本文介绍了查找堆,堆栈和交换进程的内存的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

各位大家好,



这可能是已知的问题,但在问这个问题之前我已经搜索了很多但没有找到确切的答案。



1.)如何在Linux框中找出当前运行进程的堆,堆栈和交换内存使用情况?

2.)如何找出总数在整个Linux机箱中分配动态堆和堆栈?



我知道要查找当前运行过程的堆内存使用情况如下

$ awk'{print $ 23}'/ proc / {process_id} / stat

但这可以通过打开一个文件来实现,而我想用直接命令找到它。



另外,我希望这个问题在很多人心中产生,对答案非常有帮助。

非常感谢。

Hello everybody,

This may be the known question but before asking this I had searched a lot but did not find the precise answer.

1.) How to find out the Heap, Stack and Swap memory usage of current running process in Linux box?
2.) How to find out total and dynamic Heap and Stack allocated in the entire Linux box?

I know to find out the Heap memory usage of current running process as below
$ awk '{print $23}' /proc/{process_id}/stat
But this is achieved by opening a file rather I wanted to find this out with the direct command.

Also, I hope this question arises in many others mind and would be very helpful for the answer.
Many thanks.

推荐答案




这篇关于查找堆,堆栈和交换进程的内存的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持!

07-30 15:17