03/29/2010: "MybookWorld woes"
So a while back I bought a 1tb mybookworld drive to store all my data in what I thought would be a secure and reliable solution. Well, about a month ago the drive crashed and I came close to losing all my data. I had the blue rings 2x500gb drive and unfortunately I had it set at raid0, meaning it was a 1tb linear drive (no redundancy). Well, I had a power failure and one of the drives got corrupted. The western digital software would not let me access my data as it thought one of the drives had failed. After much searching and some experimentation I was able to determine that the drive had not failed, it had just lost some data on one of the partitions. Anyway, after much searching I was able to find a solution and I thought I'd share it.
I required the following:
A drive large enough to backup all of the files (in my case about 360gb)
2 usb sata controllers (or a desktop that will allow you to plug in the drives internally)
Basically you need to plug in both of the drives while running linux and tell the computer to look at the 4th partition on each drive as a single linear space. Once I was able to do that I plugged in the new backup drive and copied everything over. After that its just a matter of reformatting the bad drive and starting over. It sounds simple, but was far from it. I was able to find instructions over at wikidot that eventually worked. The first set helped me access my files and the second to rebuild the drive when the western digital software was unable.
Basically I used these commands:
$ sudo mknod /dev/md4 b 9 4
$ sudo apt-get install mdadm
$ sudo mdadm --assemble /dev/md4 /dev/sdb4
$ sudo mkdir /media/xyz
$ sudo mount /dev/md4 /media/xyz
$ sudo chmod -R 777 /media/xyz
One of these commands didn't work, so I had to change the root password and login... luckily there were instructions further down the page
this is to change the root password so you can su to change to root
use your newly created root password
search in /dev is there a mount of sdb4
#ls /dev | grep sd
if you can see it on the list
then continue with
#mdadm -Cv /dev/md4 -l1 -n2 -c64 /dev/sdb4 missing
Anyway, it took a couple tries, but everything went fairly nicely once it became visible.
Ok, so after I finished copying all my data the web interface for the network drive wouldn't reformat the bad drive. So I had to rebuild it from some images that people had posted on another forum topic, here: http://mybookworld.wikidot.com/forum/t-45881/how-to-backup-wd-mybook-world-ed-ii-1tb
1. Restore the sda_mbr. "dd if=sda_mbr of=/dev/sda bs=512 count=1"
2. Restore the partition table. "sfdisk /dev/sda < sda_ptable"
3. Restore the Image partition. "bzip2 -cd sda1_image.bz2 | dd of=/dev/sda1" do the rest for sda2, sda3, sda4.
If you get some error about not writable. You might have to follow step 4 and 6 above instructions. Make sure you change it back if you do this.
4. Not sure if you need to do this:
tune2fs -c -1 -i 0 /dev/sda1
tune2fs -c -1 -i 0 /dev/sda3
tune2fs -c -1 -i 0 /dev/sda4
And that should work. Hope this helps anybody who ran into problems similar to me. If anything isn't clear please let me know (paul at paulgraham dot ca).