Follow TV Tropes

Following

Discussion SchmuckBait / RealLife

Go To

You will be notified by PM when someone responds to your discussion
Type the word in the image. This goes away if you get known.
If you can't read this one, hit reload for the page.
The next one might be easier to see.
Nigel Since: Aug, 2012
Jan 13th 2013 at 8:10:57 AM •••

Re the Unix rm-rf /;

At a place where I worked as a Unix system administrator, a man managed to change the permissions on every file and directory on a Unix box with one mistake in a command. Working as root, he had just created a filesystem, just below the root directory and loaded quite a few files into it. He wanted to change the permissions on all the files and directories to rwxr-xr-x, including a large number of files with a dot as the first character in the name, and so went to the top of the filesystem and entered the command

chmod -r 755 * .*

What he failed to consider is that one of the expansions of ".*" is "..", and ".." was, of course, /

It took over a day and a half to fix this. Incidentally, he turned off all setuid and setgid, named pipes and so on because chmod 755 is actually interpreted as chmod 0755, and the first byte of the permissions has the setuid and setgid permissions.

Top