32

I recently installed Ubuntu 14.04 using WUBI and after installation when it booted it showed an error:

Serious errors were found while checking the disk drive for /. 

There were three options:

press [I] to ignore, press [S] to skip mounting and press [M] to mount manually. 

After I pressed I, it showed /tmp could not be mounted and my Ubuntu isn't booting.

  • Can anybody please guide me to how to solve this problem?
Hugo
  • 144
  • 11
user272877
  • 323
  • 1
  • 4
  • 4
  • @pandya I have aleeady seen the link but the answers dont seem to help me to solve the problen – user272877 Apr 23 '14 at 09:59
  • I would like to install via wubi because then I can remove ubuntu whenever I want without any trouble. Can you please guide me to how to solve this problem – user272877 Apr 23 '14 at 11:14
  • I used the above and it works great. However, when I try to edit the GRUB2 boot entry; it will revert back to the original (even after saving it). I used the command: sudo gedit /etc/grub.d/10_lupin I was able to edit it and save it (changed ro to rw). But after rebooting, it reverts back to the original boot entry. How can I make it permanent? Many thanks, –  May 02 '14 at 19:29
  • holy cow, why is this even happening? – Dirk Aug 10 '14 at 11:12
  • [Bug #1091792 The disk drive for /tmp is not ready yet or not present](https://bugs.launchpad.net/ubuntu/+source/mountall/+bug/1091792) – bain Sep 18 '14 at 09:35

2 Answers2

44
  1. In Windows Boot Manager, select Ubuntu.
  2. Press any key and enter GNU Grub2 menu.
  3. You can press "e" to edit GRUB2 boot entry.

You need to change the GRUB2 boot entry from "ro" to "rw",

e.g.

linux   /boot/vmlinuz-3.13.0-24-generic root=UUID=AAC884AC1F144321 loop=/ubuntu/disks/root.disk ro   quiet splash $vt_handoff

to

linux   /boot/vmlinuz-3.13.0-24-generic root=UUID=AAC884AC1F144321 loop=/ubuntu/disks/root.disk rw   quiet splash $vt_handoff

Press F10, you can boot in Ubuntu 14.04.

and you can fix GRUB2 boot entry:

sudo vi /etc/grub.d/10_lupin

Change the line:

linux   ${rel_dirname}/${basename} root=${LINUX_HOST_DEVICE} loop=${loop_file_relative} ro ${args}

to:

linux   ${rel_dirname}/${basename} root=${LINUX_HOST_DEVICE} loop=${loop_file_relative} rw ${args}

Regenerate GRUB2 boot entry:

sudo update-grub
karel
  • 110,292
  • 102
  • 269
  • 299
user273948
  • 456
  • 5
  • 3
  • Ok thanks for helping but last question how can I change the grub file without booting into ubuntu because I cant boot into my ubuntu – user272877 Apr 25 '14 at 13:21
  • 1. in windows boot manager, select Ubuntu . 2. press any key and go in GUN Grub2 menu. 3. you can press "e" to edit the commands before booting. – user273948 Apr 25 '14 at 17:29
  • After you select "Ubuntu" from the Windows boot manager, keep Shift pressed and the Grub menu should appear. – gfour Apr 27 '14 at 09:10
  • Thank you very much my ubuntu finally booted! Thanks to everyone – user272877 Apr 29 '14 at 18:01
  • I fix the issue with this answer, but now when i restart or shutdown the computer, after selecting ubuntu in boot options, the screen go black and never initiate. I reboot manually and then select ubuntu in boot options, in the menu press e and then F10 and it loads fine, always have to press e -> F10 in order to be able to load ubuntu. Any suggestions? – Duver May 05 '14 at 21:38
  • You sir......are my hero. This was driving me crazy and your solution here brought me back to sanity. One suggestion I would make though is when editing the GRUB file to use `sudo gedit /etc/grub.d/10_lupin` instead of `sudo vi /etc/grub.d/10_lupin`. This works better for me as I have a more graphical interface, easier to read text, and I can be lazy by using the search function instead of having to look through many lines to find `} ro ${`. But again, THANK YOU!! – The Duke Of Marshall שלום Jun 04 '14 at 18:28
  • This solution actually worked, which amazes me. How in the world does somebody know this? Can somebody tell me where I should start reading / learning in order to understand issues like this and be able to solve problems like this? Is there a textbook I should read? – littleO Jul 13 '14 at 10:16
  • where to find windows boot manager in windows 8. I'm also having the same issue. – Anuj TBE Sep 09 '14 at 16:16
  • This is a life saver! – na-no. Jul 29 '18 at 08:35
6

The temporary fix - overriding the initial mounting of the root.disk to rw (read/write) instead of ro(read-only) is good. It's the only way to boot Wubi after a 14.04 install (or upgrade).

However, there is a better long term fix than permanently modifying the mount to read/write. It's best to modify the way the loop device is created in order to allow remounting as read-write. This will then allow you to use recovery mode.

Modify the file /usr/share/initramfs-tools/script/local as shown (one line removed, three added):

--- /home/bcbc/local   2014-11-19 20:25:12.274837304 -0800
+++ /usr/share/initramfs-tools/scripts/local   2014-11-19 20:28:37.990832807 -0800
@@ -143,7 +143,9 @@
        modprobe ${FSTYPE}

        # FIXME This has no error checking
-       mount ${roflag} -o loop -t ${FSTYPE} ${LOOPFLAGS} "/host/${LOOP#/}" ${rootmnt}
+       loopdev=`losetup -f`
+       losetup ${loopdev} "/host/${LOOP#/}"
+       mount ${roflag} -t ${FSTYPE} ${LOOPFLAGS} ${loopdev} ${rootmnt}        

        if [ -d ${rootmnt}/host ]; then
            mount -o move /host ${rootmnt}/host

After making the change, update the initial ramdisk:

sudo update-initramfs -u

For additional information, and credit for the fix see: https://code.launchpad.net/~noorez-kassam/ubuntu/utopic/initramfs-tools/fix-for-1317437/+merge/219927

Caution: obviously if you make some typos when applying this fix it may prevent your install from booting. So proceed with caution. And if unsure, use the easier Grub override. Make sure you use the ` quote, not ' for the loopdev= line.

If you attempt this and run into problems, there are a couple of things you can try:

  1. If you have more than one kernel, go to the Recovery menu and select an older kernel (with it's own initramfs).
  2. You could backup the initramfs (before updating), and then copy it over the bad one from a live DVD/USB.
  3. You could rebuild the initramfs in a chroot, but this is a bit involved.

If it's a fresh install, then reinstalling is your best option.

bcbc
  • 6,006
  • 4
  • 36
  • 68
  • Like yourself, I am trying to find a better long term solution to this problem. Tried your method, and ended up getting a lot of errors on reboot, some of which indicated missing files like /etc/fstab. Could be that I have made a typo, however, is it possible that 'losetup' is finding a different first unused loop device than is expected? Should I be using /dev/loop0 instead? At present, I have applied the easier Grub override. – Bill Dec 27 '14 at 08:53
  • @Bill I'd guess there's a typo. If you pastebin your code and post the link I'll take a look. – bcbc Dec 30 '14 at 03:10
  • Thanks bcbc, Unfortunately, I cannot pastebin the original code since I ended up uninstalling and reinstalling wubi. What I will do, however, is pastebin the current code I intend to use to recreate initramfs. Here is the link: http://pastebin.com/bRKc9fdL – Bill Dec 30 '14 at 03:47
  • @Bill that looks good. – bcbc Dec 30 '14 at 07:35
  • 3
    To quote Acts 8:8 - So there was much rejoicing in that city....so too was in the Tourloupis household that evening...! Thanks for your help bcbc. Solved my problem. Must have been a typo after all! Mind you, I had to copy and paste that portion of code into the latest copy of /usr/share/initramfs-tools/script/local, as it had been modified since I had posted my original comment. Otherwise, it worked like a charm! That is, after I changed the affected line of /etc/grub.d/10_lupin back to read-only. Once again, thank you for your help! – Bill Dec 30 '14 at 08:42
  • @Bill Great! You're welcome. Your experience does highlight the risk of attempting this fix. I'll add some suggestions to my answer to get around the problem. – bcbc Dec 30 '14 at 19:01
  • +1 This is my preferred solution, since it's long term and shouldn't disrupt recovery settings. Thanks! – Warrick Feb 05 '15 at 08:04