PDA

View Full Version : [ubuntu] Ubuntu Vm to Dual Boot



breizh29
May 14th, 2012, 12:51 PM
Hi,

I'm using from few months a Virtual Machine Ubuntu in VirtualBox. VirtualBox is installed in Windows.

I want to install the Virtual Machine Ubuntu in dual boot.

Is it possible ?

Thanks

roelforg
May 14th, 2012, 12:57 PM
You didn't give much info.
I don't know what virtual box hd format you used,
but if you boot to a livecd, create partitions matching those in the vm (e.g. root and swap) and mount the hdimg somehow.
You should, theoratically, be able to copy all the files, reinstall the bootloader and be done.
Because in Linux, all is a file. The only thing that isn't is the bootloader.
I'm sure there's more to it (never did it), but that's basically how it *should* work.
I'm not counting adjusting config files to reflect new hw/partition layouts.

WARNING: very complex and hard

breizh29
May 14th, 2012, 01:02 PM
I don't know what virtual box hd format you used,
but if you boot to a livecd, create partitions matching those in the vm (e.g. root and swap) and mount the hdimg somehow.
You should, theoratically, be able to copy all the files, reinstall the bootloader and be done.
Because in Linux, all is a file. The only thing that isn't is the bootloader.
I'm sure there's more to it (never did it), but that's basically how it *should* work.
I'm not counting adjusting config files to reflect new hw/partition layouts.

OK,

So if I already have a Ubuntu in dual boot, I can theorically, copy and paste the folders from the VM Ubuntu to the Dual Boot Ubuntu ?

roelforg
May 14th, 2012, 01:08 PM
OK,

So if I already have a Ubuntu in dual boot, I can theorically, copy and paste the folders from the VM Ubuntu to the Dual Boot Ubuntu ?

In linux, everything is a file.
A file can by copied.
But you'll need to manually adjust configs and reinstall the bootloader.
Like i said: it's complex and can render your computer unbootable when done wrong (this goes for everything involving reinstalling bootloaders)
Do you feel confident with partitioners and such?
How experienced are you in linux?
Note that i gave you the theory, but i can't guarantee the result.
It's kinda like turning a rootfs generated by debootstrap into a bootable system, i imagine.

breizh29
May 14th, 2012, 01:16 PM
In linux, everything is a file.
A file can by copied.
But you'll need to manually adjust configs and reinstall the bootloader.
Like i said: it's complex and can render your computer unbootable when done wrong (this goes for everything involving reinstalling bootloaders)
Do you feel confident with partitioners and such?
How experienced are you in linux?
Note that i gave you the theory, but i can't guarantee the result.
It's kinda like turning a rootfs generated by debootstrap into a bootable system, i imagine.

Actually, I'm not an expert in Linux.
I understand the theory, but I'm not sure to be enough good to reach the goal.
I'm going to think about another solution.

Thank you roelforg

roelforg
May 14th, 2012, 01:24 PM
Actually, I'm not an expert in Linux.
I understand the theory, but I'm not sure to be enough good to reach the goal.
I'm going to think about another solution.

Thank you roelforg

This forum's here to help.
If you want to do this, me or someone else will gladly help you.
Though i advise reading about partitioning (gparted is my favorite) and basic bash scripting first.
You may want to post what kind of hd-format virtual box used and where on the win-disk it is.
Understanding the theory i gave you is a very good start, and you got that right.
You don't have to be an expert in linux, but atleast techsavvy enough to look up things you don't understand (which i advise you do with a subject like this).

EDIT:
Note: you don't need an ubuntu already in dualboot. It's easier though as the installer will prepare a bootloader (i suck at configuring grub, i usually use extlinux but then again, i'm a geek that doesn't mind manually reconfiguring the bootloader when installing something that would edit grub). But grub will need to be reinstalled anyways.