HP-UX Compressed Dump White paper Version 1.
Compressed Dump White Paper, Version 1.
Compressed Dump White Paper, Version 1.3 1. Objective ..........................................................................................................................1 2. Introduction .....................................................................................................................1 3. Compressed Dump Features ....................................................................................1 4. Manpages .................................................................
Compressed DumpWhite paper, Version 1.
Compressed Dump White Paper, Version 1.3 1. Objective The objective of this document is to describe the Compressed Dump functionality that will be introduced in HP-UX 11i, v2 in the kernel dump subsystem. The features implemented by the Compressed Dump project will be a standard feature for future releases of HP-UX starting from 11i v2. 2.
Compressed Dump White Paper, Version 1.3 Compressed Dump configured by using the dump configuration utility, crashconf. The new option, -c can be used to turn compression ON or OFF as follows.
Compressed Dump White Paper, Version 1.3 If compression is turned OFF, then the system will not dump compressed even when the environment of the crash is suitable to dump compressed. The compression hint is turned ON by default. Any changes to the configuration take effect immediately and remain in effect until the next system reboot, or until changed with a subsequent invocation of crashconf.
Compressed Dump White Paper, Version 1.3 When savecrash runs during boot-up, the dump is copied into the filesystem. savecrash will run faster when copying compressed dump since the dump size will be smaller compared to uncompressed dump. savecrash option -p can be used to avoid saving portions of the dump that are sitting in dedicated dump devices. savecrash option -z is ignored since the dump is already compressed.
Compressed Dump White Paper, Version 1.3 crashconf(1M) crashconf(1M) NAME crashconf - configure system crash dumps SYNOPSIS /sbin/crashconf [-artv] [-i|-e class] [-c mode]...[device...] DESCRIPTION crashconf displays and/or changes the current system crash dump configuration. The crash dump configuration consists of: + The crash dump device list.This list identifies all devices that can be used to store a crash dump. + The included class list.
Compressed Dump White Paper, Version 1.3 class is the name (or number) of a system memory class which should be added to the appropriate class list. The list of system memory classes can be obtained using crashconf -v. The memory page size is 4Kb. class may also be the word all, in which case all classes are added to the appropriate list. (The effect of adding all classes to the included class list is to force full crash dumps under all circumstances.
Compressed Dump White Paper, Version 1.3 WARNINGS On systems running VxVM 3.5, the swap volumes to be configured for system crash dumps should be created with the usage type as swap during the creation of the swap volume. Not doing so will cause dump corruption. You could use the -U option of vxassist (1M) to do the same. The output of crashconf is not designed to be parsed by applications or scripts, but only to be read by humans. The output format may change without notice.
Compressed Dump White Paper, Version 1.
Compressed Dump White Paper, Version 1.3 crashconf(2) crashconf(2) NAME crashconf() - configure system crash dumps SYNOPSIS #include int crashconf( int operation, int includeClasses, int excludeClasses, int deviceCount, char **devices, int *deviceReturn ); DESCRIPTION crashconf() changes the current system crash dump configuration. The crash dump configuration consists of: + The crash dump device list. This list identifies all devices that can be used to store a crash dump.
Compressed Dump White Paper, Version 1.3 Configuration changes made using crashconf() take effect immediately and remain in effect until the next system reboot, or until changed with a subsequent call to crashconf(). Parameters operation is a bitmask specifying what crashconf() should do. It must have at least one of the following flags set: • DC_INCLUDE crashconf() will change the contents of the included class list. The includeClasses parameter is valid.
Compressed Dump White Paper, Version 1.3 index into an array of error messages. The error message strings are defined in CCERR_STRINGS (see below). >0 Warning, The corresponding device has been configured but there is one or more notes or warnings associated with the device. The returned value is a bitmap of warnings. the warning message strings are defined in CCWARN_STRINGS (see below). Any parameters which are not used for the given operation should be set to zero.
Compressed Dump White Paper, Version 1.3 Example 4: Using CCERR_STRINGS and CCWARN_STRINGS Assume only one device, devices[0], is being added to the dump configuration. The following code will check the device_return[0] value and print corresponding error or warning messages. char *ccerrs[] = { CCERR_STRINGS }; int num_ccerrs = sizeof(ccerrs)/sizeof(*ccerrs); char *ccwarns[] = { CCWARN_STRINGS }; int num_ccwarns = sizeof(ccwarns)/sizeof(*ccwarns); char *device_to_add[1]; int device_return[1]; ...
Compressed Dump White Paper, Version 1.3 [EINVAL] operation has both DC_INCLUDE and DC_EXCLUDE set, and the same class (bit) is specified in both includeClasses and excludeClasses. [EINVAL] operation has both DC_SETCOMPRESS and DC_SETNOCOMPRESS set. [EINVAL] operation has DC_DEVICES set, and deviceCount is less than zero or greater than DC_MAXDEVICES. WARNINGS On systems running VxVM 3.
Compressed Dump White Paper, Version 1.3 savecrash(1M) savecrash(1M) NAME savecrash - save a crash dump of the operating system SYNOPSIS /sbin/savecrash [-cflprvzZ] [-D dumpdevice -O offset] [-d sysfile] [-m minfree] [-s chunksize] [-t tapedevice] [-w NOSWAP|SWAPEACH|SWAPEND] [dirname] DESCRIPTION savecrash saves the crash dump information of the system (assuming one was made when the system crashed) and writes a reboot message in the shutdown log file.
Compressed Dump White Paper, Version 1.3 It is possible for dump devices to be used also as paging devices. If savecrash determines that a dump device is already enabled for paging, and that paging activity has already taken place on that device, a warning message will indicate that the dump may be invalid. If a dump device has not already been enabled for paging, savecrash prevents paging from being enabled to the device by creating the file /etc/ savecore.LCK.
Compressed Dump White Paper, Version 1.3 page 16 -D dumpdevice dumpdevice is the name of the device containing the header of the raw crash image. The console messages from the time of the panic will identify the major and minor numbers of this device. This option, in combination with -O, can be used to tell savecrash where to find the dump in the rare instances that savecrash doesn’t know where to look.
Compressed Dump White Paper, Version 1.3 crash will not perform any compression. When dirname is specified with the -t option, dirname is the name of the existing directory where the INDEX file is created; the default directory is /tmp. The INDEX file is the first file that is written out to the dump tape. This file is written a second time once all the dump files have been written. The first copy of the file only contains crash dump header information and its filename on tape is tmpindex.
Compressed Dump White Paper, Version 1.3 savecrash relies on the expectation that device numbers have the same meaning (point to the same devices) at the time the system dumps and at the time the dump is saved. If, after a crash, the system was booted from a different boot device in order to run savecrash, it is possible that this expectation will not be met. If so, savecrash may save an incomplete or incorrect dump or may fail to save a dump at all.
Compressed Dump White Paper, Version 1.3 crashutil(1M) crashutil(1M) NAME crashutil - manipulate crash dump data SYNOPSIS /usr/sbin/crashutil [-q] [-v version] source [destination] DESCRIPTION crashutil copies and preserves crash dump data, and performs format conversions on it. Common uses of crashutil include: + Copying portions of a dump that still reside on a raw dump device into a crash dump directory. + Converting between different formats of crash dumps.
Compressed Dump White Paper, Version 1.3 portions of the physical memory image and metadata describing which memory pages were dumped and which were not. sources or destinations of this type should be specified as the pathname to a crash directory. PARDIR (Version 3) This format is used in HP-UX Release 11i Version 2.0 and later. It is very similar in structure to the CRASHDIR format in that it consists of a crash.
Compressed Dump White Paper, Version 1.3 still resident in the raw dump devices. To save the remainder of the dump into the crash dump directory, use: crashutil /var/adm/crash/crash.2 If preferred, the completed crash dump directory could be in a different location perhaps on another machine via NFS: crashutil /var/adm/crash/crash.
Compressed Dump White Paper, Version 1.3 libcrash(5) libcrash(5) NAME libcrash - crash dump access library SYNOPSIS #include
Compressed Dump White Paper, Version 1.3 cr_read() Reads pages from the dump. cr_set_node() Sets the node number that is used by cr_read() and cr_isaddr() to access memory in the node private memory areas. cr_perror() Prints to standard error an error or warning message corresponding to one of the error or warning codes returned by another library call. cr_close() Terminates access to the crash dump and frees all space allocated by the library.
Compressed Dump White Paper, Version 1.3 be used when the dump devices have compressed memory images. See crashconf(1M). Other formats, for example tape archival formats, may be added in the future. Cache Caching mechanism is implemented to improve the performance while analyzing PARDIR format crash dumps. This caching mechanism is used to keep the uncompressed pages so that subsequent requests can be satisfied from the cache. By default, this caching mechanism will be disabled.
Compressed Dump White Paper, Version 1.3 CRERR_WRONGDUMP A raw dump device which is supposed to contain part of the dump does not. It may have been overwritten by swap activity or by a more recent dump. CRERR_WRONGHOST A portion of the crash dump still resides on a dump device of the system that dumped, which is not the current system. CRERR_NONODE The specified node number does not exist. CRERR_ERRNO A system error occurred. Consult errno for the specific error.