shutdown Linux Commands – Overview with Examples and FAQs

Introduction

Linux shutdown is a command used to shut down or reboot a Linux system. It is used to power off the system, halt the system, or reboot the system. It can also be used to schedule a shutdown or reboot at a specific time. The shutdown command is available in all versions of Linux, including Ubuntu, Debian, CentOS, and Red Hat. It is a powerful command that can be used to manage system resources and ensure system security.

Examples

The shutdown command is used to shut down or reboot a Linux system.

Syntax:
shutdown [OPTION] [TIME] [MESSAGE]

Options:
-h, –help: Display help information
-r, –reboot: Reboot the system
-k, –poweroff: Power off the system
-c, –cancel: Cancel a pending shutdown
-P, –poweroff: Power off the system

Examples:

1. To shut down the system immediately:
$ shutdown -h now

2. To shut down the system in 10 minutes:
$ shutdown -h 10

3. To reboot the system in 5 minutes:
$ shutdown -r 5

4. To cancel a pending shutdown:
$ shutdown -c


Shutting down a Linux system is a straightforward process. The command to shut down a Linux system is shutdown. This command can be used to shut down the system immediately, or to schedule a shutdown for a later time.

The basic syntax for the shutdown command is:

shutdown [options] [time] [message]

The options argument can be used to specify how the system should be shut down. The available options are:

  • -h : Shut down the system immediately.
  • -r : Reboot the system immediately.
  • -c : Cancel a scheduled shutdown.

The time argument is used to specify when the system should be shut down. This can be specified as a number of minutes, or as a specific time in the format hh:mm. If no time is specified, the system will be shut down immediately.

The message argument is used to specify a message that will be displayed to all users before the system is shut down. This is optional, and can be used to provide information about why the system is being shut down.

For example, to shut down the system immediately, the following command can be used:

shutdown -h now

To schedule a shutdown for 10 minutes from now, the following command can be used:

shutdown -h 10

To schedule a shutdown for 8:00 PM, the following command can be used:

shutdown -h 20:00

To cancel a scheduled shutdown, the following command can be used:

shutdown -c
Jaspreet Singh Ghuman

Jaspreet Singh Ghuman

Jassweb.com/

Passionate Professional Blogger, Freelancer, WordPress Enthusiast, Digital Marketer, Web Developer, Server Operator, Networking Expert. Empowering online presence with diverse skills.

jassweb logo

Jassweb always keeps its services up-to-date with the latest trends in the market, providing its customers all over the world with high-end and easily extensible internet, intranet, and extranet products.

Contact
San Vito Al Tagliamento 33078
Pordenone Italy
Item added to cart.
0 items - 0.00
Open chat
Scan the code
Hello 👋
Can we help you?