ITeye博客

linux内存用光

fengqinyun · 2016-03-28 00:00 · linux · 操作系统 · Markdown

free -g 代表的含义



/	total	used	free	shared	buffers	cached
Mem	总物理内存	当前使用的内存(包括slab+buffers+cached)	完全没有使用的内存	进程间共享的内存	缓存文件的元数据1	缓存文件的具体内容1
-/+ buffers/cache		当前使用的内存(不包括buffers+cached,但包括slab)	未使用和缓存的内存(free+buffers+cached)			
Swap	总的交换空间	已使用的交换空间	未使用的交换空间			


然后top看了下,没有特别吃内存的程序。用ps大概统计下所有程序占用的总内存:


ps aux | awk '{mem += $6} END {print mem/1024/1024}'


cat /proc/meminfo

具体可以参考 http://blog.atime.me/research/linux-ate-my-memory.html

评论(0)

暂无评论。

评论功能维护中,当前仅展示历史评论。