Indicates if the process is a 64 bit process (Y) or a 32 bit process (N) Mthrd
Indicates if the process is multi-threaded (Y) or not (N). 16MB
Indicates the 16MB page status of the process. \\means that the process does not use 16MB pages. 工程经验
svmon –P是一个很好的监控单独进程内存利用率的命令. 它也可以用来作为检查程序是否有内存泄漏的一个重要工具.
ps
#ps v 254008
PID TTY STAT TIME PGIN SIZE RSS LIM TSIZ TRS %CPU %MEM COMMAND
254008 - A 193:26 50425 729316 717376 32768 39 72 0.0 29.0 /opt/IBM SIZE(单位1KB)
(v flag) The virtual size of the data section of the process (in 1KB units). 被分配的working segment pages, size大小的计算公式:
729316=(65536+65525+51020+213+35)*4, 后者是svmon输出的结果(Virtual),包括物理内存和paging space. RSS
(v flag) The real-memory (resident set) size of the process (in 1KB units).包括所有在内存中的的working segment和code segment. Rss大小的计算公式: 717376=(65111+65001+48991+191+32+18)*4, 后者是svmon输出中inuse对应的值. TRS
(v flag) The size of resident-set (real memory) of text. TRS的计算公式: 72=18*4,表示的是程序段在内存中的大小
计算公式
SIZE = 4 * Virtual of (work lib data + work private)
RSS = 4 * Inuse of (work lib data + work private + pers code) TRS = 4 * Inuse of (pers code) # svmon -P 254008|more
------------------------------------------------------------------------------- Pid Command Inuse Pin Pgsp Virtual 64-bit Mthrd 16MB 254008 java 191539 7530 12956 194382 N Y N
PageSize Inuse Pin Pgsp Virtual s 4 KB 191145 7530 12941 193951 m 64 KB 394 0 15 431
Vsid Esid Type Description PSize Inuse Pin Pgsp Virtual 244ed 4 work working storage s 65111 0 697 65536 344e9 3 work working storage s 65001 0 5434 65525 204ec 5 work working storage s 48991 0 6719 51020 0 0 work kernel s 11397 7468 21 11417 330ad d work unused segment m 394 0 15 431 114ed - clnt /dev/hd10opt:40960 s 238 0 - - 284ee f work working storage s 191 0 12 213 3c4eb - work s 162 59 55 205 384ea 2 work process private s 32 3 3 35 3c4 1 clnt code,/dev/hd10opt:47099 s 18 0 - - 4725 - clnt /dev/hd10opt:53347 s 2 0 - -
AIX 性能调优 内存篇之五 常用命令二 序号 版本号 更改人 日期 备注 1 1.0版 bldmickey 2007-06-20 本章介绍和AIX内存调优用到的常用命令,继续内存篇常用命令一
Topas
# topas MEMORY Real,MB 3920 % Comp 44.6 % Noncomp 5.6 % Client 6.9
计算型的和非计算型的,剩余的就是free的内存. PAGING SPACE Size,MB 8192 % Used 1.0 % Free 98.9
查看所有进程的信息. # topas -D
Topas Monitor for host: XXX Interval: 2 Fri Jun 22 15:42:12 2007 DATA TEXT PAGE PGFAULTS
USER PID PPID PRI NI RES RES SPACE TIME CPU% I/O OTH COMMAND
root 254008 1 60 20 179326 18 182329 193:28 0.1 0 0 java root 344078 1 60 20 1173 243 2758 5:49 0.0 0 108 kuma610
root 397376 225504 58 41 298 102 298 0:00 0.0 0 0 topas root 352382 458810 60 20 162 15 270 14:43 0.0 0 110 kux_vmst
root 69666 0 37 41 192 0 240 44:10 0.0 0 0 gil root 266386 1 60 20 21 17 101 27:48 0.0 0 0 getty root 336062 1 60 20 1436 96 1531 1:23 0.0 0 0 kulagent
root 12294 0 17 41 96 0 112 0:38 0.0 0 0 sched root 188538 135356 48 8 76 64 102 4:51 0.0 0 0 xntpd
root 65568 0 36 41 96 0 112 0:46 0.0 0 0 netm root 319610 430160 60 20 9791 1639 17063 173:53 0.0 0 0 dsmc
root 258184 270468 60 20 14451 4657 20262 158:41 0.0 0 0 dsmserv
root 94312 1 60 20 121 2 128 149:23 0.0 0 0 syncd root 16392 0 16 41 64 0 128 6:38 0.0 0 0 lrud root 155768 135356 60 20 1278 275 1934 5:13 0.0 0 0 IBM.CSMA
root 286776 1 60 20 1244 146 2077 3:28 0.0 0 0 kuxagent
root 413938 458810 60 20 139 12 174 3:23 0.0 0 0 nfs_stat
root 458810 286776 60 20 334 40 460 1:14 0.0 0 0 stat_dae
root 49176 0 60 41 96 0 112 1:04 0.0 0 0 xmgc root 1 0 60 20 70 10 187 0:57 0.0 0 0 init
vmo
查看内核的参数 # vmo -a
cpu_scale_memp = 8 data_stagger_interval = 161 defps = 1 force_relalias_lite = 0 framesets = 2 htabscale = n/a kernel_heap_psize = 4096 large_page_heap_size = 0 lgpg_regions = 0 lgpg_size = 0 low_ps_handling = 1 lru_file_repage = 1 lru_poll_interval = 10 lrubucket = 131072 maxclient% = 80 maxfree = 1088 maxperm = 768483 maxperm% = 80 maxpin = 810654 maxpin% = 80