In Linux, how to tell how much memory processes are using?

前端 未结 13 1112
情歌与酒
情歌与酒 2020-11-30 17:36

I think I may have a memory leak in my LAMP application (memory gets used up, swap starts getting used, etc.). If I could see how much memory the various processes are using

13条回答
  •  独厮守ぢ
    2020-11-30 18:00

    Use ps to find the process id for the application, then use top -p1010 (substitute 1010 for the real process id). The RES column is the used physical memory and the VIRT column is the used virtual memory - including libraries and swapped memory.

    More info can be found using "man top"

提交回复
热议问题