I would like to reformat my hard disk, and if possible recover the (somewhat unimportant) contents if possible.
I have a Western Digital 1TB hard drive which had a NTFS partition.
I unplugged the drive without safely removing it first.
At first a pop up was asking me to use a Windows OS to run the chkdsk /f command, however, in the effort to keep using a Linux OS I used the ntfsfix command on the ubuntu terminal
Now, when I try to access the hard drive, it doesn't show up anymore in Nautilus.
I tried reformatting it using Disk Utility, but it gives me an error message, and Gparted would hang on the "Scanning devices" step infinitely.
Please comment any output that you would like to see and I will add it to my question.
EDIT
disk utility tells me is on /dev/sdb
the command sudo fdisk -l gives
dodohjk@DodosPC:~$ sudo fdisk -l
[sudo] password for dodohjk:
Disk /dev/sda: 250.1 GB, 250059350016 bytes
255 heads, 63 sectors/track, 30401 cylinders, total 488397168 sectors
Units = sectors of 1 * 512 = 512 bytes
Sector size (logical/physical): 512 bytes / 512 bytes
I/O size (minimum/optimal): 512 bytes / 512 bytes
Disk identifier: 0x0006fa8c Device Boot Start End Blocks Id System
/dev/sda1 * 4094 482344959 241170433 5 Extended
/dev/sda2 482344960 488396799 3025920 82 Linux swap / Solaris
/dev/sda5 4096 31461127 15728516 83 Linux
/dev/sda6 31463424 52434943 10485760 83 Linux
/dev/sda7 52436992 62923320 5243164+ 83 Linux
/dev/sda8 62924800 482344959 209710080 83 Linux
Disk /dev/sdb: 1000.2 GB, 1000202043392 bytes
255 heads, 63 sectors/track, 121600 cylinders, total 1953519616 sectors
Units = sectors of 1 * 512 = 512 bytes
Sector size (logical/physical): 512 bytes / 512 bytes
I/O size (minimum/optimal): 512 bytes / 512 bytes
Disk identifier: 0x6e697373
This doesn't look like a partition table
Probably you selected the wrong device. Device Boot Start End Blocks Id System
/dev/sdb1 ? 1936269394 3772285809 918008208 4f QNX4.x 3rd part
/dev/sdb2 ? 1917848077 2462285169 272218546+ 73 Unknown
/dev/sdb3 ? 1818575915 2362751050 272087568 2b Unknown
/dev/sdb4 ? 2844524554 2844579527 27487 61 SpeedStor
Partition table entries are not in disk orderI wrote something wrong here, however here the output of fsck /dev/sbd is
dodohjk@DodosPC:~$ sudo fsck /dev/sdb
fsck from util-linux 2.20.1
e2fsck 1.42.5 (29-Jul-2012)
ext2fs_open2: Bad magic number in super-block
fsck.ext2: Superblock invalid, trying backup blocks...
fsck.ext2: Bad magic number in super-block while trying to open /dev/sdb
The superblock could not be read or does not describe a correct ext2
filesystem. If the device is valid and it really contains an ext2
filesystem (and not swap or ufs or something else), then the superblock
is corrupt, and you might try running e2fsck with an alternate superblock: e2fsck -b 8193 <device> 5 3 Answers
You can try installing testdisk. Sometimes it fixes problems other software can't. Becareful though it is pretty hardcore. Google around to see how it works.
1Note: This is a stale post, so I assume it's already resolved, but here are my thoughts in case they help someone else:
Data Recovery prospects: terrible
Since ntfsfix didn't help, using a Windows utility like chkdsk is really your best bet, but I wouldn't anticipate success.
The sfdisk output seems to indicate that the partition table is corrupt. It shows (apparently) a large primary partition and a logical partition with two logical volumes, but the partition numbers and file system types are wrong. The only encouraging part is that the sizes and layout are reasonable.
The fsck.ext2 output is meaningless for two reasons.
- You ran it on the device instead of a parition, e.g.,
/dev/sdbinstead of/dev/sdb1 - This is an ntfs partition,
fsck.ext2is the wrong tool.
Formatting prospects: health check required
The partition map corruption is worrisome. I'd use a tool like gnome-disk-utility that will run the short SMART test and show general health, and let you format it. If that doesn't work, the drive is probably toast.
Several years ago, I experienced a hard drive failure. I was at work when my laptop suddenly started to act particularly strange. First, I thought it was because I had too many windows open and the RAM was full, but when the problems persisted after a reboot, I knew it was more than that. I immediately started to back up recent files. About half an hour later, the hard drive failed audibly and the laptop wouldn’t boot anymore.
If your hard drive has failed physically, maybe this little guide can help you or at least give you some hope. So roll up your sleeves and get to work.
- External Hard Drive? Check Whether The IDE / SATA to USB Enclosure is ok or not
- Internal Hard Drive? Make Sure The Hard Drive Connections are ok or not
- Check the sound
- Is The Hard Drive Recognized?
- Is The Printed Circuit Board Broken?
- Witchcraft & Wizardry
- Consult with a specialist for professional data recovery
Diagnosing and fixing a broken hard drive is serious business. Do take it seriously, but also try to exclude some of the more simple to fix culprits before you fork out hundreds of dollars to a so-called specialist. The more informed you are, the better. How far you go to diagnose and fix your hard drive will depend on how important the data is for you.
1