PDA

View Full Version : Recover laptop (only knoppix seems to work!)



foxdog27
12-06-2005, 02:20 PM
Hello, and apologies if this is an inappropriate forum for this post. I'll try and be as brief as possible in describing my computer problems, as they have been going on for some time now:

I have a laptop (IBM thinkpad T22, 900Mhz 256 RAM), which had XP on it. Some months ago, out of the blue, it froze during boot-up (progress bar stopped moving). I could boot-up in safe mode, and access hdd etc. Without pausing to think (my usual problem!) I whipped my XP disk into the machine and before I knew it was in the process of re-installing XP. A mistake, as during the installation got the same boot-up freeze, and could no longer do a safe mode boot-up. Put windows 98 SE disk in, booted from this, tried "fdisk /mbr", got the "abort, retry fail" message!

So, knoppix time: put my trusty knoppix CD in (forget the version, but was prior to 3.9), and... also failed. Machine froze at the "autoconfiguring devices" bit. Tried all the failsafe boot-up options etc, same problem every time.

Next, went into BIOS (could read hdd no problems), tried the Ultimate Boot cd (UBCD), ran diagnostic on hdd, was ok. Swapped out hdd for other drive, same problems.

Then, downloaded the knoppix 3.9 CD, and it worked fine! Everything was ok, could access the hdd. Breathed a sigh of relief, whipped my wedding photos off the drive, did nothing until saw that there was now a dvd knoppix, with R on it (am statistician, so this meant could again use laptop for work). Knoppix DVD 4.02 works great. Decided no need to go back to xp ever, and thought I'd try installing suse linux 10.0 (naively believing all problems would be gone with a recent linux installation). But suse linux installation also froze, after the first screen (if you are familiar, choose installation from menu, it then loads linux kernel, next screen after that was the freeze).

At this point, used ubcd to completely wipe hdd and boot sector. No help. Realised I could no longer access hdd in knoppix, instead got message "Could not mount device, The reported error was, mount mount point /mnt/hda1 does not exist".
In knoppix, (probably shouldn't have done this, but figured what further harm could happen?!), as root ran "fdisk /dev/hda"
chose to write a new partition, primary, default settings for first and last cylinder, the whole lot. There was a warning for this: "Warning: invalid flag 0x0000 of partition table 4 will be corrected by w(rite)". I w(rote). Still couldn't access hdd. Finally, tried "mkfs.ext2 -c /dev/hda1". This didn't complain, but mentioned 752 bad blocks, anyway, rebooted, tried to mount hdd and got different error: "mount wrong fs type, bad option, bad superblock on /dev/hda1, missing codepage or other error". Followed advice to check for more info using "dmesg | tail", got lots but error stuff seemed to be: "NTFS-fs error (device hda1): read_ntfs_boot_sector(): Primary boot sector is invalid. NTFS-fs error (device hda1): read_ntfs_boot_sector(): Mount option error=recover not used. Aborting without trying to recover. NTFS-fs error (device hda1): ntfs_fill_super(): Not an NTFS volume."

Anyone still here will have realised I don't know much and am just blundering along. Any ideas as to what the problem is would be great, and ideas on how to fix it and I will be over the moon!!

Cheers,
Rob.

rusty
12-06-2005, 03:07 PM
I'm not familiar with the ubcd but it doesn't look like it wiped your drive,

From a root shell in knoppix type dd if=/dev/zero of=/dev/hda, and wait until it finishes, which could be a while depending on the size of the drive. That will hose the drive completely. Then try creating a partition with fdisk or qtparted and see if it works.

Remember to write a new empty DOS partition table ( option o in fdisk) before creating the partitions and writing the table to disk.

HTH

OErjan
12-06-2005, 06:57 PM
in adition to rustys suggestion, making a complete check of the filesystem might be a good idea, those bad blocks... that does not sound good to me.
If it was me I would make the filesystem (I will use EXT3 but...) and scan it thuroughly for bad blocks.

mkfs.ext2 -b 4096 -c -j m 1 /dev/hda1&&e2fsck -cfkpv /dev/hda1
this will take a l o o o o n n n g time, but it will scan for bad blocks and mark any found as bad...
you might ave to make a "checked" swapspace aswell.
mkswap -c /dev/hda2 will scan for bad blocks and make a swap partition on hda2.

ah, just a sidenote, I would make two regular linux partitions one / other /home. then I can wipe / and still have my own files in /home intact.

foxdog27
12-07-2005, 03:11 AM
Thanks rusty, OErjan. I've tried both your suggestions, unfortunately without success. rusty, when I did the "dd if=/dev/zero of=/dev/hda", there was a couple of times that the hdd made that ominous clickng noise. OErjan, after doing "mkfs.ext2 -b 4096 -c -j -m 1 /dev/hda1&&e2fsck -cfkpv /dev/hda1", I did successfully mount the hdd, although it took a long time. After rebooting though, it was again unmountable. Seems to be recognised, just not accessable. I would be strongly tempted to just buy a new drive, if it wasn't for the time I swapped out the drive and no problems were solved. Still different problems, a while ago now. I'll probably stick with the current situation (knoppix 4.0.2, doing work on a flash-card) rather than fork out cash and not solve the problem. One last request -- if either of you can think of a way someone with a knack for getting things wrong could have attempted to faithfully follow your instructions yet still mess it up, it would be great if you'd let me know. Basically, this is exactly what I did, in order:

"fdisk /dev/hda" => "o" (dos partition) => "w" write.
"fdisk /dev/hda" => "n" (add new partition) => "p" (primary) => "1" => defaults for begin and end => "w" (write)
"mkfs.ext2 -b 4096 -c -j -m 1 /dev/hda1&&e2fsck -cfkpv /dev/hda1"

Cheers,
Rob.

rusty
12-07-2005, 05:15 AM
Hmm,

At this point I'm inclined to think that this is a hardware problem, either a bad drive or bad controller. I've seen similar on T20 of that vintage. In the end, the owner just stopped using it , except as you are doing now. It seemed to me that the connection (the bus) was flakey. Intermittently working, then not. If it is the controller or a connection problem then the purchase of a new drive would not be worthwhile.

Knoppix is a great way to get some more use out of the old lappy, enjoy!