Assuming the root.disk
you copied wasn't corrupted... you can boot it as follows:
search -s -f -n /ubuntu/disks/root.disk
probe --set=diskuuid -u $root
loopback loop0 /ubuntu/disks/root.disk
set root=(loop0)
linux /vmlinuz root=UUID=$diskuuid loop=/ubuntu/disks/root.disk ro quiet splash
initrd /initrd.img
boot
After booting, make sure you run sudo update-grub
Wubi corruption is most common on the NTFS
file system (requires running chkdsk /f
from Windows), followed by corruption of the internal ext3/4
filesystem. Since you managed to copy your root.disk
you may have internal corruption, in which case running fsck root.disk
might fix it. But this depends on when you made your backup (i.e. before or after you encountered the problem).
To fsck
the root.disk
you can boot an Ubuntu DVD/USB, Select Try Ubuntu, then mount the partition that contains the root.disk
and then fsck
it as follows (this example assumes the root.disk
is on /dev/sda1
):
sudo mount /dev/sda1 /mnt
sudo fsck -fyv /mnt/ubuntu/disks/root.disk
(flags are f
orce, y
es to fix automatically, v
erbose)
Note: fsck
used in this way does make changes and there's no guarantee it will fix everything without data loss. If recovery is critical it's possible to use photorec
(which comes bundled when you install testdisk
i.e. sudo apt-get install testdisk
). Photorec is read-only (non-destructive) and can recover raw files. The downside is that the recovered files are not named, and it recovers everything e.g. deleted files as well - so there is some manual effort to find the ones you are after. It does provide the ability to target specific file types though. See here for more info: Recover deleted data with rm -rf?
probe --set=diskuuid
gets the UUID of the partition that theroot.disk
resides on. Previously you'd have needed either the UUID of the partition number (/dev/sdXY
) to boot and this isn't always obvious. – bcbc Dec 03 '13 at 17:12root.disk
from a liveCD to attempt data recovery and thenfsck
ing it. It seems likely that it's corrupted. – bcbc Dec 04 '13 at 05:50fsck
theroot.disk
of the old one. If you create one you could also do a normal dual boot which is more reliable than Wubi which is designed more to try out Ubuntu. – bcbc Dec 04 '13 at 17:46ext3/4
filesystem corruption. The only way to fix that isfsck
(e2fsck
). There is no guarantee it will, but without it, you have 0 bytes in/home
so... that appears to be your only option. For a pure data recovery there is one other alternative (I'll add to answer). – bcbc Dec 05 '13 at 19:17