Raspberry Pi 1 Model A running Raspbian Stretch Lite here. What's the preferred method for elegantly shutting down the pi (so that all services shut down correctly & safely, etc.)?
Looks like I have several options:
sudo shutdown -h now
sudo shutdown -P now
sudo poweroff
sudo halt -p
sudo init 0
Or I could just unplug the power and let it crash (I don't like this method).
Ideally my teardown procedure would be something like:
- When I'm ready to shut it down, SSH into the RPi
- Issue some command (see above -- any ideas?) to shut it down
- Wait for all the onboard lights to turn off
- Unplug the power (Micro USB) safely
Just wondering if there is a preferred/best practices way to go about this.