Home Interests Raspberry Pi

Don’t Pull the Plug: How to Safely Shut Down or Reboot Your Raspberry Pi

howchoo   (467)
September 12, 2023
3 minutes

Share

You'll Need 1

What you'll need
Interests
Howchoo is reader-supported. As an Amazon Associate, we may earn a small affiliate commission at no cost to you when you buy through our links.
Posted in these interests:
pi • 92 guides

Like any computer, simply pulling the plug on your Pi can have dire consequences; but unlike most computers, the Raspberry Pi does not have a native power button. The following commands should be used to safely shut down or reboot your Pi. Obviously, these commands should be run from the command line. Note: You must have sudo privileges to run sudo commands. The default raspberry pi user has such privileges so this shouldn’t be an issue unless you’ve drastically altered your Pi’s user configuration.

1 – Shutdown command

sudo halt

This is shorthand for the following:

sudo shutdown -h now

An explanation:

sudo - run the command as superuser
shutdown - shut down the pi
-h - halt after shutting down (do not reboot)
now - do this now (required time command)

2 – Reboot command

sudo reboot

This is shorthand for the following:

sudo shutdown -r now

An explanation:

sudo - run the command as superuser
shutdown - shut down the pi
-r - reboot the pi after shutting down
now - do this now (required time command)

3 – Using a power button

You can also safely shut down the Pi by adding a Pi power button!

How to Add a Power Button to Your Raspberry Pi
Because you should always safely shut down your Pi.

NEXT UP

How to Run a Minecraft Server on the Raspberry Pi

A whole world trapped inside your Pi.
howchoo   (467)
December 7, 2023

There are several ways to go about running a Minecraft server on the Raspberry Pi. In this guide, I’ll cover how to install Nukkit—a cross-platform Minecraft server that’s super easy to set up on the Raspberry Pi. This server should work with PCs, consoles, and tablets running Minecraft 1.14. I’ll be using a Raspberry Pi

Continue Reading

howchoo

 467 guides

Introducing Howchoo, an enigmatic author whose unique pen name reflects their boundless curiosity and limitless creativity. Mysterious and multifaceted, Howchoo has emerged as a captivating storyteller, leaving readers mesmerized by the uncharted realms they craft with their words. With an insatiable appetite for knowledge and a love for exploration, Howchoo's writing transcends conventional genres, blurring the lines between fantasy, science fiction, and the surreal. Their narratives are a kaleidoscope of ideas, weaving together intricate plots, unforgettable characters, and thought-provoking themes that challenge the boundaries of imagination.

Discover interesting things!

Explore Howchoo's most popular interests.

Explore