DOC HOME SITE MAP MAN PAGES GNU INFO SEARCH PRINT BOOK
 
Troubleshooting system-level problems

Forcing a panic on your system

If your system is hung, you can cause a panic on your system and take a system dump for analysis.


WARNING: A panic is a very dangerous way to bring a system down. This method should be used only on a test system, or as a last resort on a production system where the only alternative is to power the machine off. If possible, all users should be logged off the system and all filesystems should be unmounted before attempting to force the panic.

kdb(1M) must be installed to force a panic as described here.


If the feature is enabled, a panic can be forced from the console with the key sequence <Ctrl><Alt>p. (The <Ctrl> and <Alt> keys are held down and the p key is pressed.) You are then prompted with:

   Generate a panic on the system ? (y or n) :


NOTE: If the console is redirected to a serial port, press <Ctrl>-. This is similar to invoking the debugger through <Ctrl>k.

A response of y will start the panic. Any other response will return to the prompt and no panic will be generated.

The availability of the <Ctrl><Alt>p key sequence is governed by the kernel tunable CONSOLE_SECURITY. This also governs the availability of the <Ctrl><Alt><Del> sequence to initiate a shutdown. The tunable has a range of 0-3. Here is a table of the possible values and their effect.

Panic and reboot keystrokes

CONSOLE_SECURITY <Ctrl><Alt><Del> <Ctrl><Alt>p
0 Disabled Disabled
1 Enabled Disabled
2 Disabled Enabled
3 Enabled Enabled
To check or set the CONSOLE_SECURITY value, use the idtune(1M) command. The following will display the current value of the tunable:

/etc/conf/bin/idtune -g CONSOLE_SECURITY

   1       1       0       3
The value we are interested in is the first column, which is the current value. The second is the default value. The third and fourth are the minimum and maximum values. In this example, (which is the default after installing UnixWare), the <Ctrl><Alt><Del> sequence to reboot is enabled, but the <Ctrl><Alt>p panic sequence is disabled.

To change the value, use this command:

/etc/conf/idtune -f CONSOLE_SECURITY 3

In this case the value would be set to 3, which enables both the panic and reboot key sequences.

After updating the value of the tunable, a new kernel needs to be rebuilt and the system needs to be rebooted for the changes to be effective. The kernel is built with the idbuild(1M) command. Run the following to rebuild the kernel immediately:

/etc/conf/bin/idbuild -B

The next time you reboot the system, the new kernel will be booted and the changes will be in effect.


Next topic: Checking error messages
Previous topic: Software hang

© 2004 The SCO Group, Inc. All rights reserved.
UnixWare 7 Release 7.1.4 - 22 April 2004