Debian GNU/Linux and world domination
The power and flexibility of Debian GNU/Linux never ceases to amaze me.
My root file system suffered from an unrecoverable partial failure yesterday. That resulted in a number of files in the /sbin directory being inaccessible. I know, with all the non vital directories in a file system, why is it that the most critical ones get hit the most?
Well, better /sbin than /home, right?
Anyway, the first thing I did was to boot off Knoppix and back up the entire contents of the hard drive, partition by partition. I used a combination of tar and ssh, partimage, rsync, and good old dd.
"What, you did not have backups already?" - I hear you ask. Well, you know, real men do not keep backups :-)
Then, I popped in the netinst cd and kicked off Debian's installation. After the base system installed, I instructed dpkg to select all the packages that were previously installed in my compromised system with a single command:
dpkg --set-selections < selections.txt
where the selections.txt is a text file containing a list of debian packages and their status (e.g. install, purge, etc.)
This list can be easily generated using:
dpkg --get-selections "*" > selections.txt
In this case, I actually had to use `chroot' since my system would not boot and the system's root file system had been mounted under /mnt/hda2 within Knoppix.
To cut a long story short, apt-get install.
Once that completed, everything was back to normal. My home directory, with all its contents, was untouched. My configuration files and settings, stored in my home directory (which resides in a different partition), were preserved.
Being able to recall previous commands from bash after completely reinstalling your system gave me a warm fuzzy feeling.
Same when I fired up Firefox and discovered that all my bookmarks a nd history were preserved. Heck, I did not even have to log in to multithread.org, since the cookie was still there.
In case anyone wonders, the file system in question was ReiserFS 3.6. I have decided to revert back to ext3.
I have used ReiserFS for a few years and have had a number of mishaps with it (topic for the next post??), so I thought it might be wise to give ext3 a go.
No, my decision was not influenced by these recent events.
To sum it up, from a disatrous failure to a fully functional and virtually unchanged system in a couple of hours. Amazing.
Why anybody would choose to use an inferior and proprietary operating system is beyond my comprehension. I understand that some people might be forced to use a Windows operating system, for a number of reasons, i.e. the operating system is mandated by the employer, need for a proprietary application, etc.
However, I cannot condone someone who would persist in using Windows when having the freedom to make the switch.
But this is a different story.
- Matteo Vescovi's blog
- Login to post comments