Post on 08-May-2015
description
No.43 HOW NOT TO DELETEYOUR IMPORTANT FILES
François Marier <francois@safe-rm.org.nz>
tl;dr
apt-get install safe-rm
story
$ rm -rf /usr/lib/junk
$ rm -rf /usr/lib/junkrm: cannot remove `/junk':No such file or directory
$ rm -rf /usr/lib /junkrm: cannot remove `/junk':No such file or directory
recovery
1- swear alot#%@ !!!☠✮
1- swear a lot
2- reinstall dpkg
1- swear a lot
2- reinstall dpkg
3- reinstall apt
1- swear a lot
2- reinstall dpkg
3- reinstall apt
4- list installed packages
1- swear a lot
2- reinstall dpkg
3- reinstall apt
4- list installed packages
5- reinstall all packages
/bin/etc/home/francois/usr/bin/usr/lib
safe-rm
/usr/bin/rm
PATH="/usr/bin:/bin"
/bin/rm -rf /usr/lib
$ rm -rf /usr/lib
$ rm -rf /usr/libsafe-rm: skipping /usr/lib
/bin/boot/dev/etc/home/initrd/lib/proc/root/sbin/sys/usr
/usr/bin/usr/include/usr/lib/usr/local/usr/local/bin/usr/local/include/usr/local/sbin/usr/local/share/usr/sbin/usr/share/usr/src/var
/etc/safe-rm.conf
~/.safe-rm
apt-get install safe-rm
www.safe-rm.org.nz
THE END
Copyright © 2012 François Marier <francois@safe-rm.org.nz>This work is licensed under a Creative Commons
Attribution-ShareAlike 3.0 Unported License.