Sunday, April 12, 2015

How to fix Wubi after Ubuntu 14.04 upgrade

I've been planned to convert the Wubi installation on my old PC to a complete Ubuntu system long time ago, but the hassle of backing up Windows files has held me back. End of the day, Wubi is a relatively safe option comparing to true dual-system solutions, and I'm keeping Windows 7 on this machine anyway. So I ended up finally upgrading Wubi to Ubuntu 14.04 LTS today.

As expected, Ubuntu failed to start after upgrading. The fix is quite easy (for my case at least...):
1. In choosing system screen, choose Ubuntu and press "Enter"
2. Press "Shift" immediately after to enter Grub menu
3. Press "e" at Grub menu to edit the Grub menu
4. Replace
"linux /boot/$your Linux version$ root=$some ID number$ loop=/ubuntu/disks/root.disk ro   quiet splash $vt_handoff"
to
"linux /boot/$your Linux version$ root=$some ID number$ loop=/ubuntu/disks/root.disk rw   quiet splash $vt_handoff"
5. Press F10 to boot into Ubuntu
6. If you succeed in boot into Ubuntu this time, make your change permanent by making the same edit in /etc/grub.d/10_lupin:
"sudo vi /etc/grub.d/10_lupin"
"sudo update-grub"
If you don't use vim, any other text editor such as gedit can do as well. Just don't forget to add "sudo", otherwise you won't be able to save your change.
7. Open /boot/grub/grub.cfg to confirm that the change has also been made there by update-grub.
8. Restart your system to check if everything works well now.

At step 2, if you hold another key instead of "Shift", you will very likely end up here:
"[ Minimal BASH-like line editing is supported.For the first word, TAB lists possible command completions. Anywhere else TAB lists possible device/file completions]
grub>"
In this case, type "reboot" and wait for the choosing system screen to appear to try again with the before-mentioned solution.

To know more about what this fix does, read here:
https://help.ubuntu.com/community/Grub2/Troubleshooting
http://ubuntuforums.org/showthread.php?t=2217829

If you still can't start Ubuntu normally, try something here:
http://ubuntuforums.org/showthread.php?t=1594052