halt.8
来自「sysvinit--linux系统下的init」· 8 代码 · 共 103 行
8
103 行
.\"{{{}}}.\"{{{ Title.TH HALT 8 "Nov 6, 2001" "" "Linux System Administrator's Manual".\"}}}.\"{{{ Name.SH NAMEhalt, reboot, poweroff \- stop the system..\"}}}.\"{{{ Synopsis.SH SYNOPSIS.B /sbin/halt.RB [ \-n ].RB [ \-w ].RB [ \-d ].RB [ \-f ].RB [ \-i ].RB [ \-p ].RB [ \-h ].br.B /sbin/reboot.RB [ \-n ].RB [ \-w ].RB [ \-d ].RB [ \-f ].RB [ \-i ].br.B /sbin/poweroff.RB [ \-n ].RB [ \-w ].RB [ \-d ].RB [ \-f ].RB [ \-i ].RB [ \-h ].\"}}}.\"{{{ Description.SH DESCRIPTION\fBHalt\fP notes that the system is being brought down in the file\fI/var/log/wtmp\fP, and then either tells the kernel to halt, reboot orpoweroff the system..PPIf \fBhalt\fP or \fBreboot\fP is called when the system is\fInot\fP in runlevel \fB0\fP or \fB6\fP, in other words when it's runningnormally, \fBshutdown\fP will be invoked instead (with the \fB-h\fPor \fB-r\fP flag). For more info see the \fBshutdown\fP(8)manpage..PPThe rest of this manpage describes the behaviour in runlevels 0and 6, that is when the systems shutdown scripts are being run..\"}}}.\"{{{ Options.SH OPTIONS.IP \fB\-n\fPDon't sync before reboot or halt..IP \fB\-w\fPDon't actually reboot or halt but only write the wtmp record(in the \fI/var/log/wtmp\fP file)..IP \fB\-d\fPDon't write the wtmp record. The \fB\-n\fP flag implies \fB\-d\fP..IP \fB\-f\fPForce halt or reboot, don't call \fBshutdown\fP(8)..IP \fB\-i\fPShut down all network interfaces just before halt or reboot..IP \fB\-h\fPPut all harddrives on the system in standby mode just before halt or poweroff..IP \fB\-p\fPWhen halting the system, do a poweroff. This is the default when halt iscalled as \fBpoweroff\fP..\"}}}.\"{{{ Diagnostics.SH DIAGNOSTICSIf you're not the superuser, you will get the message `must be superuser'..\"}}}.\"{{{ Notes.SH NOTESUnder older \fBsysvinit\fP releases , \fBreboot\fP and \fBhalt\fP shouldnever be called directly. From release 2.74 on \fBhalt\fP and \fBreboot\fPinvoke \fBshutdown\fP(8) if the system is not in runlevel 0 or 6. Thismeans that if \fBhalt\fP or \fBreboot\fP cannot find out the currentrunlevel (for example, when \fI/var/run/utmp\fP hasn't been initializedcorrectly) \fBshutdown\fP will be called, which might not be what you want.Use the \fB-f\fP flag if you want to do a hard \fBhalt\fP or \fBreboot\fP..PPThe \fB-h\fP flag puts all harddisks in standby mode just before haltor poweroff. Right now this is only implemented for IDE drives. A sideeffect of putting the drive in standby mode is that the write cacheon the disk is flushed. This is important for IDE drives, since thekernel doesn't flush the write-cache itself before poweroff..PPThe \fBhalt\fP program uses /proc/ide/hd* to find all IDE disk devices,which means that /proc needs to be mounted when \fBhalt\fP or\fBpoweroff\fP is called or the \fB-h\fP switch will do nothing..PP.\"}}}.\"{{{ Author.SH AUTHORMiquel van Smoorenburg, miquels@cistron.nl.\"}}}.\"{{{ See also.SH "SEE ALSO".BR shutdown (8),.BR init (8).\"}}}
⌨️ 快捷键说明
复制代码Ctrl + C
搜索代码Ctrl + F
全屏模式F11
增大字号Ctrl + =
减小字号Ctrl + -
显示快捷键?