echo 1 > /proc/sys/vm/drop_cacheslinux
清理前服務器
# free -hide
total used free shared buffers cachedcode
Mem: 19G 19G 203M 1.1G 82M 17G內存
-/+ buffers/cache: 1.5G 18Gclass
Swap: 23G 159M 23Gcli
清理後sed
# echo 1 > /proc/sys/vm/drop_caches硬件
# free -hgrep
total used free shared buffers cached
Mem: 19G 2.4G 17G 1.1G 680K 1.4G
-/+ buffers/cache: 1.1G 18G
Swap: 23G 163M 23G
查看內存條數命令:
dmidecode | grep -A16 "Memory Device$"
查看服務器內存槽數量及各內存條大小
linux
dmidecode | grep -A16 "Memory Device$"
esxi
vclient-主機-硬件狀態