[Linux] shutdown and restart commands

Source: Internet
Author: User
Linux has the following shutdown and restart commands: shutdown, reboot, halt, and poweroff. What are the differences between them? Shutdown-the recommended command shutdown is the most common and secure command for shutdown and restart. it will call fsck to check the disk before shutdown.

Linux has the following shutdown and restart commands: shutdown, reboot, halt, and poweroff. What are the differences between them?

Shutdown-the recommended command shutdown is the most common and secure command for shutdown and restart. it will call fsck to check the disk before shutdown, among them,-h and-r are the most common parameters:
-H: Stop system service and shut down-r: Stop system service and restart
The following are examples:
Shutdown-h now -- immediate shutdown-h -- to shutdown, if this time is less than the current time, then shutdown-h + 10 -- shutdown automatically after 10 minutes-r now -- restart shutdown-r + 30 'The System Will Reboot in 30 mins' -- restart and and send notifications to other online users.

Reboot indicates immediate restart, equivalent to shutdown-r now
Poweroffpoweroff indicates immediate shutdown. The effect is equivalent to shutdown-h now. it is not recommended in multi-user mode (Run Level 3.
Halt does not care about the current system conditions, hardware shutdown is generally not recommended
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.