how to check memory and CPU stats in Linux ?
Question : how to check memory and CPU status in Linux ?
Question : what command will you used to check memory and cpu status ?
Question : how to check CPU status ?
Question : how to check memory status ?
1. free
free command give us valuable information on available RAM / Memory
# free
# free --helpusage: free [-b|-k|-m|-g|-h] [-l] [-o] [-t] [-s delay] [-c count] [-V]
-b,-k,-m,-g show output in bytes, KB, MB, or GB
-h human readable output (automatic unit scaling)
-l show detailed low and high memory statistics
-o use old format (no -/+buffers/cache line)
-t display total for RAM + swap
-s update every [delay] seconds
-c update [count] times
-a show available memory if exported by kernel (>80 characters per line)
-V display version information and exit
vmstat command give us information about processes, memory/RAM,cpu activity and more.
# vmstat
# vmstat --helpusage: vmstat [-V] [-n] [delay [count]]
-V prints version.
-n causes the headers not to be reprinted regularly.
-a print inactive/active page stats.
-d prints disk statistics
-D prints disk table
-p prints disk partition statistics
-s prints vm table
-m prints slabinfo
-t add timestamp to output
-S unit size
delay is the delay between updates in seconds.
unit size k:1000 K:1024 m:1000000 M:1048576 (default is K)
count is the number of updates.
top command give us information like tasks, memory, CPU and swap and more
# top
# top --help
Leave a Comment