dumpadm - configure operating system crash dump
/usr/sbin/dumpadm [-nuy] [-c content-type] [-d dump-device] [-m mink | minm | min%] [-s savecore-dir] [-r root-dir]
The dumpadm program is an administrative command that manages the configuration of the operating system crash dump facility. A crash dump is a disk copy of the physical memory of the computer at the time of a fatal system error. When a fatal operating system error occurs, a message describing the error is printed to the console. The operating system then generates a crash dump by writing the contents of physical memory to a predetermined dump device, which is typically a local disk partition. The dump device can be configured by way of dumpadm. Once the crash dump has been written to the dump device, the system will reboot.
Fatal operating system errors can be caused by bugs in the operating system, its associated device drivers and loadable modules, or by faulty hardware. Whatever the cause, the crash dump itself provides invaluable information to your support engineer to aid in diagnosing the problem. As such, it is vital that the crash dump be retrieved and given to your support provider. Following an operating system crash, the savecore(1M) utility is executed automatically during boot to retrieve the crash dump from the dump device, and write it to a pair of files in your file system named unix.X and vmcore.X, where X is an integer identifying the dump. Together, these data files form the saved crash dump. The directory in which the crash dump is saved on reboot can also be configured using dumpadm.
For systems with a UFS root file system, the default dump device is configured to be an appropriate swap partition. Swap partitions are disk partitions reserved as virtual memory backing store for the operating system. Thus, no permanent information resides in swap to be overwritten by the dump. See swap(1M). For systems with a ZFS root file system, dedicated ZFS volumes are used for swap and dump areas. For further information about setting up a dump area with ZFS, see the ZFS Administration Guide. To view the current dump configuration, use the dumpadm command with no arguments:
example# dumpadm Dump content: kernel pages Dump device: /dev/dsk/c0t0d0s1 (swap) Savecore directory: /var/crash/saturn Savecore enabled: yes
When no options are specified, dumpadm prints the current crash dump configuration. The example shows the set of default values: the dump content is set to kernel memory pages only, the dump device is a swap disk partition, the directory for savecore files is set to /var/crash/hostname, and savecore is set to run automatically on reboot.
When one or more options are specified, dumpadm verifies that your changes are valid, and if so, reconfigures the crash dump parameters and displays the resulting configuration. You must be root to view or change dump parameters.
The following options are supported:
-c content-type
kernel
all
curproc
-d dump-device
dump-device
swap
-m mink | minm | min%
k
m
%
The savecore command will consult the minfree file, if present, prior to writing the dump files. If the size of these files would decrease the amount of free disk space below the minfree threshold, no dump files are written and an error message is logged. The administrator should immediately clean up the savecore directory to provide adequate free space, and re-execute the savecore command manually. The administrator can also specify an alternate directory on the savecore command-line.
-n
-r root-dir
-s savecore-dir
-u
-y
Example 1 Reconfiguring The Dump Device To A Dedicated Dump Device:
The following command reconfigures the dump device to a dedicated dump device:
example# dumpadm -d /dev/dsk/c0t2d0s2 Dump content: kernel pages Dump device: /dev/dsk/c0t2d0s2 (dedicated) Savecore directory: /var/crash/saturn Savecore enabled: yes
The following exit values are returned:
0
1
2
/dev/dump
/etc/dumpadm.conf
savecore-directory/minfree
See attributes(5) for descriptions of the following attributes:
|
svcs(1), uname(1), savecore(1M), svcadm(1M), swap(1M), attributes(5), smf(5)
The system crash dump service is managed by the service management facility, smf(5), under the service identifier:
svc:/system/dumpadm:default
Administrative actions on this service, such as enabling, disabling, or requesting restart, can be performed using svcadm(1M). The service's status can be queried using the svcs(1) command.
When the special swap token is specified as the argument to dumpadm -d the utility will attempt to configure the most appropriate swap device as the dump device. dumpadm configures the largest swap block device as the dump device; if no block devices are available for swap, the largest swap entry is configured as the dump device. If no swap entries are present, or none can be configured as the dump device, a warning message will be displayed. While local and remote swap files can be configured as the dump device, this is not recommended.
In the event that the dump device is also a swap device, and the swap device is deleted by the administrator using the swap -d command, the swap command will automatically invoke dumpadm -d swap in order to attempt to configure another appropriate swap device as the dump device. If no swap devices remain or none can be configured as the dump device, the crash dump will be disabled and a warning message will be displayed. Similarly, if the crash dump is disabled and the administrator adds a new swap device using the swap -a command, dumpadm -d swap will be invoked to re-enable the crash dump using the new swap device.
Once dumpadm -d swap has been issued, the new dump device is stored in the configuration file for subsequent reboots. If a larger or more appropriate swap device is added by the administrator, the dump device is not changed; the administrator must re-execute dumpadm -d swap to reselect the most appropriate device fom the new list of swap devices.
If the dumpadm -m option is used to create a minfree file based on a percentage of the total size of the file system containing the savecore directory, this value is not automatically recomputed if the file system subsequently changes size. In this case, the administrator must re-execute dumpadm -m to recompute the minfree value. If no such file exists in the savecore directory, savecore will default to a free space threshold of one megabyte. If no free space threshold is desired, a minfree file containing size 0 can be created.
If, upon reboot, the specified savecore directory is not present, it will be created prior to the execution of savecore with permissions 0700 (read, write, execute by owner only) and owner root. It is recommended that alternate savecore directories also be created with similar permissions, as the operating system crash dump files themselves may contain secure information.
Закладки на сайте Проследить за страницей |
Created 1996-2024 by Maxim Chirkov Добавить, Поддержать, Вебмастеру |