I have been upgrading my MBWE Single Disk with a new harddisk.
The new harddisk is a WD15EARS with 64MB CACHE and 4k alignment (Advanced Format Drive).
This is the way I have done the upgrade:
Prepare our mission
- Setup a Linux VMware session. I used a Debian 5.7 net install which can be found here Debian. A 8Gb partition and 400MB memory allocation worked fine for me. (Be sure you don't have any RAID utils installed!)
- Shutdown the Linux VMware session. And shutdown your PC. Connect the old drive and the new drive to your PC using 2 SATA connectors. Boot up your PC
- Setup VMware Linux. Add the 2 drives as physical drives so Linux can see all of them!
- Boot VMware Linux
- Check the drives in Linux. /dev/sda should be the VMware Linux. /dev/sdb should be your old drive. /dev/sdc should be your new drive.
COPY
1. Copy the MBR (Master Boot Record) and Bootloader
dd if=/dev/sdb of=/dev/sdc bs=512 count=48195
2. Copy the partition table
sfdisk -d /dev/sdb | sed s/sdb/sdc > part_sdb.img
sfdisk /dev/sdc < part_sdb.img
3. Copy the partitions
dd if=/dev/sdb1 of=/dev/sdc1 bs=64k
dd if=/dev/sdb2 of=/dev/sdc2 bs=64k
dd if=/dev/sdb3 of=/dev/sdc3 bs=64k
dd if=/dev/sdb4 of=/dev/sdc4 bs=64k
This can take a while, it cost me 8 hrs on a AMD 3000+ PC.
bs=64k is to speed up the process
4. Grow the last partition
Reboot your VMware Linux (to be sure Linux sees the partition tables correctly)
Start the Gnome partition editor (gparted) and grow the last partition.
Then check the volumes sdc1 sdc3 and sdc4 one by one with gparted. gparted will take care of the 4k alignment!
5. Check filesystems
the -D command will optimize directories in filesystem. This option causes e2fsck to try to optimize all directories, either by reindexing them if the filesystem supports directory indexing, or by sorting and compressing directories for smaller directories, or for filesystems using traditional linear directories.
e2fsck /dev/sdc1 -f -D -v
e2fsck /dev/sdc3 -f -D -v
e2fsck /dev/sdc4 -f -D -v
6. Shutdown VMware Linux
7. Shutdown PC
8. Reassemble your MBWE
9. Bootup
Fall Back Scenario
If you have problems or you just want to have a clean (new MBWE) install you use this thread in stead of step 4.
1. download the original images
WD_MYBOOK_WE_500GB_IMA.7z (57MiB) Link
SDA3_IMA.BZ2
Link
2. Copy the partitions
bzip2 -cd SDA1.IMA.BZ2 | of=/dev/sdc1 bs=64k
bzip2 -cd SDA2.IMA.BZ2 | of=/dev/sdc2 bs=64k
bzip2 -cd SDA3.IMA.BZ2 | of=/dev/sdc3 bs=64k
bzip2 -cd SDA4.IMA.BZ2 | of=/dev/sdc4 bs=64k
Extra Fallback
If your MBWE boots and you can't see your share you can Follow these steps:
install the martin Hinner hack [http://martin.hinner.info/mybook/sshaccess.php]
««< [shadowman2001 edited most updated link for that solution]»»»»»>
ather that:
login and type:
su
fdisk /dev/sda
d (delete partition)
4 (number 4)
n (new partition)
4 (number 4)
start cylinder: 506
end cylinder: press enter for default
t (change type of partition)
4 (number 4)
fd (=raid array)
w (to write the new partition table)
reboot
After the reboot type:
mdadm —stop /dev/md4 (to stop the array)
mdadm -Cv /dev/md4 -l1 -n2 -c64 /dev/sda4 missing (to create a new array)
mdadm: chunk size ignored for this level
mdadm: /dev/sda4 appears to contain an ext2fs file system
size=1461079620K mtime=Mon Feb 22 18:50:52 2010
mdadm: size set to 1461079552K
y (Continue creating array? -> press y -> you will get the message "mdadm: array /dev/md4 started." )
mke2fs -L "Data" -j /dev/md4 (to format the partition)
This should be the result:
mke2fs 1.38 (30-Jun-2005)
Filesystem label=Data
OS type: Linux
Block size=4096 (log=2)
Fragment size=4096 (log=2)
182648832 inodes, 365269888 blocks
18263494 blocks (5.00%) reserved for the super user
First data block=0
11148 block groups
32768 blocks per group, 32768 fragments per group
16384 inodes per group
Superblock backups stored on blocks:
32768, 98304, 163840, 229376, 294912, 819200, 884736, 1605632, 2654208,
4096000, 7962624, 11239424, 20480000, 23887872, 71663616, 78675968,
102400000, 214990848
Writing inode tables: 10016/11148
Leave it till this message comes
Creating journal (32768 blocks): done
Writing superblocks and filesystem accounting information: done
This filesystem will be automatically checked every 35 mounts or
180 days, whichever comes first. Use tune2fs -c or -i to override.
Then reboot -> Your drive is working now!














