- slug
mullyguard
- tags
Ubuntu, Debian, server
- date
2010-12-23
- category
System Administration
Having a Molly Guard to protect your servers from accidental shutdows is woth a lot, once you've tried to do it to the wrong machine:
sudo reboot
- Discovering you're on a remote production server, instead of somewhere else...
- SHIT! SHIT! SHIT! - wrong machine! OMFG!
First, install molly guard:
sudo apt-get install molly-guard.
It basically aliases reboot
, halt
, shutdown
and friends to a small script that first checks if you're on a remote connection. So next time your'e about to do something really stupid on a remote machine, molly-guard kicks in:
sudo reboot
W: molly-guard: SSH session detected!
Please type in hostname of the machine to reboot: