1reboot(3C)               Standard C Library Functions               reboot(3C)
2
3
4

NAME

6       reboot - reboot system or halt processor
7

SYNOPSIS

9       #include <sys/reboot.h>
10
11       int reboot(int howto, char *bootargs);
12
13

DESCRIPTION

15       The reboot() function reboots the system.  The howto argument specifies
16       the behavior of the system while rebooting and is a mask constructed by
17       a bitwise-inclusive-OR of flags from the following list:
18
19       RB_AUTOBOOT    The  machine is rebooted from the root filesystem on the
20                      default boot device. This is the default  behavior.  See
21                      boot(1M) and kernel(1M).
22
23
24       RB_HALT        The  processor  is simply halted; no reboot takes place.
25                      This option should be used with caution.
26
27
28       RB_ASKNAME     Interpreted by the bootstrap program and kernel, causing
29                      the user to be asked for pathnames during the bootstrap.
30
31
32       RB_DUMP        The  system  is  forced to panic immediately without any
33                      further processing and a crash dump is  written  to  the
34                      dump device (see dumpadm(1M)) before rebooting.
35
36
37
38       Any other howto argument causes the kernel file to boot.
39
40
41       The interpretation of the bootargs argument is platform-dependent.
42

RETURN VALUES

44       Upon  successful  completion, reboot() never returns.  Otherwise, −1 is
45       returned and errno is set to indicate the error.
46

ERRORS

48       The reboot() function will fail if:
49
50       EPERM    The {PRIV_SYS_CONFIG} privilege is not asserted in the  effec‐
51                tive set of the calling process.
52
53

SEE ALSO

55       Intro(1M),   boot(1M),  dumpadm(1M),  halt(1M),  init(1M),  kernel(1M),
56       reboot(1M), uadmin(2)
57
58
59
60SunOS 5.11                        22 Mar 2004                       reboot(3C)
Impressum