Easy to master Linux shutdown restart command _linux Shell

Source: Internet
Author: User

There are shutdown, halt, reboot, Init for Linux down and restart systems, and their internal processes are different for them.

Another year, into 2010 years, in the last year maybe Microsoft grabbed the halo of Linux, but for the development of less than a long time Linux, can stand firm in front of Microsoft, very simple. In fact, Linux is getting hotter, and many computer users have Linux installed. For those Linux beginners, this article will give you a detailed introduction to Linux Shutdown command, for you to learn the Linux shutdown command to play a role.

1, Shutdown command

Use it to safely shut down the system, however, when the system is shut down, all logged-in user systems are notified that the system will be shut down, and all instructions will be frozen, that is, all new users will no longer be able to log on, and use the directive to immediately turn off or reboot and delay the shutdown or reboot for a period of time. (Note: Only super users can use this command)

Command syntax format:

shutdown [options] [TIME] [warning message]

The meanings of the options in this command are described:

-K: Just send a warning message to the user

-R: Reboot the system after shutting down the system

-H: Do not reboot the system after shutting down the system

-F: Fast shutdown of the system, but no disk detection on reboot (the system was found to enter the BIOS interface during the experiment, but no action was possible)

-N: Quickly shutdown the system without the INIT program shutdown

-C: Interrupt shutdown system (no specific How the experiment was found)

2, Halt command

Using the halt command is to invoke the "shutdown-h" command to perform the shutdown system

command syntax format;

Halt [Options]

-W: Not really shut down the system, just write "wtmp" (/var/log/wtmp) records

-D: Do not write "wtmp"

-F: Not calling "shutdown" but forced shutdown

-I: Turn off all network UO interfaces before shutting down the system or rebooting the system

-P: This option is the default option, call "power off" when the system is shut down

3, Reboot command

The reboot command works like the halt command, but reboot initiates a host reboot. All of its parameters are similar to "halt".

4. Init command

The above content is small set to share the easy Master Linux shutdown Restart command of all the narration, I hope you like.

The init command uses the system's operating level control system. It is the ancestor of the process of all systems, its process number is always 1, so sending "TERM" signals to Init will terminate all user processes and daemons, and "shutdown" is the use of this mechanism. Init 0 is shutting down the system, init 1 restarts the system.

Related Article

Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.