News for hackers. Stuff that matters.
Re:Linux 4.5-rc5: efivarfs fixed to avoid “rm -rf /” brickin... by smaili on Monday February 22, 2016 @04:11PM (#11154331)
I've never actually seen or had the courage to attempt "rm -rf /". Does anyone know what would happen if it were run?
Re:Linux 4.5-rc5: efivarfs fixed to avoid “rm -rf /” brickin... by floatboth on Monday February 22, 2016 @05:20PM (#11154781)
You wouldn't be able to run any programs from the hard drive, and when you reboot, you'll end up with no operating system.

Unless you're running FreeBSD (or Illumos) with ZFS and Boot Environments, in which case you'd just select a backup boot environment and continue working :-) Probably without your home directory though, as that is usually excluded from boot environments. But you can set them up however you want.

But if you're running Linux (before this update) on a laptop with terrible piece of shit firmware, you'd end up with a brick.

P.S. found a cool post about rm -rf / in my bookmarks: https://lambdaops.com/rm-rf-remains/ – you can recover a running rm'd Linux machine by using a running shell and /dev/tcp :D

Re:Linux 4.5-rc5: efivarfs fixed to avoid “rm -rf /” brickin... by dingo_bat on Tuesday February 23, 2016 @07:35AM (#11158428)
I wanna try it out but I'm not brave enough to do it directly in my OS. WHat would happen if I did it in Ubuntu inside a VM? What if VirtualBox has mounted some directory on my system to the guest? I'm afraid to try this too :/

I once tried 'format C:' on a Windows 10 laptop I didn't care about and I just got a boring error message.

Re:Linux 4.5-rc5: efivarfs fixed to avoid “rm -rf /” brickin... by qb45 on Monday February 22, 2016 @06:21PM (#11155184)
> P.S. found a cool post about rm -rf / in my bookmarks: https://lambdaops.com/rm-rf-remains/ – you can recover a running rm'd Linux machine by using a running shell and /dev/tcp :D

Awesome. This dynamic loading of bash plugins is mad.

Re:Linux 4.5-rc5: efivarfs fixed to avoid “rm -rf /” brickin... by Symbiote on Monday February 22, 2016 @05:26PM (#11154818)
You get an error along of you're sure.

You should try

  rm --no-preserve-root -rf /
Re:Linux 4.5-rc5: efivarfs fixed to avoid “rm -rf /” brickin... by TazeTSchnitzel on Monday February 22, 2016 @04:46PM (#11154530)
You wipe your mounted disks.
Re:Linux 4.5-rc5: efivarfs fixed to avoid “rm -rf /” brickin... by qb45 on Monday February 22, 2016 @06:16PM (#11155155)
... and remote filesystems.