2004-11-03 13:51:07 +00:00
|
|
|
.\" Written by Oron Peled <oron@actcom.co.il>.
|
ldd.1, capget.2, clone.2, create_module.2, fallocate.2, futex.2, get_kernel_syms.2, get_thread_area.2, getcpu.2, getitimer.2, getpid.2, io_cancel.2, io_destroy.2, io_getevents.2, io_setup.2, io_submit.2, ioctl_list.2, mkdir.2, mknod.2, pciconfig_read.2, pivot_root.2, posix_fadvise.2, query_module.2, sendfile.2, set_thread_area.2, setns.2, unshare.2, __setfpucw.3, a64l.3, addseverity.3, argz_add.3, bindresvport.3, cabs.3, cacos.3, cacosh.3, canonicalize_file_name.3, carg.3, casin.3, casinh.3, catan.3, catanh.3, ccos.3, ccosh.3, cerf.3, cexp.3, cexp2.3, cimag.3, clog.3, clog10.3, clog2.3, cmsg.3, conj.3, cpow.3, cproj.3, creal.3, csin.3, csinh.3, csqrt.3, ctan.3, ctanh.3, des_crypt.3, envz_add.3, fdim.3, fma.3, fmax.3, fmemopen.3, fmin.3, fmtmsg.3, fpclassify.3, gamma.3, getpt.3, getrpcent.3, getrpcport.3, getttyent.3, isgreater.3, key_setsecret.3, lgamma.3, malloc_hook.3, mempcpy.3, nan.3, netlink.3, nextafter.3, putgrent.3, remove.3, remquo.3, rpc.3, rtime.3, rtnetlink.3, setaliasent.3, setnetgrent.3, signbit.3, significand.3, sincos.3, stdin.3, tgamma.3, xcrypt.3, xdr.3, cciss.4, hpsa.4, mouse.4, pts.4, sk98lin.4, tty_ioctl.4, wavelan.4, hosts.equiv.5, rpc.5, tzfile.5, boot.7, complex.7, ddp.7, fifo.7, futex.7, icmp.7, ip.7, ipv6.7, netdevice.7, netlink.7, packet.7, raw.7, rtnetlink.7, socket.7, tcp.7, udp.7, unix.7, x25.7, sync.8: Global fix: Put copyright info at top of page, followed by blank line and LICENSE
Signed-off-by: Michael Kerrisk <mtk.manpages@gmail.com>
2013-03-10 09:29:51 +00:00
|
|
|
.\"
|
2013-03-10 09:28:50 +00:00
|
|
|
.\" %%%LICENSE_START(GPL_NOVERSION_ONELINE)
|
2004-11-03 13:51:07 +00:00
|
|
|
.\" May be distributed subject to the GPL.
|
2013-03-10 09:28:50 +00:00
|
|
|
.\" %%%LICENSE_END
|
2004-11-03 13:51:07 +00:00
|
|
|
.\"
|
|
|
|
.\" I tried to be as much generic in the description as possible:
|
|
|
|
.\" - General boot sequence is applicable to almost any
|
|
|
|
.\" OS/Machine (DOS/PC, Linux/PC, Solaris/SPARC, CMS/S390)
|
2014-10-03 06:47:03 +00:00
|
|
|
.\" - kernel and init(1) is applicable to almost any UNIX/Linux
|
intro.1, time.1, accept.2, bind.2, connect.2, execve.2, flock.2, getdents.2, getpriority.2, getuid.2, intro.2, ioctl.2, mincore.2, mknod.2, personality.2, ptrace.2, read.2, recv.2, select_tut.2, send.2, sendfile.2, shmctl.2, sigaction.2, signal.2, stat.2, times.2, truncate.2, umask.2, wait.2, MB_CUR_MAX.3, MB_LEN_MAX.3, argz_add.3, btowc.3, clearenv.3, clock.3, cmsg.3, end.3, endian.3, errno.3, exit.3, fgetwc.3, fgetws.3, fopen.3, fputwc.3, fputws.3, fseek.3, fwide.3, getfsent.3, getgrnam.3, gethostid.3, getipnodebyname.3, getmntent.3, getpwnam.3, getwchar.3, grantpt.3, iconv.3, iconv_close.3, iconv_open.3, insque.3, intro.3, iswalnum.3, iswalpha.3, iswblank.3, iswcntrl.3, iswctype.3, iswdigit.3, iswgraph.3, iswlower.3, iswprint.3, iswpunct.3, iswspace.3, iswupper.3, iswxdigit.3, malloc.3, mblen.3, mbrlen.3, mbrtowc.3, mbsinit.3, mbsnrtowcs.3, mbsrtowcs.3, mbstowcs.3, mbtowc.3, mkstemp.3, mktemp.3, nl_langinfo.3, openpty.3, posix_openpt.3, printf.3, ptsname.3, putwchar.3, qecvt.3, rcmd.3, readdir.3, rexec.3, rpc.3, setnetgrent.3, shm_open.3, sigpause.3, stdin.3, stpcpy.3, strftime.3, strptime.3, syslog.3, towctrans.3, towlower.3, towupper.3, ttyslot.3, ungetwc.3, unlocked_stdio.3, wcpcpy.3, wcpncpy.3, wcrtomb.3, wcscasecmp.3, wcscat.3, wcschr.3, wcscmp.3, wcscpy.3, wcscspn.3, wcsdup.3, wcslen.3, wcsncasecmp.3, wcsncat.3, wcsncmp.3, wcsncpy.3, wcsnlen.3, wcsnrtombs.3, wcspbrk.3, wcsrchr.3, wcsrtombs.3, wcsspn.3, wcsstr.3, wcstok.3, wcstombs.3, wcswidth.3, wctob.3, wctomb.3, wctrans.3, wctype.3, wcwidth.3, wmemchr.3, wmemcmp.3, wmemcpy.3, wmemmove.3, wmemset.3, wprintf.3, console_ioctl.4, pts.4, elf.5, filesystems.5, hosts.5, proc.5, ttytype.5, boot.7, capabilities.7, credentials.7, epoll.7, glob.7, koi8-r.7, path_resolution.7, pty.7, signal.7, suffixes.7, time.7, unicode.7, unix.7, uri.7, utf-8.7: global fix: s/Unix/UNIX/
The man pages were rather inconsistent in the use of "Unix"
versus "UNIX". Let's go with the trademark usage.
Signed-off-by: Michael Kerrisk <mtk.manpages@gmail.com>
2010-10-12 04:45:38 +00:00
|
|
|
.\" - boot scripts are applicable to SYSV-R4 based UNIX/Linux
|
2004-11-03 15:32:55 +00:00
|
|
|
.\"
|
2005-03-31 14:12:28 +00:00
|
|
|
.\" Modified 2004-11-03 patch from Martin Schulze <joey@infodrom.org>
|
2004-11-03 15:32:55 +00:00
|
|
|
.\"
|
2015-03-11 19:54:44 +00:00
|
|
|
.TH BOOT 7 2015-03-11 "Linux" "Linux Programmer's Manual"
|
2007-08-10 07:22:13 +00:00
|
|
|
.SH NAME
|
2015-03-11 19:54:44 +00:00
|
|
|
boot \- System bootup process based on UNIX System V Release 4
|
2007-08-10 07:22:13 +00:00
|
|
|
.SH DESCRIPTION
|
2007-04-12 22:42:49 +00:00
|
|
|
.LP
|
2015-03-11 19:54:44 +00:00
|
|
|
The \fBbootup process\fR (or "\fBboot sequence\fR") varies in details
|
|
|
|
among systems, but can be roughly divided into phases controlled by
|
|
|
|
the following components:
|
|
|
|
.IP 1. 4
|
|
|
|
hardware
|
|
|
|
.IP 2. 4
|
|
|
|
operating system (OS) loader
|
|
|
|
.IP 3. 4
|
|
|
|
kernel
|
|
|
|
.IP 4. 4
|
|
|
|
root user-space process (\fIinit\fR and \fIinittab\fR)
|
|
|
|
.IP 5. 4
|
|
|
|
boot scripts
|
|
|
|
.PP
|
|
|
|
Each of these is described below in more detail.
|
|
|
|
.SS Hardware
|
2007-12-25 22:02:19 +00:00
|
|
|
After power-on or hard reset, control is given
|
2015-03-11 19:54:44 +00:00
|
|
|
to a program stored in read-only memory (normally
|
|
|
|
PROM); for historical reasons involving the personal
|
|
|
|
computer, this program is often called "the \fBBIOS\fR".
|
2004-11-03 13:51:07 +00:00
|
|
|
|
2015-03-11 19:54:44 +00:00
|
|
|
This program normally performs a basic self-test of the
|
accept.2, access.2, acct.2, clock_nanosleep.2, mbind.2, mincore.2, remap_file_pages.2, sched_setscheduler.2, set_mempolicy.2, splice.2, stat.2, syslog.2, timer_create.2, timerfd_create.2, truncate.2, fenv.3, ferror.3, fflush.3, fgetwc.3, fgetws.3, flockfile.3, fputwc.3, fputws.3, fread.3, getopt.3, gets.3, getwchar.3, glob.3, iconv.3, longjmp.3, pow.3, printf.3, puts.3, putwchar.3, regex.3, rpc.3, scanf.3, setjmp.3, termios.3, unlocked_stdio.3, wcswidth.3, hd.4, rtc.4, st.4, core.5, dir_colors.5, elf.5, proc.5, arp.7, ascii.7, boot.7, bootparam.7, charsets.7, futex.7, ip.7, iso_8859-11.7, man-pages.7, man.7, mdoc.samples.7, path_resolution.7, pipe.7, posixoptions.7, unicode.7, unix.7, uri.7, utf-8.7, ld.so.8: s/non-/non/
The tendency in English, as prescribed in style guides like
Chicago MoS, is towards removing hyphens after prefixes
like "non-" etc.
Signed-off-by: Michael Kerrisk <mtk.manpages@gmail.com>
2010-01-16 17:20:12 +00:00
|
|
|
machine and accesses nonvolatile memory to read
|
2007-04-12 22:42:49 +00:00
|
|
|
further parameters.
|
|
|
|
This memory in the PC is
|
2007-12-25 22:02:19 +00:00
|
|
|
battery-backed CMOS memory, so most people
|
2015-03-11 19:54:44 +00:00
|
|
|
refer to it as "the \fBCMOS\fR"; outside
|
|
|
|
of the PC world, it is usually called "the \fBNVRAM\fR"
|
|
|
|
(nonvolatile RAM).
|
2004-11-03 13:51:07 +00:00
|
|
|
|
2015-03-11 19:54:44 +00:00
|
|
|
The parameters stored in the NVRAM vary among
|
|
|
|
systems, but as a minimum, they should specify
|
|
|
|
which device can supply an OS loader, or at least which
|
|
|
|
devices may be probed for one; such a device is known as "the
|
|
|
|
\fBboot device\fR".
|
|
|
|
The hardware boot stage loads the OS loader from a fixed position on
|
|
|
|
the boot device, and then transfers control to it.
|
2007-04-12 22:42:49 +00:00
|
|
|
.TP
|
2004-11-03 13:51:07 +00:00
|
|
|
Note:
|
2015-03-11 19:54:44 +00:00
|
|
|
The device from which the OS loader is read may be attached via a network, in which
|
|
|
|
case the details of booting are further specified by protocols such as
|
|
|
|
DHCP, TFTP, PXE, Etherboot, etc.
|
intro.1, time.1, _syscall.2, accept.2, capget.2, clone.2, execve.2, fcntl.2, intro.2, ioctl_list.2, ioprio_set.2, kill.2, mlock.2, nanosleep.2, perf_event_open.2, select.2, stat.2, times.2, ustat.2, vfork.2, wait.2, cfree.3, dbopen.3, dlopen.3, fenv.3, fmtmsg.3, gamma.3, getaddrinfo.3, gethostbyname.3, getnameinfo.3, getspnam.3, login.3, printf.3, regex.3, stdio.3, sysconf.3, termios.3, ttyslot.3, undocumented.3, wordexp.3, console_codes.4, initrd.4, mouse.4, random.4, st.4, tty_ioctl.4, wavelan.4, charmap.5, dir_colors.5, hosts.5, termcap.5, armscii-8.7, boot.7, bootparam.7, capabilities.7, charsets.7, ddp.7, futex.7, glob.7, ipv6.7, iso_8859-1.7, iso_8859-10.7, iso_8859-11.7, iso_8859-13.7, iso_8859-14.7, iso_8859-15.7, iso_8859-16.7, iso_8859-2.7, iso_8859-3.7, iso_8859-4.7, iso_8859-5.7, iso_8859-6.7, iso_8859-7.7, iso_8859-8.7, iso_8859-9.7, koi8-r.7, koi8-u.7, man.7, numa.7, path_resolution.7, pipe.7, posixoptions.7, pthreads.7, pty.7, rtnetlink.7, signal.7, time.7, udp.7, udplite.7, unicode.7, uri.7, utf-8.7: G;lobal fix: remove unneeded double quotes in .SS headings
Signed-off-by: Michael Kerrisk <mtk.manpages@gmail.com>
2013-02-24 18:02:18 +00:00
|
|
|
.SS OS loader
|
2015-03-11 19:54:44 +00:00
|
|
|
The main job of the OS loader is to locate the kernel
|
|
|
|
on some device, load it, and run it.
|
|
|
|
Most OS loaders allow
|
|
|
|
interactive use, in order to enable specification of an alternative
|
|
|
|
kernel (maybe a backup in case the one last compiled
|
|
|
|
isn't functioning) and to pass optional parameters
|
|
|
|
to the kernel.
|
|
|
|
|
|
|
|
In a traditional PC, the OS loader is located in the initial 512-byte block
|
|
|
|
of the boot device; this block is known as "the \fBMBR\fR"
|
2004-11-03 13:51:07 +00:00
|
|
|
(Master Boot Record).
|
|
|
|
|
2015-03-11 19:54:44 +00:00
|
|
|
In most systems, the OS loader is very
|
2007-04-12 22:42:49 +00:00
|
|
|
limited due to various constraints.
|
2015-03-11 19:54:44 +00:00
|
|
|
Even on non-PC systems,
|
|
|
|
there are some limitations on the size and complexity
|
2004-11-03 13:51:07 +00:00
|
|
|
of this loader, but the size limitation of the PC MBR
|
2015-03-11 19:54:44 +00:00
|
|
|
(512 bytes, including the partition table) makes it
|
|
|
|
almost impossible to squeeze much functionality into it.
|
2004-11-03 13:51:07 +00:00
|
|
|
|
2015-03-11 19:54:44 +00:00
|
|
|
Therefore, most systems split the role of loading the OS between
|
|
|
|
a primary OS loader and a secondary OS loader; this secondary
|
|
|
|
OS loader may be located within a larger portion of persistent
|
|
|
|
storage, such as a disk partition.
|
2004-11-03 13:51:07 +00:00
|
|
|
|
2015-03-11 19:54:44 +00:00
|
|
|
In Linux, the OS loader is often either
|
2004-11-03 13:51:07 +00:00
|
|
|
.BR lilo (8)
|
|
|
|
or
|
|
|
|
.BR grub (8).
|
2015-03-11 19:54:44 +00:00
|
|
|
.SS Kernel
|
|
|
|
When the kernel is loaded, it initializes various components of
|
|
|
|
the computer and operating system; each portion of software
|
|
|
|
responsible for such a task is usually consider "a \fBdriver\fR" for
|
2015-04-22 09:59:18 +00:00
|
|
|
the applicable component.
|
|
|
|
The kernel starts the virtual memory
|
2015-03-11 19:54:44 +00:00
|
|
|
swapper (it is a kernel process, called "kswapd" in a modern Linux
|
|
|
|
kernel), and mounts some filesystem at the root path,
|
|
|
|
.IR / .
|
2004-11-03 13:51:07 +00:00
|
|
|
|
|
|
|
Some of the parameters that may be passed to the kernel
|
2015-03-11 19:54:44 +00:00
|
|
|
relate to these activities (for example, the default root filesystem
|
2015-04-02 10:30:05 +00:00
|
|
|
can be overridden); for further information
|
2015-03-11 19:54:44 +00:00
|
|
|
on Linux kernel parameters, read
|
2004-11-03 13:51:07 +00:00
|
|
|
.BR bootparam (7).
|
|
|
|
|
2015-03-11 19:54:44 +00:00
|
|
|
Only then does the kernel create the initial userland
|
|
|
|
process, which is given the number 1 as its
|
|
|
|
.B PID
|
|
|
|
(process ID).
|
|
|
|
Traditionally, this process executes the
|
2004-11-03 13:51:07 +00:00
|
|
|
program
|
|
|
|
.IR /sbin/init ,
|
2015-03-11 19:54:44 +00:00
|
|
|
to which are passed the parameters that haven't already been
|
|
|
|
handled by the kernel.
|
|
|
|
.SS Root user-space process
|
2015-03-11 21:00:00 +00:00
|
|
|
.TP
|
|
|
|
Note:
|
|
|
|
The following description applies to an OS based on UNIX System V Release 4.
|
2015-03-22 19:38:53 +00:00
|
|
|
However, a number of widely used systems have adopted a related but
|
|
|
|
fundamentally different approach known as
|
2015-03-11 21:00:00 +00:00
|
|
|
.BR systemd (1),
|
|
|
|
for which the bootup process is detailed in its associated
|
|
|
|
.BR bootup (7).
|
|
|
|
.LP
|
2015-03-11 19:54:44 +00:00
|
|
|
When
|
|
|
|
.I /sbin/init
|
|
|
|
starts, it reads
|
2004-11-03 13:51:07 +00:00
|
|
|
.I /etc/inittab
|
|
|
|
for further instructions.
|
2015-03-11 19:54:44 +00:00
|
|
|
This file defines what should be run when the
|
|
|
|
.I /sbin/init
|
|
|
|
program is instructed to enter a particular \fIrun-level\fR, giving
|
|
|
|
the administrator an easy way to establish an environment
|
|
|
|
for some usage; each run-level is associated with a set of services
|
|
|
|
(for example, run-level \fBS\fR is \fIsingle-user\fR mode,
|
|
|
|
and run-level \fB2\fR entails running most network services).
|
2004-11-03 13:51:07 +00:00
|
|
|
|
2007-04-12 22:42:49 +00:00
|
|
|
The administrator may change the current
|
2004-11-03 13:51:07 +00:00
|
|
|
run-level via
|
2015-03-11 19:54:44 +00:00
|
|
|
.BR init (1),
|
2004-11-03 13:51:07 +00:00
|
|
|
and query the current run-level via
|
|
|
|
.BR runlevel (8).
|
|
|
|
|
|
|
|
However, since it is not convenient to manage individual services
|
2015-03-11 19:54:44 +00:00
|
|
|
by editing this file,
|
|
|
|
.I /etc/inittab
|
|
|
|
only bootstraps a set of scripts
|
2004-11-03 13:51:07 +00:00
|
|
|
that actually start/stop the individual services.
|
intro.1, time.1, _syscall.2, accept.2, capget.2, clone.2, execve.2, fcntl.2, intro.2, ioctl_list.2, ioprio_set.2, kill.2, mlock.2, nanosleep.2, perf_event_open.2, select.2, stat.2, times.2, ustat.2, vfork.2, wait.2, cfree.3, dbopen.3, dlopen.3, fenv.3, fmtmsg.3, gamma.3, getaddrinfo.3, gethostbyname.3, getnameinfo.3, getspnam.3, login.3, printf.3, regex.3, stdio.3, sysconf.3, termios.3, ttyslot.3, undocumented.3, wordexp.3, console_codes.4, initrd.4, mouse.4, random.4, st.4, tty_ioctl.4, wavelan.4, charmap.5, dir_colors.5, hosts.5, termcap.5, armscii-8.7, boot.7, bootparam.7, capabilities.7, charsets.7, ddp.7, futex.7, glob.7, ipv6.7, iso_8859-1.7, iso_8859-10.7, iso_8859-11.7, iso_8859-13.7, iso_8859-14.7, iso_8859-15.7, iso_8859-16.7, iso_8859-2.7, iso_8859-3.7, iso_8859-4.7, iso_8859-5.7, iso_8859-6.7, iso_8859-7.7, iso_8859-8.7, iso_8859-9.7, koi8-r.7, koi8-u.7, man.7, numa.7, path_resolution.7, pipe.7, posixoptions.7, pthreads.7, pty.7, rtnetlink.7, signal.7, time.7, udp.7, udplite.7, unicode.7, uri.7, utf-8.7: G;lobal fix: remove unneeded double quotes in .SS headings
Signed-off-by: Michael Kerrisk <mtk.manpages@gmail.com>
2013-02-24 18:02:18 +00:00
|
|
|
.SS Boot scripts
|
2007-04-12 22:42:49 +00:00
|
|
|
.TP
|
2004-11-03 13:51:07 +00:00
|
|
|
Note:
|
2015-03-11 21:00:00 +00:00
|
|
|
The following description applies to an OS based on UNIX System V Release 4.
|
2015-03-22 19:38:53 +00:00
|
|
|
However, a number of widely used systems (Slackware Linux, FreeBSD, OpenBSD)
|
2015-03-11 19:54:44 +00:00
|
|
|
have a somewhat different scheme for boot scripts.
|
2004-11-03 13:51:07 +00:00
|
|
|
.LP
|
2015-03-11 19:54:44 +00:00
|
|
|
For each managed service (mail, nfs server, cron, etc.), there is
|
2004-11-03 13:51:07 +00:00
|
|
|
a single startup script located in a specific directory
|
|
|
|
.RI ( /etc/init.d
|
|
|
|
in most versions of Linux).
|
|
|
|
Each of these scripts accepts as a single argument
|
2015-03-11 19:54:44 +00:00
|
|
|
the word "start" (causing it to start the service) or the word
|
|
|
|
\&"stop" (causing it to stop the service).
|
2007-04-12 22:42:49 +00:00
|
|
|
The script may optionally
|
2015-04-22 09:59:29 +00:00
|
|
|
accept other "convenience" parameters (e.g., "restart" to stop and then
|
2015-03-11 19:54:44 +00:00
|
|
|
start, "status" to display the service status, etc.).
|
2007-04-12 22:42:49 +00:00
|
|
|
Running the script
|
2004-11-03 13:51:07 +00:00
|
|
|
without parameters displays the possible arguments.
|
intro.1, time.1, _syscall.2, accept.2, capget.2, clone.2, execve.2, fcntl.2, intro.2, ioctl_list.2, ioprio_set.2, kill.2, mlock.2, nanosleep.2, perf_event_open.2, select.2, stat.2, times.2, ustat.2, vfork.2, wait.2, cfree.3, dbopen.3, dlopen.3, fenv.3, fmtmsg.3, gamma.3, getaddrinfo.3, gethostbyname.3, getnameinfo.3, getspnam.3, login.3, printf.3, regex.3, stdio.3, sysconf.3, termios.3, ttyslot.3, undocumented.3, wordexp.3, console_codes.4, initrd.4, mouse.4, random.4, st.4, tty_ioctl.4, wavelan.4, charmap.5, dir_colors.5, hosts.5, termcap.5, armscii-8.7, boot.7, bootparam.7, capabilities.7, charsets.7, ddp.7, futex.7, glob.7, ipv6.7, iso_8859-1.7, iso_8859-10.7, iso_8859-11.7, iso_8859-13.7, iso_8859-14.7, iso_8859-15.7, iso_8859-16.7, iso_8859-2.7, iso_8859-3.7, iso_8859-4.7, iso_8859-5.7, iso_8859-6.7, iso_8859-7.7, iso_8859-8.7, iso_8859-9.7, koi8-r.7, koi8-u.7, man.7, numa.7, path_resolution.7, pipe.7, posixoptions.7, pthreads.7, pty.7, rtnetlink.7, signal.7, time.7, udp.7, udplite.7, unicode.7, uri.7, utf-8.7: G;lobal fix: remove unneeded double quotes in .SS headings
Signed-off-by: Michael Kerrisk <mtk.manpages@gmail.com>
2013-02-24 18:02:18 +00:00
|
|
|
.SS Sequencing directories
|
2015-03-11 19:54:44 +00:00
|
|
|
To make specific scripts start/stop at specific run-levels and in a
|
|
|
|
specific order, there are \fIsequencing directories\fR, normally
|
|
|
|
of the form \fI/etc/rc[0\-6S].d\fR.
|
|
|
|
In each of these directories,
|
2008-07-15 13:24:00 +00:00
|
|
|
there are links (usually symbolic) to the scripts in the \fI/etc/init.d\fR
|
2004-11-03 13:51:07 +00:00
|
|
|
directory.
|
|
|
|
|
2007-04-12 22:42:49 +00:00
|
|
|
A primary script (usually \fI/etc/rc\fR) is called from
|
2015-03-11 19:54:44 +00:00
|
|
|
.BR inittab (5);
|
|
|
|
this primary script calls each service's script via a link in the
|
|
|
|
relevant sequencing directory.
|
|
|
|
Each link whose name begins with \(aqS\(aq is called with
|
2008-06-05 20:14:50 +00:00
|
|
|
the argument "start" (thereby starting the service).
|
2015-03-11 19:54:44 +00:00
|
|
|
Each link whose name begins with \(aqK\(aq is called with
|
|
|
|
the argument "stop" (thereby stopping the service).
|
2004-11-03 13:51:07 +00:00
|
|
|
|
|
|
|
To define the starting or stopping order within the same run-level,
|
2015-03-11 19:54:44 +00:00
|
|
|
the name of a link contains an \fBorder-number\fR.
|
|
|
|
Also, for clarity, the name of a link usually
|
|
|
|
ends with the name of the service to which it refers.
|
|
|
|
For example,
|
2004-11-03 13:51:07 +00:00
|
|
|
the link \fI/etc/rc2.d/S80sendmail\fR starts the sendmail service on
|
2007-04-12 22:42:49 +00:00
|
|
|
runlevel 2.
|
|
|
|
This happens after \fI/etc/rc2.d/S12syslog\fR is run
|
2004-11-03 13:51:07 +00:00
|
|
|
but before \fI/etc/rc2.d/S90xfs\fR is run.
|
|
|
|
|
2015-03-11 19:54:44 +00:00
|
|
|
To manage these links is to manage the boot order and run-levels;
|
|
|
|
under many systems, there are tools to help with this task
|
|
|
|
(e.g.,
|
2004-11-03 13:51:07 +00:00
|
|
|
.BR chkconfig (8)).
|
intro.1, time.1, _syscall.2, accept.2, capget.2, clone.2, execve.2, fcntl.2, intro.2, ioctl_list.2, ioprio_set.2, kill.2, mlock.2, nanosleep.2, perf_event_open.2, select.2, stat.2, times.2, ustat.2, vfork.2, wait.2, cfree.3, dbopen.3, dlopen.3, fenv.3, fmtmsg.3, gamma.3, getaddrinfo.3, gethostbyname.3, getnameinfo.3, getspnam.3, login.3, printf.3, regex.3, stdio.3, sysconf.3, termios.3, ttyslot.3, undocumented.3, wordexp.3, console_codes.4, initrd.4, mouse.4, random.4, st.4, tty_ioctl.4, wavelan.4, charmap.5, dir_colors.5, hosts.5, termcap.5, armscii-8.7, boot.7, bootparam.7, capabilities.7, charsets.7, ddp.7, futex.7, glob.7, ipv6.7, iso_8859-1.7, iso_8859-10.7, iso_8859-11.7, iso_8859-13.7, iso_8859-14.7, iso_8859-15.7, iso_8859-16.7, iso_8859-2.7, iso_8859-3.7, iso_8859-4.7, iso_8859-5.7, iso_8859-6.7, iso_8859-7.7, iso_8859-8.7, iso_8859-9.7, koi8-r.7, koi8-u.7, man.7, numa.7, path_resolution.7, pipe.7, posixoptions.7, pthreads.7, pty.7, rtnetlink.7, signal.7, time.7, udp.7, udplite.7, unicode.7, uri.7, utf-8.7: G;lobal fix: remove unneeded double quotes in .SS headings
Signed-off-by: Michael Kerrisk <mtk.manpages@gmail.com>
2013-02-24 18:02:18 +00:00
|
|
|
.SS Boot configuration
|
2015-03-11 19:54:44 +00:00
|
|
|
A program that provides a service is often called a "\fBdaemon\fR".
|
|
|
|
Usually, a daemon may receive various command-line options
|
2007-04-12 22:42:49 +00:00
|
|
|
and parameters.
|
2015-03-11 19:54:44 +00:00
|
|
|
To allow a system administrator to change these
|
|
|
|
inputs without editing an entire boot script,
|
|
|
|
some separate configuration file is used, and is located in a specific
|
|
|
|
directory where an associated boot script may find it
|
2015-03-11 21:00:00 +00:00
|
|
|
(\fI/etc/sysconfig\fR on older Red Hat systems).
|
2004-11-03 13:51:07 +00:00
|
|
|
|
2015-03-11 19:54:44 +00:00
|
|
|
In older UNIX systems, such a file contained the actual command line
|
|
|
|
options for a daemon, but in modern Linux systems (and also
|
|
|
|
in HP-UX), it just contains shell variables.
|
|
|
|
A boot script in \fI/etc/init.d\fR reads and includes its configuration
|
|
|
|
file (that is, it "\fBsources\fR" its configuration file) and then uses
|
|
|
|
the variable values.
|
2007-08-10 07:22:13 +00:00
|
|
|
.SH FILES
|
2007-04-12 22:42:49 +00:00
|
|
|
.LP
|
2004-11-03 13:51:07 +00:00
|
|
|
.IR /etc/init.d/ ,
|
2007-06-01 05:18:41 +00:00
|
|
|
.IR /etc/rc[S0\-6].d/ ,
|
2004-11-03 13:51:07 +00:00
|
|
|
.I /etc/sysconfig/
|
2007-08-10 07:22:13 +00:00
|
|
|
.SH SEE ALSO
|
2016-06-22 10:31:21 +00:00
|
|
|
.BR init (1),
|
|
|
|
.BR systemd (1),
|
2004-11-03 13:51:07 +00:00
|
|
|
.BR inittab (5),
|
|
|
|
.BR bootparam (7),
|
2016-06-22 10:31:21 +00:00
|
|
|
.BR bootup (7),
|
2004-11-03 13:51:07 +00:00
|
|
|
.BR runlevel (8),
|
|
|
|
.BR shutdown (8)
|