Tuesday, April 1, 2014

IBMPower AIX: perfpmr pipes "pile" to kdb

The topas utility in AIX has some information, specifically in 'topas -M' that I'd like to be able to log over time.  Namely, the amount of filesystem cache associated with each SRAD (the logical CPUs and memory within an LPAR from the same socket) and the local/near/far dispatch ratio for threads on that logical core.

Check it out on Nigel Griffiths' blog
https://www.ibm.com/developerworks/community/blogs/aixpert/entry/local_near_far_memory_part_2_virtual_machine_cpu_memory_lay_out3?lang=en


Logging topas from an unattended script is painful.  But most of the work I fret over should be monitored unattended.

Nigel mentioned in his post that he's seen information similar to 'topas -M' in perfstat API programming.  He's got a great page on that, linked below.  Very promising, but after investing a significant amount of time today I still wasn't able to get what I wanted.  I'll come back to perfstat in the future, I'm sure.  Especially because if I can write something using the perfstat API, at least it won't need root access like most of the kdb work I end up doing.
https://www.ibm.com/developerworks/community/wikis/home?lang=en#!/wiki/Power%20Systems/page/Roll-Your-Own-Performance-Tool


So I'll take a look at what perfpmr is doing these days that might be relevant.

Saw this, wanted to make sure I jotted it down before it gets lost in the sea of my life.
 
[root@sasquatch_mtn: /root]
# echo pile | kdb
           START              END <name>
0000000000001000 00000000058A0000 start+000FD8
F00000002FF47600 F00000002FFDF9C8 __ublock+000000
000000002FF22FF4 000000002FF22FF8 environ+000000
000000002FF22FF8 000000002FF22FFC errno+000000
F1000F0A00000000 F1000F0A10000000 pvproc+000000
F1000F0A10000000 F1000F0A18000000 pvthread+000000
read vscsi_scsi_ptrs OK, ptr = 0xF1000000C0208380
(0)> pile
ADDRESS                NAME             cur_total_pages
0xF100010020990800     NLC64            0x00000000000000FC
0xF100010020990900     NLC128           0x0000000000000014
0xF100010020990A00     NLC256           0x0000000000000000
0xF10001002BBD0800     iCache           0x0000000000002080
0xF10001002BBD0900     iCache           0x0000000000002080
0xF10001002BBD0A00     iCache           0x0000000000002080
0xF10001002BBD0B00     iCache           0x0000000000002080
0xF10001002BBD0C00     iCache           0x0000000000002080
0xF10001002BBD0D00     iCache           0x0000000000002080
0xF10001002BBD0E00     iCache           0x0000000000002080
0xF10001002BBD0F00     iCache           0x0000000000002080
0xF10001002BBD0000     iCache           0x0000000000002080
0xF10001002BBD8100     iCache           0x0000000000002080
0xF10001002BBD8200     iCache           0x0000000000002080
0xF10001002BBD8300     iCache           0x0000000000002080
0xF10001002BBD8400     iCache           0x0000000000002080
0xF10001002BBD8500     iCache           0x0000000000002080
0xF10001002BBD8600     iCache           0x0000000000002080
0xF10001002BBD8700     iCache           0x0000000000002080
0xF10001002BBD8800     iCache           0x0000000000002080
0xF10001002BBD8900     iCache           0x0000000000002080
0xF10001002BBD8A00     iCache           0x0000000000002080
0xF10001002BBD8B00     iCache           0x0000000000002080
0xF10001002BBD8C00     iCache           0x0000000000002080
0xF10001002BBD8D00     iCache           0x0000000000002080
0xF10001002BBD8E00     iCache           0x0000000000002080
0xF10001002BBD8F00     iCache           0x0000000000002080
0xF10001002BBD8000     iCache           0x0000000000002080
0xF10001002BCF3100     bmIOBufPile      0x0000000000000000
0xF10001002BCF3200     bmXBufPile       0x0000000000000FEC
0xF10001002BCF3300     j2SnapBufPool    0x0000000000000000
0xF10001002BCF3500     logxFreePile     0x0000000000000004
0xF10001002BCF3600     txLockPile       0x000000000000151C
0xF10001002BCF3700     j2VCBufferPool   0x0000000000000080
0xF10001002BCF3900     j2VCBufferPool   0x0000000000000078
0xF10001002BCF3D00     j2VCBufferPool   0x000000000000007C
0xF100010020990B00     j2VCBufferPool   0x0000000000000078
0xF1000100358AD500     j2VCBufferPool   0x00000000000000EC
0xF1000100358AD600     j2VCBufferPool   0x0000000000000078
0xF1000100358AD700     j2VCBufferPool   0x00000000000000F4
0xF1000100358ADB00     j2VCBufferPool   0x00000000000000F8
0xF1000100E0D28200     j2VCBufferPool   0x0000000000000104
0xF1000100E1BC5500     vmmBufferPool    0x0000000000000800



Yeah... that one I probably won't get to until sometime next year.


# echo "mempsum -psx" | kdb
           START              END <name>
0000000000001000 00000000058A0000 start+000FD8
F00000002FF47600 F00000002FFDF9C8 __ublock+000000
000000002FF22FF4 000000002FF22FF8 environ+000000
000000002FF22FF8 000000002FF22FFC errno+000000
F1000F0A00000000 F1000F0A10000000 pvproc+000000
F1000F0A10000000 F1000F0A18000000 pvthread+000000
read vscsi_scsi_ptrs OK, ptr = 0xF1000000C0208380
(0)> mempsum -psx
MEMP VMP SRAD PSZ NB_PAGES  MEMP%   SYS% LRUPAGES   NUMFRB    NRSVD  PERM%

 000  00   0  ---    7.5GB ------  50.0%    7.5GB    3.5GB    0.0MB  11.3%
 001  00   0  ---    7.5GB ------  49.9%    7.5GB    3.5GB    0.0MB  11.3%  


# echo "lrustate 1" | kdb
           START              END <name>
0000000000001000 00000000058A0000 start+000FD8
F00000002FF47600 F00000002FFDF9C8 __ublock+000000
000000002FF22FF4 000000002FF22FF8 environ+000000
000000002FF22FF8 000000002FF22FFC errno+000000
F1000F0A00000000 F1000F0A10000000 pvproc+000000
F1000F0A10000000 F1000F0A18000000 pvthread+000000
read vscsi_scsi_ptrs OK, ptr = 0xF1000000C0208380
(0)> lrustate 1

LRU State @F1000F0009540840 for mempool 1
> LFBLRU
> not fileonly mode
> first call to vcs (lru_firstvcs)
LRU Start nfr        (lru_start)        : 0000000000000000
mempools first nfr   (lru_firstnfr)     : 0000000000000000
numfrb this mempool  (lru_numfrb)       : 0000000000000000, 0
number of steals     (lru_steals)       : 0000000000000000, 0
page goal to steal   (lru_goal)         : 0000000000000000, 0
npages scanned       (lru_nbscan)       : 0000000000000000, 0
addr, head of cur pass list   (lru_hdr) : 0000000000000000
addr, head of alt pass list  (lru_hdrx) : 0000000000000000
current lru list          (lru_curlist) : 0000000000000000
current lru list object    (lru_curobj) : 0000000000000000
pgs togo p1 cur obj        (lru_p1_pgs) : 0000000000000000, 0
pages left this chunklet (lru_chunklet) : 0000000000000000, 0
scans of start nfr (lru_scan_start_cnt) : 00000000
lru revolutions      (lru_rev)          : 00000000
fault color          (lru_fault_col)    : 00000000, 0 BLUE
nbuckets scanned     (lru_nbucket)      : 00000000
lru mode             (lru_mode)         : 00000000 DEF_MODE
request type         (lru_rq)           : 00000000 LRU_NONE
list type to use     (lru_listidx)      : 00000000 WORKING
page size to find    (lru_psx)          : 0000
MPSS fs'es to skip   (lru_mpss_skip)    : 00000000
MPSS fs'es failed    (lru_mpss_fail)    : 00000000
numperm_global     (lru_numperm_global) : 00000000
global numperm%    (lru_global_numperm) : 00000000  0.0%
perm frames (lru_global_perm_n4kframes) : 0000000000000000
lruable frames   (lru_global_n4kframes) : 0000000000000000
16m mpss type        (lru_16m_type)     : 00 LRU16_IDLE
16m mpss seqn        (lru_16m_seqn)     : 00000000

No comments:

Post a Comment