I had a feeling this would be happening soon. About a week ago I noticed some strange "plink" sounds coming from the machine and I assumed it was the hard drive. But the system was still working fine. Nevertheless, I thought it would be a good idea to back up the web server. So copied it all to a folder on my PC's desktop.
Good thing. :)
So when I found the machine not responding, I opened the closet and saw that the HDD light was on steady. Hmm. Well I don't have a monitor or keyboard hooked up to the machine over there, so I couldn't tell what had happened last. I couldn't connect via SSH either.
Well I thought maybe I could see what's going on if I hook up my old TVator box and run the composite video line across the room to my TV. It took me a half hour to find the TVator, but I finally did, and hooked it up, to find that the screen was black. Either the TVator wasn't working or there was no video signal coming from the machine. In any case, I decided to just cycle the power.
So it's rebooting and I see that there's still no video on the TV, so I figure the TVator must not be working, because I should at least see the BIOS flash screen. After the machine settles down I tried accessing it through the network again. Still nothing. Now I'm thinking there must be a serious error and Linux won't even boot...
I have to find some way to hook up my monitor to the machine to see what's going on. (But I don't want to move it and it's too far, you see.) I thought I'd try using my A/B switch box to join two lengths of VGA cable together and maybe that will be enough to reach the monitor. Well it was close enough - I had to move the machine slightly out of the closet. And what do I see?
In the very first start-up screen, the BIOS goes through the IDE channels and reports what it finds. Well, this time it found something. The hard drive's S.M.A.R.T. status was "BAD". It spit out a line suggesting I backup and replace the drive, then told me to press F1 to continue. So I figure this is a warning message and maybe the drive still works (otherwise they wouldn't be so stupid as to suggest backing it up, if it was known to be dead, right?) ... but now I had to dig out an old keyboard to hook up to the machine, too.
So my room turns into a big mess.
I hook up a keyboard and press F1 and Linux starts booting up... Yay! But since the last shutdown was abnormal (read: power cut) it did an automatic File System ChecK ("fsck") and started finding errors and fixing them. It fixed 7 errors, then reported a more serious error and said I should run fsck manually, and gave me a prompt to log in as root with the file system in read-only mode.
Well, I haven't done that yet, but I predict it will find a whole bunch of errors and the file system will probably be so corrupted that I wouldn't want to copy it to a new drive. This means re-installing Linux, to which I am not looking forward.
Well I knew I'd need a new drive in any case, but all I have are the two 20GB IBM drives that gave me problems a while back. They went kooky on me when I tried to slave them either together or to/from other drives to copy data, and some data on the drive ended up being lost. But I ran IBM's Drive Fitness Test cleaner on them and now they pass the test, so I'm thinking it's ok to use them (heck, one was hardly used).
Just to make sure, I thought I should run DFT again on the drive I'm going to use, so I did, and it passed the thorough test. Plus the old drive is slaved to it and it still works. So that's good.
Now I need to decide if I want to boot Linux and see what the manual fsck reports.
I really should just install Linux fresh on the new drive, but I really don't trust myself to do it right. The first time I tried, I made a mess, and my friend Dan came over and redid the whole thing for me.
Heck, let's put it to a poll. :) The important data is backed up and can be copied back over. So it's just a matter of whether I should deal with the old drive or not. What do you think?
How should I fix my Linux box?
Install fresh on the new drive. Don't even look at that old drive.
At least run the manual fsck and see if the OS still works on the old drive.