数据库实际使用的内存应该是yong db2mrtk -i -d -v 来看 在节点1上 db2inpe@dmsrvr:~> db2mtrk -i -d -v Tracking Memory on: 2012/03/15 at 04:29:44
Memory for instance
Other Memory is of size 34799616 bytes Database Monitor Heap is of size 327680 bytes FCMBP Heap is of size 22413312 bytes Total: 57540608 bytes
Memory for database: TEST
Backup/Restore/Util Heap is of size 65536 bytes Package Cache is of size 524288 bytes Other Memory is of size 131072 bytes Catalog Cache Heap is of size 262144 bytes Buffer Pool Heap (2) is of size 33226752 bytes Buffer Pool Heap (1) is of size 4521984 bytes Buffer Pool Heap (System 32k buffer pool) is of size 851968 bytes Buffer Pool Heap (System 16k buffer pool) is of size 589824 bytes Buffer Pool Heap (System 8k buffer pool) is of size 458752 bytes Buffer Pool Heap (System 4k buffer pool) is of size 393216 bytes Shared Sort Heap is of size 0 bytes Lock Manager Heap is of size 26476544 bytes Database Heap is of size 14876672 bytes Application Heap (3744) is of size 196608 bytes Application Heap (68077) is of size 65536 bytes Application Heap (3749) is of size 65536 bytes Application Heap (3746) is of size 65536 bytes Application Heap (68068) is of size 65536 bytes Application Heap (68067) is of size 65536 bytes Applications Shared Heap is of size 327680 bytes Total: 83230720 bytes
在节点0上
db2inpe@dmsrvr:~/sqllib/db2dump> db2mtrk -i -d -v Tracking Memory on: 2012/03/15 at 04:41:17
Memory for instance
Other Memory is of size 35258368 bytes Database Monitor Heap is of size 327680 bytes FCMBP Heap is of size 22413312 bytes Total: 57999360 bytes
Memory for database: TEST
Backup/Restore/Util Heap is of size 65536 bytes Package Cache is of size 2162688 bytes Other Memory is of size 131072 bytes Catalog Cache Heap is of size 524288 bytes Buffer Pool Heap (2) is of size 33226752 bytes Buffer Pool Heap (1) is of size 4521984 bytes Buffer Pool Heap (System 32k buffer pool) is of size 851968 bytes Buffer Pool Heap (System 16k buffer pool) is of size 589824 bytes Buffer Pool Heap (System 8k buffer pool) is of size 458752 bytes Buffer Pool Heap (System 4k buffer pool) is of size 393216 bytes Shared Sort Heap is of size 131072 bytes Lock Manager Heap is of size 26476544 bytes Database Heap is of size 14876672 bytes Application Heap (68077) is of size 65536 bytes Application Heap (3749) is of size 65536 bytes Application Heap (3747) is of size 65536 bytes Application Heap (68067) is of size 65536 bytes Application Heap (3746) is of size 65536 bytes Application Heap (3745) is of size 65536 bytes Application Heap (3744) is of size 131072 bytes Application Heap (3743) is of size 65536 bytes Application Heap (3742) is of size 65536 bytes Applications Shared Heap is of size 720896 bytes Total: 85786624 bytes
57999360+85786624 =143785984
关于ps aux 应该跟dbpmem对应着看。 db2inpe@dmsrvr:~/sqllib/db2dump> ps aux|head USER PID %CPU %MEM VSZ RSS TTY STAT START TIME COMMAND db2inpe@dmsrvr:~/sqllib/db2dump> ps aux |grep db2sysc db2inpe 23934 0.0 22.4 667520 227900 ? Sl Mar12 3:53 db2sysc 0 db2inpe 23937 0.0 21.6 605008 219492 ? Sl Mar12 3:36 db2sysc 1
Database Partition Memory Controller Statistics
Controller Automatic: Y Memory Limit: 380564 KB Current usage: 309792 KB HWM usage: 313824 KB Cached memory: 69760 KB