Linux and UNIX Man Pages

Linux & Unix Commands - Search Man Pages

uadmin(2) [sunos man page]

uadmin(2)																 uadmin(2)

NAME
uadmin - administrative control SYNOPSIS
#include <sys/uadmin.h> int uadmin(int cmd, int fcn, uintptr_t mdep); The uadmin() function provides control for basic administrative functions. This function is tightly coupled to the system administrative procedures and is not intended for general use. The argument mdep is provided for machine-dependent use and is not defined here. As specified by cmd, the following commands are available: A_SHUTDOWN The system is shut down. All user processes are killed, the buffer cache is flushed, and the root file system is unmounted. The action to be taken after the system has been shut down is specified by fcn. The functions are generic; the hardware capabilities vary on specific machines. AD_HALT Halt the processor(s). AD_POWEROFF Halt the processor(s) and turn off the power. AD_BOOT Reboot the system, using the kernel file. AD_IBOOT Interactive reboot; user is prompted for bootable program name. A_REBOOT The system stops immediately without any further processing. The action to be taken next is specified by fcn as above. A_DUMP The system is forced to panic immediately without any further processing and a crash dump is written to the dump device (see dumpadm(1M)). The action to be taken next is specified by fcn, as above. A_REMOUNT The root file system is mounted again after having been fixed. This should be used only during the startup process. A_FREEZE Suspend the whole system. The system state is preserved in the state file. The following subcommands, specified by fcn, are available. AD_COMPRESS Save the system state to the state file with compression of data. AD_CHECK Check if your system supports suspend and resume. Without performing a system suspend/resume, this com- mand checks if this feature is currently available on your system. AD_FORCE Force AD_COMPRESS even when threads of user applications are not suspendable. Upon successful completion, the value returned depends on cmd as follows: A_SHUTDOWN Never returns. A_REBOOT Never returns. A_FREEZE 0 upon resume. A_REMOUNT 0. Otherwise, -1 is returned and errno is set to indicate the error. The uadmin() function will fail if: EBUSY Suspend is already in progress. EINVAL The cmd argument is invalid. ENOMEM Suspend/resume ran out of physical memory. ENOSPC Suspend/resume could not allocate enough space on the root file system to store system information. ENOTSUP Suspend/resume is not supported on this platform or the command specified by cmd is not allowed. ENXIO Unable to successfully suspend system. EPERM The {PRIV_SYS_CONFIG} privilege is not asserted in the effective set of the calling process. dumpadm(1M), kernel(1M), uadmin(1M), privileges(5) 1 Sep 2005 uadmin(2)

Check Out this Related Man Page

cpr(7)							   Device and Network Interfaces						    cpr(7)

NAME
cpr - Suspend and resume module SYNOPSIS
/platform/'uname -m'/kernel/misc/cpr DESCRIPTION
The cpr module is a loadable module used to suspend and resume the entire system. You may wish to suspend a system to save power or to power off temporarily for transport. The cpr module should not be used in place of a normal shutdown when performing any hardware reconfig- uration or replacement. In order for the resume operation to succeed, it is important that the hardware configuration remain the same. When the system is suspended, the entire system state is preserved in non-volatile storage until a resume operation is conducted. dtpower(1M) or power.conf(4) are used to configure the suspend-resume feature. The speed of suspend and resume operations can range from 15 seconds to several minutes, depending on the system speed, memory size, and load. During resume operation, the SIGTHAW signal is sent to all processes to allow them to do any special processing in response to suspend- resume operation. Normally applications are not required to do any special processing because of suspend-resume, but some specialized pro- cesses can use SIGTHAW to restore the state prior to suspend. For example, X can refresh the screen in response to SIGTHAW. In some cases the cpr module may be unable to perform the suspend operation. If a system contains additional devices outside the standard shipped configuration, it is possible that device drivers for these additional devices might not support suspend-resume operations. In this case, the suspend fails and an error message is displayed. These devices must be removed or their device drivers unloaded for the suspend operation to succeed. Contact the device manufacturer to obtain a new version of device driver that supports suspend-resume. A suspend may also fail when devices or processes are performing critical or time-sensitive operations (such as realtime operations). The system will remain in its current running state. Messages reporting the failure will be displayed on the console and status returned to the caller. Once the system is successfully suspended the resume operation will succeed, barring external influences such as a hardware recon- figuration. Some network-based applications may fail across a suspend and resume cycle. This largely depends on the underlying network protocol and the applications involved. In general, applications that retry and automatically reestablish connections will continue to operate transparently on a resume operation; those applications that do not will likely fail. ATTRIBUTES
See attributes(5) for descriptions of the following attributes: +-----------------------------+-----------------------------+ | ATTRIBUTE TYPE | ATTRIBUTE VALUE | +-----------------------------+-----------------------------+ |Availability |SUNWcpr | +-----------------------------+-----------------------------+ |Interface stability |Unstable | +-----------------------------+-----------------------------+ SEE ALSO
dtpower(1M) (OpenWindows Reference Manual), pmconfig(1M), uadmin(1M), uadmin(2), power.conf(4), attributes(5) Using Power Management Writing Device Drivers NOTES
Certain device operations such as tape and floppy disk activities are not resumable due to the nature of removable media. These activities are detected at suspend time, and must be stopped before the suspend operation will complete successfully. Suspend-resume is currently supported only on a limited set of hardware platforms. Please see the book Using Power Management for a com- plete list of platforms that support system Power Management. See uname(2) to programatically determine if the machine supports suspend- resume. SunOS 5.10 7 May 2001 cpr(7)
Man Page