Linux - HardwareThis forum is for Hardware issues.
Having trouble installing a piece of hardware? Want to know if that peripheral is compatible with Linux?
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.
Introduction to Linux - A Hands on Guide
This guide was created as an overview of the Linux Operating System, geared toward new users as an exploration tour and getting started guide, with exercises at the end of each chapter.
For more advanced trainees it can be a desktop reference, and a collection of the base knowledge needed to proceed with system and network administration. This book contains many real life examples derived from the author's experience as a Linux system and network administrator, trainer and consultant. They hope these examples will help you to get a better understanding of the Linux system and that you feel encouraged to try out things on your own.
Click Here to receive this Complete Guide absolutely free.
Not sure what the user did but I've got a 2TB drive that is not playing nice.
Western Digital WD2001FASS 2TB drive
was formatted with a single ext3 partition
When I run off System Rescue CD x86 with the drive connected, fdisk shows the partition still there but I cannot do anything else.
e2fsck results in:
fsck.ext2: Superblock invalid, trying backup blocks
fsck.ext2: Bad magic number in super-block while trying to open /dev/sda
Superblock could not be read or does not describe a correct ext2 filesystem.
I also ran mke2fs -n on it and it provided a long list of superblocks available but when I run e2fsck -b with the block specified, it still says "Superblock invalid".
Is there any hope of recovering the data on this drive or is this a lost cause?
How important is the data on the disk? Your best chances of recovery without further damage to the disk are to first do a bit-by-bit copy of it to a second drive. Then work on the copy, preserving the original in it's current shape in case you need to go back and start over. Buying another 2Tb disk may cost more money than you're willing to spend to recover this data.
You said the disk was formatted as a single ext3 partition. I assume the user told you this? The same user that somehow screwed up the data without knowing what happened? I would take what they say with a grain of salt - definitely consider the experience level, and honesty, of your user. Did they possibly change the partitions and then come to you for help without mentioning the "embarassing" stuff they did? I've seen it happen.
On the copy disk, I would first try running "testdisk" to see what it comes up with for previous partitions. You can also use "photorec" (it's not just for photos) to recover files from a partitionless disk. If you run photorec, you will need a place for it to store the recovered files. So that means ANOTHER hard disk. So this could get expensive if you don't have all those spare 2Tb hard disks laying around. Is the data worth it?
As haertig mentioned, *testdisk* is what you should try first. It's a *very* powerful tool if you're patient enough (as you might have to test many different configs). And it will always prompt you before actually writing changes to disk. I've used it (successfully) several times and I was amazed each time. Just make sure you read the doc and examples (http://www.cgsecurity.org/wiki/TestDisk) because the interface is a little bit 'spartan'.
I like photorec, although on a disk that has had multiple installs, you will grab everything from your current data, along w/ data from old installs that has not been overwritten yet. It can be frustrating trying to sort out what is what.
It took me about 6 days to creep through 75% of a 500 meg sata drive til I came to the conclusion my data wasn't worth it. Also you will have to develop skills w/ grep and file carving (which is not exactly learned overnight), to find a handful of files you need, inside millions of random documents/files.
Also be careful that you do not exhaust your existing inodes if saving the recovered files to an disk w/ data on it already. Disks of same size can have different numbers of inodes.
I like photorec, although on a disk that has had multiple installs...
Agreed. If this was a disk with an OS installed on it, it would probably be unmanageable. But if it was a "personal data disk", containing just photos, mp3's, etc., then using photorec becomes much more realistic.
Ran testdisk and it was able to allow me to mount the partation but no files were present.
I'm giving photorec a shot now and see if there might be a glimmer of hope. If not, I'm throwing in the towel. It's just not that important to me and now it's more of a exercise to learn something new (photorec and testdir are handy tools).
Besides, the user decided to insult me, all my hard work, and effort today. Even if I can recover some files, they will be lucky to actually get them back at this point. I seriously dislike people that act that way.
Besides, the user decided to insult me, all my hard work, and effort today.
Download some porn files, burn them to a CD, then go over to his house to show him the miracles you have completed. But make sure his wife is there at the computer with you guys as you proudly display all the recovered files ... in a cycling slideshow program that you unfortunately forgot how to exit out of!