Friday, August 31, 2012

Ubuntu grub fix with btrfs

I couldn't find a simple guide for this so here it is...

I have Ubuntu 12.04 with btrfs as my main FS.  Once Windows was install Ubuntu vanished as usual. Took some playing but here is my fix.

The guts are..

sudo mount -t btrfs -o subvol=@ /dev/sda6 /mnt/

sudo mount --bind /dev /mnt/dev/

sudo mount --bind /proc /mnt/proc

sudo chroot /mnt/

grub-install --recheck /dev/sda



The key bit is the mount line. If you see in your mount directory @ and @home something has not worked and it's mounted the raw thing not the correct subvolume.