Created
July 25, 2012 05:10
-
-
Save AhnSeongHyun/3174514 to your computer and use it in GitHub Desktop.
core.sh
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
CHIP_COUNT=`cat /proc/cpuinfo | grep "physical id" | sort -u | wc -l` | |
CHIP_CORES=`cat /proc/cpuinfo | grep "siblings" | tail -1 | cut -d: -f2`; | |
CHIP_MODELS=`cat /proc/cpuinfo | grep "model name" | sort -u`; | |
echo "==== CPU INFO ====" | |
echo "CPU: $CHIP_COUNT chips x $CHIP_CORES cores" | |
echo "$CHIP_MODELS" | |
echo "" | |
echo "==== MEMORY INFO ====" | |
MEM_TOTAL=`cat /proc/meminfo | grep "MemTotal"`; | |
MEM_FREE=`cat /proc/meminfo | grep "MemFree"`; | |
echo "$MEM_TOTAL" | |
echo "$MEM_FREE" |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment