On Wed, Jan 21, 2015 at 09:06:50AM +0200, ketmar via Digitalmars-d wrote: > On Tue, 20 Jan 2015 22:43:04 -0800 > "H. S. Teoh via Digitalmars-d" <digitalmars-d@puremagic.com> wrote: > > > I almost nuked my entire system with a mistyped `rm -rf` command, as > > I'm sure every *nix person has at least once in his life > my expirience was simply doing `chmod -R 600 /` as root. lucky me. and > i really hate that person who placed '.' and '/' next to each other.
Mistyping a recursive rm command is a relatively easy mistake, but there are worse things than that. One time, an OS upgrade gone wrong left me with my entire filesystem intact, but with a broken, non-functional ld. ... which meant *nothing* can run, because ld is called to dynamically link in libc, etc., for just about *everything* on the system. So, no rm, no ls, no mv, no chmod, etc., etc.. This was on a remote server, too, and the only connection to the box that I had left was just the last ssh bash session to the box. One mistake, and it's bye-bye server. :-P To recover from that, I had to do this: http://eusebeia.dyndns.org/bashcp It was the most intense few hours, I tell ya, when I had to rescue the system from the brink of reinstallation from scratch back to a functioning system without losing any data. Now try that on Windows. :-D > ah, and once i accidentally did dd the wrong way and rewrote my > harddrive with contents of flash pen. Ouch! On a lighter note, one time I almost peed my pants when, after installing a major OS upgrade, I rebooted and got a kernel panic. (I also made the mistake of having no backup boot media, so there was no other way to get into the system to fix things.) I thought something serious had gone wrong with the upgrade, but fortunately, it turned out that the problem was that I had previously moved my main OS installation to a non-default root (/dev/sdc1 instead of the usual /dev/sda1), but had forgotten to update the bootloader to point to the new root (and didn't notice 'cos Linux tends to just run forever, so it was like 6 months later before this problem finally reared its ugly head). So when the kernel came up it tried to mount root from /dev/sda1 and couldn't, it panicked. Rebooting with the root=/dev/sdc1 parameter saved the day. :-P > > In many ways it's like D... in spite of all its niggling little > > problems, once I tasted the power of D, I just can't go back to > > C/C++ anymore. I used to take pride in being the resident C/C++ > > guru, but nowadays, doing C/C++ is like scratching on chalkboard. > > I'll do it if I have to (my employer pays me to do it, so I tolerate > > it), but I'd never do it again voluntarily. D has ruined my life; I > > just can't do C/C++ anymore. :-P > > it's almost the same for me. i hate alot of small things in D (that's > why i'm so passioned about them), but i just can't return to C/C++ > anymore! it's like going back to MS-DOS. ;-) despite all annoyances D > managed to get the main thing right -- thanks to all people that made > it possible. +1. T -- I see that you JS got Bach.