Default location where AIX copies system dump is page space.
# sysdumpdev -l primary /dev/hd6 secondary /dev/sysdumpnull copy directory /var/adm/ras forced copy flag TRUE always allow dump TRUE dump compression ON # lsvg -l rootvg rootvg: LV NAME TYPE LPs PPs PVs LV STATE MOUNT POINT hd5 boot 1 2 2 closed/syncd N/A hd6 paging 12 24 2 open/syncd N/A hd8 jfs2log 1 2 2 open/syncd N/A hd4 jfs2 1 2 2 open/syncd / hd2 jfs2 19 38 2 open/syncd /usr hd9var jfs2 1 2 2 open/syncd /var hd3 jfs2 5 10 2 open/syncd /tmp hd1 jfs2 1 2 2 open/syncd /home hd10opt jfs2 8 16 2 open/syncd /opt
This can create a problem since system will not automatically reboot in case of a crash. instead the system will prompt for instructions what to do with the dump. Luckily, it is very easy to change this settings and allocate dedicated logical volume for storing system dump.
First you need to know how big sys dump logical volume should be.
# sysdumpdev -e Estimated dump size in bytes: 483393536
So, in this case LV should be at least 460MB. If you take a closer look at the logical volume output above, you'll notice that all values in 'PPs' column are twice as big as values in 'LPs' column. That can only mean our root volume group is mirrored. So actually we will need 460MBx2. Let's check if our root volume group has enough free space.
# lsvg rootvg VOLUME GROUP: rootvg VG IDENTIFIER: 00cb8a0c00004c000000010bfabee774 VG STATE: active PP SIZE: 128 megabyte(s) VG PERMISSION: read/write TOTAL PPs: 542 (69376 megabytes) MAX LVs: 256 FREE PPs: 411 (52608 megabytes) LVs: 8 USED PPs: 131 (16768 megabytes) OPEN LVs: 7 QUORUM: 1 TOTAL PVs: 2 VG DESCRIPTORS: 3 STALE PVs: 0 STALE PPs: 0 ACTIVE PVs: 2 AUTO ON: yes MAX PPs per VG: 32512 MAX PPs per PV: 1016 MAX PVs: 32 LTG size (Dynamic): 256 kilobyte(s) AUTO SYNC: no HOT SPARE: no BB POLICY: relocatable
Seems that we have 51GB free. More than enough. Also we found out that we have 2 physical volumes in this volume group. Let's check what are the names of this PVs, we will need them soon.
# lsvg -p rootvg rootvg: PV_NAME PV STATE TOTAL PPs FREE PPs FREE DISTRIBUTION hdisk1 active 271 207 54..29..18..54..52 hdisk2 active 271 204 54..26..18..54..52
Now, what we gonna do is create two logical volumes, one on each PV, and set one as a primary dump device and the other as a secondary dump device. The reason why we do this is that we don't want to mirror sysdump device, but we still need two copies in case one of the hard drives fails.
In this example physical partition is 128MB so we should add 4 PPs to our new logical volumes. Let's start.
# echo $((128*4)) 512 # mklv -t sysdump -y sysdump1 rootvg 4 hdisk1 # mklv -t sysdump -y sysdump2 rootvg 4 hdisk2 # lsvg -l rootvg rootvg: LV NAME TYPE LPs PPs PVs LV STATE MOUNT POINT hd5 boot 1 2 2 closed/syncd N/A hd6 paging 12 24 2 open/syncd N/A hd8 jfs2log 1 2 2 open/syncd N/A hd4 jfs2 1 2 2 open/syncd / hd2 jfs2 19 38 2 open/syncd /usr hd9var jfs2 1 2 2 open/syncd /var hd3 jfs2 5 10 2 open/syncd /tmp hd1 jfs2 1 2 2 open/syncd /home hd10opt jfs2 8 16 2 open/syncd /opt sysdump1 sysdump 4 4 1 closed/syncd N/A sysdump2 sysdump 4 4 1 closed/syncd N/A
Logical volumes sysdump1 and sysdump2 are created. Now, let's change the system dump settings. First the primary device.
# sysdumpdev -Pp /dev/sysdump1
And now the second.
# sysdumpdev -Ps /dev/sysdump2
Let's check if it's applied.
# sysdumpdev -l primary /dev/sysdump1 secondary /dev/sysdump2 copy directory /var/adm/ras forced copy flag TRUE always allow dump TRUE dump compression ON
Everything seems fine. All we have to do now is to wait for a system to crash to test our new settings. :o)
http://www.miljan.org/wiki/index.php/How_to_Change_Default_System_Dump_Device_in_AIX