#! /bin/sh # hostinfo (Bourne shell script) -- reports info about the current host hostname -f uname -a # e.g. 'Ubuntu 12.04 "precise" (LinuxMint 13 "maya")' echo $DISTRO $DISTRO_RELEASE \"$DISTRO_CODENAME\" \ ${DISTRO_FLAVOUR:+\($DISTRO_FLAVOUR $DISTRO_FLAVOUR_RELEASE \"$DISTRO_FLAVOUR_CODENAME\"\)} who -r uptime if [ -d /sys/devices/system/cpu ] ; then echo "Number of CPUs online: $(ls -d /sys/devices/system/cpu/cpu[0-9]*|wc -l)" else echo "Number of CPUs online: ?" fi