Ubuntu Forums ubuntu.com - launchpad.net - ubuntu help  

Go Back   Ubuntu Forums > The Ubuntu Forum Community > Other Community Discussions > Tutorials & Tips
Register Reset Password Forum Help Forum Council Search Today's Posts Mark Forums Read

Ubuntu 9.10 is out!!!

When downloading Ubuntu 9.10 please consider using bittorrent to get your copy of Ubuntu.

The Ubuntu Developers Summit for Lucid Lynx will be held the week of 16-Nov-2009 till 20-Nov-2009 in Dallas, TX USA. Visit the the Ubuntu wiki for more information about UDS and how to participate remotely.

Tutorials & Tips
The place to find Ubuntu related Tips & Tricks.

View Poll Results: Did this howto work?
Yes, it worked 57 37.75%
It worked after a little hacking and tinkering 40 26.49%
It didn't work, but didn't do any damage 35 23.18%
It left my system completely unbootable, resulted in data loss, etc. 19 12.58%
Voters: 151. You may not vote on this poll

 
Thread Tools Display Modes
Old May 9th, 2007   #1
tuxcantfly
Fresh Brewed Ubuntu
 
tuxcantfly's Avatar
 
Join Date: Mar 2006
Location: Cambridge, MA
Beans: 1,217
Ubuntu 9.04 Jaunty Jackalope
LVPM: Upgrades Wubi installs to dedicated-partition Ubuntu installs

LVPM NOW HAS ITS OWN WEBSITE AND A SCREENSHOT-BASED GUIDE AT http://lubi.sourceforge.net/lvpm.html

LVPM currently supports installations generated by Wubi 8.04, Wubi 7.10, Wubi 7.04, and Lubi 7.04. Support for 8.04 is recent and has not been extensively tested, so you may want to use the "Alternative Instructions" (see below) instead.

Rationale for using LVPM to transfer your Wubi install to a real partition

A major feature of Wubi is that it installs Ubuntu onto a virtual disk, eliminating the hassles and risks of repartitioning. While such an install is adequate for everyday use, there are several advantages to having a "real" Ubuntu installation, that is, one in a dedicated partition, rather than a virtual disk on your Windows install.

1. Full independence from Windows: Wubi relies on Windows to store its virtual disks, and for its bootloader. Thus, should you decide that Ubuntu serves your needs and you no longer need Windows, you cannot simply delete your Windows partition, as that will remove your Wubi install as well. To switch entirely to Ubuntu, you will first need to transfer your Wubi install to its own partition by following this guide, and only then can you delete your Windows partition.

2. Performance boost: There is a slight hard drive performance penalty in a Wubi install due to the usage of virtual disks. While it shouldn't be noticeable in everyday usage, if you regularly edit and copy large files, such as in movie editing, there should be a speed improvement if you transfer your Wubi install to a dedicated partition.

3. Regain hibernation functionality: Even if your hardware supports hibernation under Ubuntu, you will be unable to do so in Wubi, since the swap is within a virtual drive. However, if you transfer your install to a real partition, you will have dedicated swap, so you will be able to hibernate if your hardware supports it normally under Ubuntu (check in the forums for information on any particular hardware models).

Before starting...

Always remember to back up data, just in case something happens. Back up to a USB flash drive, CD/DVD, anywhere EXCEPT your hard drive.

Also make sure you have a spare partition to install to. To do this, just use the Partition Manager tool (short video tutorial at http://blip.tv/file/331394 ) to resize the Windows partition with GParted and create a new primary partition formatted as ext3. You'll also need to create another partition with a size greater than your ram size, and format it as swap.

Creating new partitions and resizing existing ones

This is only required if you don't already have a spare partition to install to. Also make sure you have a swap partition of greater size than your RAM memory, in addition to the partition you will install Linux to (the filesystem type for the main partition doesn't matter, it'll be made ext3 anyhow, just make sure the swap partition is formatted as swap or it won't be used). If you do, just move on to the next section.

To do this, you can use the Partition Manager tool (short video tutorial at http://blip.tv/file/331394 ), boot it up and open GParted, then follow the guide at http://gparted.sourceforge.net/larry...e/resizing.htm

Resize your Windows partitions (NTFS) and create a new primary partition (format doesn't matter, it'll be formatted ext3 by LVPM, but it should be at least as large as the Wubi virtual disks, at least 5 GB) and a swap partition (of greater size than the amount of RAM memory). Also note what the device string of the new system (not swap) partition is (something like /dev/sdb1, /dev/hda2); you'll need it later.

ONLY resize the Windows (NTFS) partition, DON'T delete it just yet, even if you plan on getting rid of Windows, because your Wubi install is still on it.

Installing and running LVPM, the Loopmounted Virtual Partition Manager

You can either follow my step-by-step video tutorial at http://blip.tv/file/331947, a screenshot-based guide at http://lubi.sourceforge.net/lvpm.html or follow the instrctions below:

Boot the Ubuntu install created by Wubi/Lubi, and download and install the latest lvpm deb package.

http://lubi.sourceforge.net/lvpm-latest.deb

Once installed, open Applications -> System Tools -> LVPM, and select either the "transfer" option, and select a partition to install to. DO NOT SELECT A PARTITION WITH ANY IMPORTANT DATA ON IT; IT WILL BE WIPED OUT. ALSO NOTE THAT GRUB WILL BE INSTALLED TO THE MBR. If you want to resize your virtual disks, rather than transfer them to dedicated partitions, use the "resize" option.

Now, reboot and hope that it works, if you run into some horrible boot error, plop in the Super Grub Disk, and hopefully, you should be able to boot your system.

Getting rid of the original Wubi install (optional)

If you're satisfied with your new real-partition install, and have no need to keep your original Wubi install, just boot Windows, go to "Add/Remove Programs", select Wubi, and press "Uninstall", and you'll be left only with your real-partition Ubuntu installation.

Getting rid of Windows entirely (optional)

AFTER you have transferred the Wubi install to a real partition, and it is working, boot the Partition Manager tool, open GParted, delete the Windows (NTFS) partition, and follow the guide at http://gparted.sourceforge.net/larry/tips/gfs.htm to expand your ext3 partition to use up the free space left by the deleted Windows (NTFS) partition.

Resizing virtual disks using LVPM

Run LVPM, and once the menu appears, select "resize" (to resize the root virtual disk, which contains both /home and the system files).

Input the new size, in MB, of the virtual disk.

Wait until the program finishes creating a new disks file and copying files from original home disk file; it will pop up a final instruction window instructing to backup the original home disk file and renaming the newly created disk file

Boot into windows and navigate to c:\wubi\disks, move the old virtual disk to a different folder as backup, and rename new.virtual.disk to root.virtual.disk

Reboot into ubuntu

If everything works, make sure you leave your vote on the poll, and if there's some error in the instructions or something didn't work, make sure leave a comment.

Alternative Instructions

It's possible to migrate Wubi installs (any version, works on both 7.04 or 7.10), data, and settings (apps can be quickly reinstalled via apt-get) to dedicated-partition installs using an alternative approach (use this if LVPM fails), which also doesn't require a CD:

1. Create 3 new partitions with the Partition Manager (download): a 5-10 GB (ext3 format) partition to use as root (/), a ~1 GB (equal to RAM size) (swap format) partition to use as swap, and make the rest a (ext3 format) partition to use as /home.

2. Boot back into the Wubi-generated Ubuntu install, mount the new partition that will be used as /home in the dedicated-partition install to /media/disk, and copy the contents of the current /home recursively over to the new partition:

Code:
rsync -avx /home/ /media/disk
Additionally, if you want to avoid the hassle of manually reinstalling all the packages you currently have installed, run:

Code:
dpkg --get-selections > selections.dpkg
That'll generate a list of packages you have installed (back up that list to somewhere safe); after reinstalling the system, just open Synaptic, go file > read markings, select that file that was generated (selections.dpkg), press apply, and it'll reinstall all the software you have on your current system (details here).

3. Reboot into Windows, and install UNetbootin (download).

Download and install the .exe version, reboot, then select "UNetbootin" at the boot menu, then the Ubuntu installer will start up. After that, just follow the standard Ubuntu installation process (guide), just make sure that at the "partitioning" stage, select the "manual" option, and make sure tospecify the appropriate mountpoints (make sure the partition you copies /home to is mounted at /home, and make sure it doesn't get formatted). After that, wait for Ubuntu to be downloaded and installed from the net (it'll take a long time if you're on a slow connection, just give it a few hours to complete).

4. Once done installing, reboot back, and your new dedicated-partition Ubuntu install, complete with data and settings preserved, should be there. You can re-install the individual applications via apt-get. Once done, you can reboot back into Windows and remove the UNetbootin installer (it'll prompt on startup), and remove Wubi, then you'll be done.

NOTES

If you ever get a GRUB error, or can't boot one of your operating systems, boot up the Super Grub Disk http://supergrub.forjamari.linex.org/ and it will allow you to repair GRUB and be able to boot Windows and Ubuntu.

Last edited by tuxcantfly; July 5th, 2008 at 12:38 AM.. Reason: Wubi 8.04 instructions
tuxcantfly is offline   Reply With Quote
Old May 11th, 2007   #2
tuxcantfly
Fresh Brewed Ubuntu
 
tuxcantfly's Avatar
 
Join Date: Mar 2006
Location: Cambridge, MA
Beans: 1,217
Ubuntu 9.04 Jaunty Jackalope
Re: Howto: Transfer Wubi virtual disks into a real partition

I've transferred this project into its own launchpad page, the Loopmounted Virtual Partition Manager:

https://launchpad.net/lvpm
tuxcantfly is offline   Reply With Quote
Old May 30th, 2007   #3
qbnflaco
First Cup of Ubuntu
 
Join Date: Jan 2007
Beans: 3
Re: Howto: Transfer Wubi virtual disks into a real partition

Is this guide still broken?
qbnflaco is offline   Reply With Quote
Old June 9th, 2007   #4
Rohen
A Carafe of Ubuntu
 
Rohen's Avatar
 
Join Date: Jun 2007
Location: Colombia
Beans: 84
Ubuntu 8.10 Intrepid Ibex
Send a message via ICQ to Rohen Send a message via AIM to Rohen Send a message via MSN to Rohen Send a message via Yahoo to Rohen
Exclamation Re: Howto: Transfer Wubi virtual disks into a real partition

I second that.. Is it still broken??? I use way to much swap for wubi to be of any good use!
Rohen is offline   Reply With Quote
Old June 17th, 2007   #5
tuxcantfly
Fresh Brewed Ubuntu
 
tuxcantfly's Avatar
 
Join Date: Mar 2006
Location: Cambridge, MA
Beans: 1,217
Ubuntu 9.04 Jaunty Jackalope
Re: Howto: Transfer Wubi virtual disks into a real partition

qbnflaco, Rohen: see the first post, it's now working...
tuxcantfly is offline   Reply With Quote
Old June 22nd, 2007   #6
Depressed Man
Dipped in Ubuntu
 
Join Date: May 2007
Location: Maryland
Beans: 536
Ubuntu 9.04 Jaunty Jackalope
Send a message via Yahoo to Depressed Man Send a message via Skype™ to Depressed Man
Re: Howto: Transfer Wubi virtual disks into a real partition

Is it possible to use this to get hibernate/suspend working? (currently doesn't work under Wubi)

Also..what if I want to keep the Vista boot loader and not use Grub?
__________________
"I thought what I'd do was I'd pretend I was one of those deaf-mutes"
Desktop: Ubuntu: Jaunty and Windows XP
Laptop: Ubuntu: Jaunty and Windows Vista
n800: OS2008 Diablo
Depressed Man is offline   Reply With Quote
Old June 22nd, 2007   #7
tuxcantfly
Fresh Brewed Ubuntu
 
tuxcantfly's Avatar
 
Join Date: Mar 2006
Location: Cambridge, MA
Beans: 1,217
Ubuntu 9.04 Jaunty Jackalope
Re: Howto: Transfer Wubi virtual disks into a real partition

Quote:
Is it possible to use this to get hibernate/suspend working? (currently doesn't work under Wubi)
It'll depend on your hardware; even normal ubuntu installs don't support suspend or hibernate on a lot of hardware, but since the swap is on a dedicated partition, it should be no different from a standard install; if the hardware supports suspend/hiberate on a normal ubuntu install, it'll support it here.

Quote:
Also..what if I want to keep the Vista boot loader and not use Grub?
Vista bootloader can only boot Windows, Grub is needed to boot Ubuntu and other operating systems. Using the chainloader approach described above, you can boot both Ubuntu and Windows with grub, so I don't see what the problem with using grub would be... Of course, you could use the Vista bootloader to boot GRLDR, the same approach that the standard Wubi does, and remove Grub from the MBR, and that'll work too, but that's basically pointless, since it's more error-prone, increases boot times, and has no practical advantages over just using GRUB to chainload the Vista bootloader...

Last edited by tuxcantfly; June 22nd, 2007 at 08:56 PM..
tuxcantfly is offline   Reply With Quote
Old June 22nd, 2007   #8
Depressed Man
Dipped in Ubuntu
 
Join Date: May 2007
Location: Maryland
Beans: 536
Ubuntu 9.04 Jaunty Jackalope
Send a message via Yahoo to Depressed Man Send a message via Skype™ to Depressed Man
Re: Howto: Transfer Wubi virtual disks into a real partition

Yeah I understand that, though I thought there was currently a hibernate issue with Wubi. And while I know VAIOs don't have the greatest support in Ubuntu, I just can't help but wonder if Wubi could add onto the problem.

And ok, I was just worried since I've read that Vista is extremely picky about things like its partition and what not. Though I do have some problems in Wubi Ubuntu right now. sudo gedit doesn't work and I can't seem to get anything working through localhost. Though I don't know if that's an Ubuntu issue or Wubi.. I may just decide to start over with an Ubuntu install to see if it fixes anything.
__________________
"I thought what I'd do was I'd pretend I was one of those deaf-mutes"
Desktop: Ubuntu: Jaunty and Windows XP
Laptop: Ubuntu: Jaunty and Windows Vista
n800: OS2008 Diablo
Depressed Man is offline   Reply With Quote
Old June 24th, 2007   #9
tuxcantfly
Fresh Brewed Ubuntu
 
tuxcantfly's Avatar
 
Join Date: Mar 2006
Location: Cambridge, MA
Beans: 1,217
Ubuntu 9.04 Jaunty Jackalope
Re: Howto: Transfer Wubi virtual disks into a real partition

Quote:
Yeah I understand that, though I thought there was currently a hibernate issue with Wubi
Yes, that's what I meant. There's a hibernation issue with Wubi due to the usage of loopmounted disks, but once you transfer the install to a real partition using LVPM (and remember to create a swap partition that is greater than or equal to your ram size prior to installing), hibernation should work (if your hardware would support it under a standard Ubuntu install, that is)
Quote:
And ok, I was just worried since I've read that Vista is extremely picky about things like its partition and what not.
So long as you have a free partition (or make one by resizing existing ones), and you don't tell LVPM to install to the Vista partition, you shouldn't have any issues with that; Vista shouldn't be impacted by this; GRUB will simply chainload the Vista bootloader and it will boot as usual

Quote:
sudo gedit doesn't work and I can't seem to get anything working through localhost.
Very strange error, I don't think it could be related to Wubi or Lubi, since those are only supposed to impact the disk layout and partitioning-related issues, but if you don't get that issue on a standard Ubuntu install, make sure to report it, it could be some bug we didn't notice...

Last edited by tuxcantfly; June 24th, 2007 at 07:16 PM..
tuxcantfly is offline   Reply With Quote
Old June 24th, 2007   #10
tuxcantfly
Fresh Brewed Ubuntu
 
tuxcantfly's Avatar
 
Join Date: Mar 2006
Location: Cambridge, MA
Beans: 1,217
Ubuntu 9.04 Jaunty Jackalope
Re: Howto: Transfer Wubi virtual disks into a real partition

I've added a few fixes to the script (in the first post), and, most notably, a grub setup fix so that hacks aren't required anymore to boot the original host OS... It should now be safe to use, testers please? And please leave feedback on anything that worked or didn't work...
tuxcantfly is offline   Reply With Quote

Bookmarks

Thread Tools
Display Modes

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off

Forum Jump


All times are GMT -4. The time now is 04:06 PM.


vBulletin ©2000 - 2009, Jelsoft Enterprises Ltd. Ubuntu Logo, Ubuntu and Canonical © Canonical Ltd. Tango Icons © Tango Desktop Project. bilberry