?? init.8
字號(hào):
.TH INIT 8 .SH NAMEinit, rc \- process control initialization.SH SYNOPSIS.B /etc/init.br.B /etc/rc.SH DESCRIPTION.I Initis invoked as the last step of the boot procedure (see.IR boot (8)).Generally its role is to create a process for eachtypewriter on which a user may log in..PPWhen.I initfirst is executedthe console typewriter.I /dev/console.is opened for readingand writing and the shell is invoked immediately.This feature is used to bring up a single-user system.If the shell terminates,.I initcomes up multi-user and the process described below is started..PPWhen.I initcomes up multiuser,itinvokes a shell, with input taken from thefile.I /etc/rc.This command fileperforms housekeepinglike removing temporary files,mounting file systems, and startingdaemons..PPThen.I initreads the file.I /etc/ttysandforks several times to create a processfor each typewriter specified in the file.Each of these processes opens the appropriate typewriterfor reading and writing. These channels thusreceive file descriptors 0, 1 and 2, the standard input,output and error files.Opening the typewriter will usually involve a delay,since the.IR open ""is not completed until someoneis dialed up and carrier established on the channel.Then.I /etc/gettyis called with argument as specified by the last character ofthe.I ttysfile line..I Gettyreads the user's name and invokes.IR login (1)to log in the user and execute the shell..PPUltimately the shell will terminatebecause of an end-of-file eithertyped explicitly or generated as a result of hanging up.The main path of.IR init ,which has been waitingfor such an event,wakes up and removes the appropriate entry from thefile.IR utmp ,which records current users, andmakes an entry in.IR /usr/adm/wtmp ,which maintains a historyof logins and logouts.Then the appropriate typewriter is reopened and.I gettyisreinvoked..PP.I Initcatches thehangup signal SIGHUP and interprets it to mean thatthesystem should be brought from multi user to singleuser.Use `kill -1 1' to send the hangup signal..SH FILES/dev/tty?, /etc/utmp, /usr/adm/wtmp, /etc/ttys, /etc/rc.SH "SEE ALSO"login(1), kill(1), sh(1), ttys(5), getty(8)
?? 快捷鍵說明
復(fù)制代碼
Ctrl + C
搜索代碼
Ctrl + F
全屏模式
F11
切換主題
Ctrl + Shift + D
顯示快捷鍵
?
增大字號(hào)
Ctrl + =
減小字號(hào)
Ctrl + -