Linux - GeneralThis Linux forum is for general Linux questions and discussion.
If it is Linux Related and doesn't seem to fit in any other forum then this is the place.
Notices
Welcome to LinuxQuestions.org, a friendly and active Linux Community.
You are currently viewing LQ as a guest. By joining our community you will have the ability to post topics, receive our newsletter, use the advanced search, subscribe to threads and access many other special features. Registration is quick, simple and absolutely free. Join our community today!
Note that registered members see fewer ads, and ContentLink is completely disabled once you log in.
If you have any problems with the registration process or your account login, please contact us. If you need to reset your password, click here.
Having a problem logging in? Please visit this page to clear all LQ-related cookies.
Get a virtual cloud desktop with the Linux distro that you want in less than five minutes with Shells! With over 10 pre-installed distros to choose from, the worry-free installation life is here! Whether you are a digital nomad or just looking for flexibility, Shells can put your Linux machine on the device that you want to use.
Exclusive for LQ members, get up to 45% off per month. Click here for more info.
Recently I have bought an USB to IDE (cable + powersupply) to access my older harddisks. Unfortunately i cannot get my old IDE harddisk (used to be gentoo on it) to work with the USB-cable:
ubuntu@ubuntu:/$ sudo fdisk -l
Disk /dev/sda: 100.0 GB, 100030242816 bytes
240 heads, 63 sectors/track, 12921 cylinders
Units = cylinders of 15120 * 512 = 7741440 bytes
Disk identifier: 0x7e827e0d
Device Boot Start End Blocks Id System
/dev/sda1 * 1 4856 36703232 7 HPFS/NTFS
/dev/sda2 4856 12922 60980224 7 HPFS/NTFS
Disk /dev/sdb: 122.9 GB, 122942324736 bytes
255 heads, 63 sectors/track, 14946 cylinders
Units = cylinders of 16065 * 512 = 8225280 bytes
Disk identifier: 0x91b3b121
Device Boot Start End Blocks Id System
Mount gives the following message:
Code:
ubuntu@ubuntu:/$ sudo mount /dev/sdb /mnt/usbstorage
mount: you must specify the filesystem type
ubuntu@ubuntu:/$ sudo mount -t ext3 /dev/sdb /mnt/usbstorage
mount: wrong fs type, bad option, bad superblock on /dev/sdb,
missing codepage or helper program, or other error
In some cases useful info is found in syslog - try
dmesg | tail or so
dmesg
[ 751.565112] VFS: Can't find ext3 filesystem on dev sdb.
Important to know is that Gentoo on this harddisk has crashed (can't remember the reasons). My purpose is to get old data (photo's/music), that are still on this disc.
Can someone help me please? Maybe the partition table is broken?
By the way I am using ubuntu live CD
Thanks in advance for your help.
Does your USB to IDE thing work OK with other (good) disks?
If so, I suggest you read up on testdisk and photorec which both have good reputations for recovering data from partly broken, but still readable disks.
Do you have enough HDD space free to take a dd copy of your bad disk?
If so, I recommend you image it now. You probably should do this as root (so triple-check your commands before you press RETURN!):
Code:
dd if=/dev/sdb of=/home/me/baddisk.raw
Wait (maybe for quite a long time, depending on the size of your disk, and the speed of your interface (remember, USB is s-l-o-w)) while the disk is imaged.
Then you can play with your copy, leaving the original HDD unchanged:
Code:
mkdir /home/me/baddisk
mount -o loop /home/me/baddisk.raw /home/me/baddisk
Then you should be able to point photorec at /home/me/baddisk and it will behave as though it was looking at /dev/sdb
On the other hand, if you are certain it's just the partition table, you might want to run 'testdisk' (photorec's companion app) first on the disk to see if it can retrieve settings as you think are right. Notice running testdisk diagnosis is not destructive (no backup necessary) until you use "write".
Dear Tredegar, thanks for your reply and extensive explanation.
I followed your advice and download testdisk, excellent program by the way. Unfortunately the first analysis didn't found any lost partitions. I am now doing a deeper search, after that I will try the advanced superblock option.
I wonder if there is a problem with your interface hardware. What we have here, so far, is a clear inability to read the HD. The HD's firmware can be read, but an attempt to read the platter to get the MBR fails, as does (apparently) any attempt to read the platter to obtain partition information the hard way.
If I were you, I would put the drive into another machine and try to read it.
LinuxQuestions.org is looking for people interested in writing
Editorials, Articles, Reviews, and more. If you'd like to contribute
content, let us know.