CloneVDI tool - Discussion & Support
-
- Site Moderator
- Posts: 39156
- Joined: 4. Sep 2008, 17:09
- Primary OS: MS Windows 10
- VBox Version: PUEL
- Guest OSses: Mostly XP
Re: CloneVDI tool - Discussion & Support
I agree with your conclusion, OTOH I'm struggling to explain why there would be even a small difference in the two methods: both should identify all of the unused space on a disk, and both can only discard a 1MB VDI block when the entire block is unused. Normally, you should only see a difference if some extra step has been done for one case only, e.g. defragging or deleting some big file.
I would also point out that the sdelete method only works when the area to be compacted is included in a guest filesystem. CloneVDI can also clean up unpartitioned areas of the disk, e.g. left behind after shrinking a partition.
I would also point out that the sdelete method only works when the area to be compacted is included in a guest filesystem. CloneVDI can also clean up unpartitioned areas of the disk, e.g. left behind after shrinking a partition.
Re: CloneVDI tool - Discussion & Support
Hi.
I used CloneVDI in order to add space to my virtual disk, but I have a problem.
I installed Ubuntu 14.04 in the Virtual Machine with a VDI disk 8 GB wide.
Now I want to add 72 GB to this disk without reinstalling UBUNTU; with GParted I notice that I have a partition dev/sda 8GB wide, than a 500MB of Linux Swap.
With Virtual Box command line I resized my Virtual Box size to 80 GB, and now in VB setup I see my disk with 80GB, but only 8 GB allocated. In Gparted I have 72GB not allocated space.
So I tried to use Clone VDI in order to enlarge disk dimension, but after Clone_DVI.dvi creation, I can use only 8 GB
Any ideas?
Thanks
I used CloneVDI in order to add space to my virtual disk, but I have a problem.
I installed Ubuntu 14.04 in the Virtual Machine with a VDI disk 8 GB wide.
Now I want to add 72 GB to this disk without reinstalling UBUNTU; with GParted I notice that I have a partition dev/sda 8GB wide, than a 500MB of Linux Swap.
With Virtual Box command line I resized my Virtual Box size to 80 GB, and now in VB setup I see my disk with 80GB, but only 8 GB allocated. In Gparted I have 72GB not allocated space.
So I tried to use Clone VDI in order to enlarge disk dimension, but after Clone_DVI.dvi creation, I can use only 8 GB
Any ideas?
Thanks
-
- Site Moderator
- Posts: 39156
- Joined: 4. Sep 2008, 17:09
- Primary OS: MS Windows 10
- VBox Version: PUEL
- Guest OSses: Mostly XP
Re: CloneVDI tool - Discussion & Support
Those are all FAQ questions.
If you use snapshots then you must clone the most recent snapshot, not the base VDI. See the CloneVDI release notes for details.
After resizing the disk (by whatever means), you need to use GParted or similar to increase the main partition size to fill the disk.
CloneVDI can automatically increase the partition size for NTFS and FAT guest filesystems, but not Linux (EXTx). Hence the need to use GParted for those guests after resizing the disk.
If you use snapshots then you must clone the most recent snapshot, not the base VDI. See the CloneVDI release notes for details.
After resizing the disk (by whatever means), you need to use GParted or similar to increase the main partition size to fill the disk.
CloneVDI can automatically increase the partition size for NTFS and FAT guest filesystems, but not Linux (EXTx). Hence the need to use GParted for those guests after resizing the disk.
-
- Posts: 134
- Joined: 7. Feb 2010, 23:41
- Primary OS: MS Windows 7
- VBox Version: PUEL
- Guest OSses: Ubuntu Linux, Windows
Re: CloneVDI tool - Discussion & Support
1. Remove swap partition.gb3 wrote:Hi.
I used CloneVDI in order to add space to my virtual disk, but I have a problem.
I installed Ubuntu 14.04 in the Virtual Machine with a VDI disk 8 GB wide.
Now I want to add 72 GB to this disk without reinstalling UBUNTU; with GParted I notice that I have a partition dev/sda 8GB wide, than a 500MB of Linux Swap.
With Virtual Box command line I resized my Virtual Box size to 80 GB, and now in VB setup I see my disk with 80GB, but only 8 GB allocated. In Gparted I have 72GB not allocated space.
So I tried to use Clone VDI in order to enlarge disk dimension, but after Clone_DVI.dvi creation, I can use only 8 GB
Any ideas?
Thanks
2. Use parted or fdisk (parted preferred, since fdisk can't deal with GPT) to enlarge data partition.
3. Use resize2fs to enlarge filesystem to partiton size.
4. Create a swap FILE, it'll help you with future resizes, if that comes.
All this is not a VirtualBox questions, you could find this info in any Linux FAQ.
P.S.
If I were you, I'd just add a second disk instead of enlarging your current one, and moved /home to it.
Much less hassle, and much more useful.
Re: CloneVDI tool - Discussion & Support
You are right about this.
Thank you very much
I posted here my question because I tought it was a Virtual Box trouble with Ubuntu.Much less hassle, and much more useful.
Thank you very much
-
- Posts: 134
- Joined: 7. Feb 2010, 23:41
- Primary OS: MS Windows 7
- VBox Version: PUEL
- Guest OSses: Ubuntu Linux, Windows
Re: CloneVDI tool - Discussion & Support
The simplest idea you can think about, is this: VM is a separate physical system.
Anything you want to do with it, you're doing with a physical system.
Yes, you're not reaching into it with a scrwewdriver to add or replace hardware, but whatever you do with it afterward, doesn't differ from if you were doing it to the real physical system.
Creating partitions, moving data between them - all is examples of the works of your operating system, and you are better off seeking the relevant info on profile forums.
Don't forget to clearly state that you are using VM, though, if you are not sure if that info is relevant to the cause. Even if it doesn't make a difference in most cases, some issues (i.e. video driver issues) need a special treatment.
Anything you want to do with it, you're doing with a physical system.
Yes, you're not reaching into it with a scrwewdriver to add or replace hardware, but whatever you do with it afterward, doesn't differ from if you were doing it to the real physical system.
Creating partitions, moving data between them - all is examples of the works of your operating system, and you are better off seeking the relevant info on profile forums.
Don't forget to clearly state that you are using VM, though, if you are not sure if that info is relevant to the cause. Even if it doesn't make a difference in most cases, some issues (i.e. video driver issues) need a special treatment.
-
- Posts: 4
- Joined: 16. Jan 2015, 12:26
Respect for great tool
Your soft was so useful that I've even registered at Oracle to express you my respect. Enormously useful.
THANK YOU VERY MUCH!
Update: Especially useful was the feature that clears out all unpartitioned space of the processed .vdi. So shrinking the partition (say, with gParted) and cloning the result works just as expected.
THANK YOU VERY MUCH!
Update: Especially useful was the feature that clears out all unpartitioned space of the processed .vdi. So shrinking the partition (say, with gParted) and cloning the result works just as expected.
-
- Site Moderator
- Posts: 39156
- Joined: 4. Sep 2008, 17:09
- Primary OS: MS Windows 10
- VBox Version: PUEL
- Guest OSses: Mostly XP
Re: CloneVDI tool - Discussion & Support
Thanks very much for the positive feedback.
-
- Posts: 4
- Joined: 16. Jan 2015, 12:26
Re: CloneVDI tool - Discussion & Support
Btw, I would suggest to add a couple of paragraphs to your top post that would address the two most common issues one uses CloneVDI for: shrinking and expanding .vdi files. Of course, all info required is in releasenotes.txt... but... anyway, these are very standard operations.
As for shrinking (I didn' try expansion yet), I would suggest step-by-step instruction
...............................................
How to decrease .vdi size if guest system uses only part of available space:
1. Make linked copy of the virtual machine used with source .vdi (using VirtualBoxManager; it creates .vbox files, NOT .vdi)
2. Resize the partition from within the guest machine (e.g. mount .iso with gparted)
3. Make CloneVDI copy of the resized snapshot .vdi with the "Compact drive" option checked
4. In the COPY of the machine remove old .vdi and attach the one from CloneVDI.
................................................
(By the way, steps 1 and 4 smoothly solve the issue from release notes "Instead go carefully through the settings, making absolutely sure that the old and new VMs have the same settings". I tried it only once, but copying the VM automatically copies all settings; anything other would be strange. )
All this is very simple, but maybe will save someone a couple of hours that I've lost on trial and error.
The order of steps supposes that first you make the copy of the machine, and only then clone the .vdi. Thus you can place the clone to the folder of the new VM.
The procedure is completely safe, since both old machine and .vdi remain untouched. Of course, one can attach cloned .vdi to
the old machine directly, but I prefer to waste extra 30 seconds to be on the safe side.
As for shrinking (I didn' try expansion yet), I would suggest step-by-step instruction
...............................................
How to decrease .vdi size if guest system uses only part of available space:
1. Make linked copy of the virtual machine used with source .vdi (using VirtualBoxManager; it creates .vbox files, NOT .vdi)
2. Resize the partition from within the guest machine (e.g. mount .iso with gparted)
3. Make CloneVDI copy of the resized snapshot .vdi with the "Compact drive" option checked
4. In the COPY of the machine remove old .vdi and attach the one from CloneVDI.
................................................
(By the way, steps 1 and 4 smoothly solve the issue from release notes "Instead go carefully through the settings, making absolutely sure that the old and new VMs have the same settings". I tried it only once, but copying the VM automatically copies all settings; anything other would be strange. )
All this is very simple, but maybe will save someone a couple of hours that I've lost on trial and error.
The order of steps supposes that first you make the copy of the machine, and only then clone the .vdi. Thus you can place the clone to the folder of the new VM.
The procedure is completely safe, since both old machine and .vdi remain untouched. Of course, one can attach cloned .vdi to
the old machine directly, but I prefer to waste extra 30 seconds to be on the safe side.
-
- Site Moderator
- Posts: 39156
- Joined: 4. Sep 2008, 17:09
- Primary OS: MS Windows 10
- VBox Version: PUEL
- Guest OSses: Mostly XP
Re: CloneVDI tool - Discussion & Support
If "linked copy" refers to a linked clone, then that isn't really a safe procedure. Creating a linked clone modifies the original VM, and the clone too expects to use a difference image.
At the time the release notes were written, VirtualBox had no facility to clone a VM, and only command line support for cloning a disk. I agree that some of the procedures in the release notes could be simplified nowadays.
At the time the release notes were written, VirtualBox had no facility to clone a VM, and only command line support for cloning a disk. I agree that some of the procedures in the release notes could be simplified nowadays.
-
- Posts: 4
- Joined: 16. Jan 2015, 12:26
Re: CloneVDI tool - Discussion & Support
Yes, it should've been "linked clone", sorry. It does create an extra snapshot in the source VM, but the previous snapshot remains unchanged. So we can discard the extra snapshot in the source VM. Or am I missing something?mpack wrote:If "linked copy" refers to a linked clone, then that isn't really a safe procedure. Creating a linked clone modifies the original VM, and the clone too expects to use a difference image.
Yes, the cloned machine expects to use the difference image. But step 4 of the suggested procedure substitutes the link to the source .vdi with the cloned .vdi (using official VBoxManager). Or maybe there are some hidden traps?
-
- Site Moderator
- Posts: 39156
- Joined: 4. Sep 2008, 17:09
- Primary OS: MS Windows 10
- VBox Version: PUEL
- Guest OSses: Mostly XP
Re: CloneVDI tool - Discussion & Support
I don't really want to get into a technical discussion of how snapshots work, as that would be off topic here.
-
- Posts: 4
- Joined: 16. Jan 2015, 12:26
Re: CloneVDI tool - Discussion & Support
Sure. Anyway many thanks for the great soft.mpack wrote:I don't really want to get into a technical discussion of how snapshots work, as that would be off topic here.
Make a bootable external hdd from an archlinux.vdi
Hello everybody from Mauritius ~!
I am Caron from Mauritius. I run Mint 17 Quiana 64 bit and an Archlinux Vm. My aim is to convert my archlinux vdi into a bootable external hdd ( I use a laptop so I'll be using a laptop external hdd in a usb casing.)
I read that I had first to convert the .vdi into a .raw and then use dd command. Unfortunately I failed because the commands are not working- unable to find the .vdi on my system.
Can u help please ?
Thanks in advance.
Caron
I am Caron from Mauritius. I run Mint 17 Quiana 64 bit and an Archlinux Vm. My aim is to convert my archlinux vdi into a bootable external hdd ( I use a laptop so I'll be using a laptop external hdd in a usb casing.)
I read that I had first to convert the .vdi into a .raw and then use dd command. Unfortunately I failed because the commands are not working- unable to find the .vdi on my system.
Can u help please ?
Thanks in advance.
Caron
-
- Site Moderator
- Posts: 39156
- Joined: 4. Sep 2008, 17:09
- Primary OS: MS Windows 10
- VBox Version: PUEL
- Guest OSses: Mostly XP
Re: CloneVDI tool - Discussion & Support
Please post non-CloneVDI questions in an appropriate forum.