相关疑难解决方法(0)

了解虚拟内存使用情况 > Linux 上的交换 + 物理内存

我有一个进程在“top”中报告它分配了 6GB 的常驻内存和 70GB 的虚拟内存。奇怪的是,这个特定的服务器只有 8GB 的​​物理空间和 35GB 的可用交换空间。

从“顶级”手册:

   o: VIRT  --  Virtual Image (kb)
      The total amount of virtual memory used by the  task.   It  includes
      all  code,  data  and  shared  libraries  plus  pages that have been
      swapped out. (Note: you can define the STATSIZE=1 environment  vari-
      able  and  the VIRT will be calculated from the /proc/#/state VmSize
      field.)

      VIRT = SWAP + RES.
Run Code Online (Sandbox Code Playgroud)

鉴于这种解释,我希望进程的虚拟内存分配仅限于我的交换 + 可用物理内存。

根据'pmap',这个进程的代码、共享库和共享内存部分都是最小的——不超过300M左右。

显然,机器和过程仍然正常运行(虽然很慢),那么我在这里错过了什么?

linux virtual-memory

9
推荐指数
1
解决办法
1万
查看次数

标签 统计

linux ×1

virtual-memory ×1