Tuesday, November 24, 2009

Sytem Dump in AIX

               A system dump is created when the system gets an unexpected system halt or a crash. The dump will be written to the primary dump device, if not available then to the secondary dump device.
You can also initiate it using certain commands.

              After the reboot, if the cofy flag is set to TRUE, a menu will be displayed on the console requesting the removable media to copy the dump. It can be either /dev/rmtn or /dev/fd0. Otherwise, it will be copied to a file named vmcoren under /var/adm/ras.


Default Dump Device:

AIX V 4.1 and earlier :
Default dump device is /dev/hd7


AIX 5.1 and above :
Primary : /dev/hd6          Secondary : /dev/sysdumpnull
Note: If the real memory size is larger than 4GB, then a dedicated dump device called "lg_dumplv" will be created.


Here are some commands:

1. To view the current dump configuration :

# sysdumpdev -l

primary /dev/hd6
secondary /dev/sysdumpnull
copy directory /var/adm/ras
forced copy flag TRUE
always allow dump FALSE
dump compression OFF

To change the primary dump device temporarily :
# sysdumpdev -p /dev/dumplv

To change the primary dump device permanently :
# sysdumpdev -P -p /dev/dumplv

To change the secondary dump device temporarily :
# sysdumpdev -s /dev/dumplv

To change the secondary dump device permanently :
# sysdumpdev -P -s /dev/dumplv

To set the copy flag :
# sysdumpdev -K

To unset the copy flag :
# sysdumpdev -k

To estimate the dump size :
# sysdumpdev -e

To list the last dump information :
# sysdumpdev -L
Device name: /dev/lg_dumplv
Major device number: 12
Minor device number: 4
Size: 42123543 bytes
Date/Time: Wed Jan 01 12:03:00 CDT 2009
Dump status: 0
dump completed successfully
Dump copy filename: /var/adm/ras/vmcore.1

To copy the saved vmcoren file to tape :
# snap -gfkD -o /dev/rmt0

To read the dump file :
# crash dump unix
>

To change the dump file location and if the copy fails it should ask external media to copy the dump file :
# sysdumpdev -D /opt/dumpfiles

To change the dump file location and if the copy fails it should ignore the system dump :
# sysdumpdev -d /opt/dumpfiles

To specify the dumps should not be compressed :
# sysdumpdev -c

To specify the dumps should be always compress :
# sysdmpdev -C

To find out whether a new systemp dump has occured before the last reboot :
# sysdumpdev -z

1 comment:

shibhikkiran said...

Hello Mr. Raja,

You're doing great job for Novice system administrator.
I'm shibhikkiran from chennai, practising AIX for the last couple of months. Your blog helps me alot.
It's so valuable.
Thanks.

Regards,
kiran