WUBI virtual disk in WINDOWS partition

Asked by Hans-Juerg Reinhart

Is it possible to install a virtual disk in a WINDOWS partition different from the boot partition (Windows drive C:)?
How is it done?

I tried to install Ubuntu with WUBI directly in the WINDOWS partition D:. The system was not able to boot. I installed Ubuntu with WUBI in partition C:. Now I have run out of space and I have not enough space on C: to install an addtional virtual partiton or to extend Ubuntu. I also need to keep Windows.

beste regards,

HJR

Question information

Language:
English Edit question
Status:
Solved
For:
Wubi Edit question
Assignee:
No assignee Edit question
Solved by:
Hans-Juerg Reinhart
Solved:
Last query:
Last reply:
Revision history for this message
actionparsnip (andrew-woodhead666) said :
#1

Which version of windows?

Revision history for this message
Hans-Juerg Reinhart (hans-juerg-reinhart) said :
#2

Wndows XP

Revision history for this message
actionparsnip (andrew-woodhead666) said :
#3

If you go in to c:\windows you will see lots of hidden folders starting with a dollar sign, you can delete those and save a tonne of space. Also empty out your temp folders.

Revision history for this message
Hans-Juerg Reinhart (hans-juerg-reinhart) said :
#4

So no chance to use all the available space on the other partition (drive D:)?

Revision history for this message
actionparsnip (andrew-woodhead666) said :
#5

I'm not conversant with wubi, maybe others can advise...

Revision history for this message
bcbc (bcbc) said :
#6

You can install wubi on any partition. What error did you get? Pastebin your logfiles if you still have them and can't recall.

Revision history for this message
Hans-Juerg Reinhart (hans-juerg-reinhart) said :
#7

The installation routine took excessively long on D: compared to an installation on C:.
The installation seemed to finish OK. However Ubuntu simply did not boot from D:
I finally gave up and installed on C:...
Moving my current installation to a bigger virtual partition on D: would of course solve my problem.

Revision history for this message
bcbc (bcbc) said :
#8

You'd have to figure out why it didn't boot from D: to understand whether it would work from D: now. When you say it simply did not boot... do you recall any specific error messages or can you describe what happened when you tried to boot from the install on D:?

Revision history for this message
Hans-Juerg Reinhart (hans-juerg-reinhart) said :
#9

Hmm - I got the choice between XP and ubuntu from the bootloader.
After choosing ubuntu nothing happened anymore.
I cant remember seeing any error messages.

Revision history for this message
bcbc (bcbc) said :
#10

Okay... I can't really speculate why the install to D: failed previously. If you were trying to do this and had logs etc. we could troubleshoot. In theory you can install Wubi to any partition visible to Windows (i.e. NTFS or FAT32)
Note if you try to install to D: now it will require you to uninstall the current install on C: (deleting everything).

Your initial question seems to be: can you add another virtual disk on D: to the current install on C:. And the answer is No (or at least not easily). You could potentially mount the D: partition and then loop mount a virtual disk from it, but you'd be doing it all manually (none of the existing scripts support an operation like this).
What would be easier is to store data on the D: partition i.e. mount it through an entry in your /etc/fstab and then link your /home/Documents or /home/Pictures directly to a folder on the D: partition. Also you could clean up clutter like all kernels except the current and previous one etc. to streamline your existing install.

Alternatively you could backup your data, try reinstalling on D:, or move your entire wubi install to D: - but this isn't guaranteed to work (since you had problems before).

Revision history for this message
Hans-Juerg Reinhart (hans-juerg-reinhart) said :
#11

Thanks for all this information!

I will try again to move to D:
Can you tell me how to backup my current installation? There is plenty of space on D:.

Wubinstall seemed to spend a lot of time half way trough while installing on D: as far is I remember. I guess there is a problem with this installation.
Does Wubiinstall create a log file which would be usefull?
Does the bootloader create a logfile which can be analyzed?

Revision history for this message
bcbc (bcbc) said :
#12

Okay so the main thing is to backup the root.disk (actually just copy the whole C:\ubuntu\disks directory somewhere to D: (not in D:\ubuntu). Make sure your backup is outside of C:\ubuntu anyway because that whole directory is deleted when you uninstall wubi.

Then install the same release of Ubuntu on D: (choose the smallest possible install 5GB). Make sure the install is successful and then check out the grub menu entries as described in this link: http://askubuntu.com/questions/70783/move-a-wubi-installation-to-another-partition
Once you copy over your backed up \ubuntu\disks files into D:\ubuntu\disks you'll need to temporarily override the grub menu entry the first time you boot into ubuntu. And then run:
sudo update-grub
to get it permanently fixed.

The wubi log file is found in the %TEMP% directory (%TEMP% is an environment variable, just enter it in the Windows Explorer address bar). There is no 'bootloader' log - bootloaders are tiny bits of code that don't have room for luxuries like logs. But it's possible to extract logs from the installation (just depends on the method you use to install on how to do this). So just let me know if you get stuck.

Good luck.

Revision history for this message
Hans-Juerg Reinhart (hans-juerg-reinhart) said :
#13

The problem seems to come from FAT32 on D:.
I have now converted to NTFS
Next I will try to move ubuntu from C: to D: as described.
Afterward I need to extend the virtual partition.

Revision history for this message
bcbc (bcbc) said :
#14

FAT32 is supported normally but due to a bug in 11.10 wubi.exe it will fail if you run wubi.exe standalone (not with the CD ISO). This will be fixed in 12.04.

And yes you wouldn't be able to move an NTFS install to a FAT32 partition, as the FAT32 filesystem limits the file size to 4GB and Wubi on NTFS will always have a root.disk >= 5GB in size.

But since you are able to convert to NTFS this is the best solution.

Note: if you are able to repartition, you could also just install Ubuntu to its own partition (which is best for long term use). Wubi is great to try out Ubuntu, but eventually it's recommended to switch to a normal install.
Actually you could also migrate directly from the wubi install on C: to a new partition (without worrying about resizing etc. since the new size will be the size of the partition): http://ubuntuforums.org/showthread.php?t=1519354

Revision history for this message
Hans-Juerg Reinhart (hans-juerg-reinhart) said :
#15

OK this did the job! ubuntu is now on D:
I will try to extend the partition tomorrow.

But this answered my question. Thanks very much for your help!

I will try later whether I can repartition my disk.