Hacker Newsnew | past | comments | ask | show | jobs | submitlogin

molly-guard is an good way to prevent this - forces you to type in the hostname of the machine you are trying to halt / restart etc.

http://manpages.ubuntu.com/manpages/trusty/man8/molly-guard....



Excellent if you have complete and thorough control of every server you touch, but if you don't, it could be dangerous to rely on. Murphy's Law means it'll be that one dang machine that gets shut down...

Personally, I'd think that training this is a lot more portable.

  # hostname
  <foo>
  # shutdown -h now




Consider applying for YC's Winter 2027 batch! Applications are open till November 2.

Guidelines | FAQ | Lists | API | Security | Legal | Apply to YC | Contact

Search: