SHIFT

--- Sjoerd Hooft's InFormation Technology ---

User Tools

Site Tools


aixmemory
Differences

This shows you the differences between two versions of the page.

Link to this comparison view

aixmemory [2013/01/26 21:19] (current)
sjoerd created
Line 1: Line 1:
 += AIX Memory
  
 +This article handles AIX memory, info about it and the configuration. Please note that it is not a complete page! I just have to optimize the memory configuration on a few boxes and thought I post my research here.
 +
 += Memory information
 +Amount of memory in the system:
 +
 +<​code>​
 +# lsattr -El mem0
 +goodsize 640 Amount of usable physical memory in Mbytes False
 +size     640 Total amount of physical memory in Mbytes ​ False
 +</​code> ​
 +
 +<​code>​
 +# lsattr -El sys0 -a realmem
 +realmem 655360 Amount of usable physical memory in Kbytes False
 +</​code>​
 +
 += Memory Usage
 +You can use the command '​topas'​ to view current server resources:
 +{{aixmemory-topas.jpg}} ​
 +Important:
 +|PAGING SPACE, % Used |Percentage paging space what is being used |
 +|PAGING, PageIn |Memory pages that are being transferred to the paging space|
 +|PAGING, Pageout |Memory pages that are being transferred from the paging space to memory |
 +If the percentage of used paging space gets to high, or you see too much pages being transferred to paging space and back you're experiencing swapping and should consider adding more memory or tuning your settings.
 +
 +== Top usage
 +This is the command to show the processes which utilize the most memory:
 +<​code>​
 +root@qmodel1:/>​svmon -Pt15 | perl -e '​while(<>​){print if($.==2||$&&&​!$s++);​$.=0 if(/​^-+$/​)}'​
 +-------------------------------------------------------------------------------
 +     Pid Command ​         Inuse      Pin     ​Pgsp ​ Virtual 64-bit Mthrd  16MB
 +  368976 oracle ​        ​6726101 ​   65584   ​578648 ​ 2188967 ​     Y     ​N ​    N
 +  364848 oracle ​        ​6688947 ​   65584   ​575603 ​ 2186445 ​     Y     ​N ​    N
 +  385466 oracle ​        ​6687989 ​   65584   ​576948 ​ 2186861 ​     Y     ​N ​    N
 +  209378 oracle ​        ​6685939 ​   65584   ​575486 ​ 2185793 ​     Y     ​N ​    N
 +  217470 oracle ​        ​6587121 ​   65584   ​575331 ​ 2185872 ​     Y     ​N ​    N
 +  462950 oracle ​        ​6586439 ​   65584   ​575842 ​ 2185769 ​     Y     ​N ​    N
 +  159860 oracle ​        ​5895989 ​   65584   ​575090 ​ 2185593 ​     Y     ​N ​    N
 +  336170 oracle ​        ​3627823 ​   65584   ​575501 ​ 2185557 ​     Y     ​N ​    N
 +  549176 oracle ​        ​3577342 ​   65584   ​575219 ​ 2185538 ​     Y     ​N ​    N
 +  573950 oracle ​        ​3577274 ​   65584   ​575089 ​ 2185330 ​     Y     ​N ​    N
 +  246134 oracle ​        ​3577210 ​   65584   ​575410 ​ 2185591 ​     Y     ​N ​    N
 +  299504 oracle ​        ​3568335 ​   65584   ​575294 ​ 2185338 ​     Y     ​N ​    N
 +  356566 oracle ​        ​3452641 ​   65584   ​575023 ​ 2185329 ​     Y     ​N ​    N
 +  180518 oracle ​        ​3446320 ​   65584   ​575236 ​ 2185587 ​     Y     ​N ​    N
 +  307702 oracle ​        ​3446201 ​   65584   ​575112 ​ 2185325 ​     Y     ​N ​    N
 +</​code>​
 +
 += Memory tuning
 +== lru_file_repage maxclient, maxperm, minperm
 +
 +The AIX lru_file_repage kernel tuning parameter was introduced in AIX V5.2 ML5 and AIX V5.3 ML2. The default setting for lru_file_repage is 1 (on).
 +Before lru_file_repage was introduced, it was often necessary to alter minperm and maxperm/​maxclient to get good performance,​ particularly when running an Oracle RDBMS workload. Now that lru_file_repage is available, when installing AIX V5.3 at ML5 and above it is best to leave minperm, maxperm, and maxclient at their default values and to set lru_file_repage=0 (off). Subsequent AIX performance monitoring and analysis may suggest changing other vmo parameters, but it is best to start with minperm, maxperm, and maxclient at their default values unless other AIX V5.3 initial tuning recommendations come from some authoritative source. (The VMM Tuning Tip: Protecting Computational Memory article cited on the Performance Monitoring Documentation web page suggests setting minperm=5, maxperm=90, and maxclient=90 when setting lru_file_repage=0.)
 +[[http://​www.ibm.com/​developerworks/​wikis/​display/​WikiPtype/​AIXV53InitialTuning|Source]]
 +
 +
 +=== Adjusting these settings
 +Adjusting the settings according to the VMM Tuning tip would be done like this:
 +<​code>​
 +# vmo -p -o minperm%=5 -o maxperm%=90 -o maxclient%=90 -o lru_file_repage=0
 +</​code>​
 +| -p | Adjust the current values as well as the value it should have after a reboot (permanent) |
 +| -o | Specific option you want to adjust |
 +| -L | Displays current, default and possible settings (see below) |
 +
 +Before lru_file_repage was introduced, you would have to set these numbers a bit otherwise:
 +<​code>​
 +# vmo -p -o minperm%=5 -o maxperm%=30 -o maxclient%=30
 +</​code>​
 +
 +=== Viewing these settings
 +<​code>​
 +# vmstat -v
 +              2097152 memory pages
 +              2017044 lruable pages
 +               ​201021 free pages
 +                    2 memory pools
 +               ​260312 pinned pages
 +                 80.0 maxpin percentage
 +                 10.0 minperm percentage
 +                 90.0 maxperm percentage
 +                 74.5 numperm percentage
 +              1503689 file pages
 +                  0.0 compressed percentage
 +                    0 compressed pages
 +                 74.5 numclient percentage
 +                 90.0 maxclient percentage
 +              1503689 client pages
 +                    0 remote pageouts scheduled
 +                 2625 pending disk I/Os blocked with no pbuf
 +                    0 paging space I/Os blocked with no psbuf
 +                 2484 filesystem I/Os blocked with no fsbuf
 +                    0 client filesystem I/Os blocked with no fsbuf
 +                  838 external pager filesystem I/Os blocked with no fsbuf
 +                    0 Virtualized Partition Memory Page Faults
 +                 0.00 Time resolving virtualized partition memory page faults
 +</​code>​
 +<​code>​
 +bash-3.00# vmo -L
 +NAME                      CUR    DEF    BOOT   ​MIN ​   MAX    UNIT           TYPE
 +     ​DEPENDENCIES
 +--------------------------------------------------------------------------------
 +<<<​cut>>>​
 +--------------------------------------------------------------------------------
 +lru_file_repage ​          ​0 ​     1      0      0      1      boolean ​          D
 +--------------------------------------------------------------------------------
 +maxclient% ​               90     ​80 ​    ​90 ​    ​1 ​     100    % memory ​         D
 +     ​maxperm%
 +     ​minperm%
 +--------------------------------------------------------------------------------
 +maxperm% ​                 90     ​80 ​    ​90 ​    ​1 ​     100    % memory ​         D
 +     ​minperm%
 +
 +
 +
 +
 +     ​maxclient%
 +--------------------------------------------------------------------------------
 +minperm% ​                 10     ​20 ​    ​10 ​    ​1 ​     100    % memory ​         D
 +     ​maxperm%
 +     ​maxclient%
 +<<<​cut>>>​
 +Parameter types:
 +    S = Static: cannot be changed
 +    D = Dynamic: can be freely changed
 +    B = Bosboot: can only be changed using bosboot and reboot
 +    R = Reboot: can only be changed during reboot
 +    C = Connect: changes are only effective for future socket connections
 +    M = Mount: changes are only effective for future mountings
 +    I = Incremental:​ can only be incremented
 +    d = deprecated: deprecated and cannot be changed
 +</​code>​
 +
 +=== AIX 6.1
 +On AIX 6.1 there are some changes with these parameters: ​
 +* lru_file_repage,​ maxperm% and maxclient% are by default set to the correct value and are hidden. You can still see them using 'vmo -F -L'
 +* minperm% is set to 3 by default which is almost always correct as well
 +
 +{{tag>​aix}}
aixmemory.txt ยท Last modified: 2013/01/26 21:19 by sjoerd