Find amount of installed memory on QNX system

爱⌒轻易说出口 提交于 2019-12-12 02:47:22

问题


How do I find the amount of memory installed on my QNX Neutrino system?

  • uname -a doesn't show it
  • top only shows how much memory is available
  • I've looked at pidin syspage without success
  • pidin mem shows all the used memory in gory detail

回答1:


The amount of free RAM is the size of "/proc" !

In your own program, you can write something like this :

#include <sys/stat.h>
struct stat buf;
if (stat("/proc", &buf) != -1) {
    printf("Mem free = %d\n", buf.st_size);
}

-- Hope this help Emmanuel




回答2:


showmem -S will show the amount of RAM memory installed as shown below,

showmem -S

System RAM: 1936M ( 2030043136) Total Used: 401M ( 420642376) Used Private: 317M ( 332529404) Used Shared: 79M ( 83333120) Other: 4667K ( 4779852) (includes IFS and reserved RAM)




回答3:


pidin info will show the amount of memory installed, as shown below.

pidin info
CPU:X86 Release:6.4.1  FreeMem:836Mb/1015Mb BootTime:Jun 04 14:01:55 UTC 2014


来源:https://stackoverflow.com/questions/24040046/find-amount-of-installed-memory-on-qnx-system

标签
易学教程内所有资源均来自网络或用户发布的内容,如有违反法律规定的内容欢迎反馈
该文章没有解决你所遇到的问题?点击提问,说说你的问题,让更多的人一起探讨吧!