crashconf.2 (2010 09)
c
crashconf(2) crashconf(2)
Example 7: Removing a Crash Dump Device
char *device_to_remove[1];
int device_return[1];
...
crashconf(DC_DEVICES|DC_REMOVE, 0, 0, 1, device_to_remove,
device_return);
Example 8: Setting Concurrent Dump ON, Including Kernel Code Pages
crashconf(DC_SETCONCURRENT | DC_INCLUDE, DT_KCODE, 0, NULL, NULL);
RETURN VALUE
0 Successful completion.
-1 Error. errno is set to indicate the error.
1 If DC_DEVICES is set, 1 indicates that at least one device has been configured but one or more dev-
ices failed to configure. If
DC_PERSISTENT is set, 1 indicates that at least one of the dump devices
is not marked persistent.
ERRORS
crashconf() fails if one or more of the following is true:
[EPERM] The calling process is not owned by superuser or not privileged.
[EINVAL] operation does not have at least one of
DC_INCLUDE, DC_EXCLUDE,
DC_SETCOMPRESS, DC_SETNOCOMPRESS
,orDC_DEVICES set.
[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 both
DC_SETCONCURRENT
and DC_SETNOCONCURRENT set.
[EINVAL] operation has
DC_DEVICES set, and deviceCount is less than zero or greater than
DC_MAXDEVICES.
[EINVAL] operation has both
DC_REPLACE and DC_REMOVE set.
[EINVAL] operation has both
DC_LEGACY_MODE
and DC_PERSISTENT set.
[EIO] operation
DC_LEGACY_MODE failed to save the configuration change.
[EIO] operation
DC_PERSISTENT failed to save the configuration change.
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. It is also possible to use the -U option of the vxassist command to do the same (see
vxassist (1M)).
Marking dump devices using
lvlnboot, vxvmboot, and /stand/system will be obsoleted in the
next HP-UX release. DC_PERSISTENT operation of crashconf() can be used to mark the dump dev-
ice list as persistent.
SEE ALSO
crashconf(1M), vxassist(1M), pstat_getcrashdev(2), pstat_getcrashinfo(2), alwaysdump(5), dontdump(5),
dump_compress_on(5), dump_concurrent_on(5), krs(5), privileges(5), intro(7).
4 Hewlett-Packard Company − 4 − HP-UX 11i Version 3: September 2010