Solution for compressing virtual machine files in VirtualBox

Source: Internet
Author: User


Currently, virtual machines in VirtualBox will apply for space until the maximum value of dynamic space is reached. Therefore, the issue of compressing VM files and releasing space is caused. Www.2cto.com first, if the Virtual Machine file is in vmdk or other non-vdi format, you must first convert it to vdi format. The command is as follows: VBoxManage clonehd source. vmdk target. in vdi -- format VDI, where the command VBoxManage is in C: \ Program Files \ VirtualBox \ VBoxManage.exe, source and target are the original Files to be converted and the target Files are executed slowly, www.2cto.com is then compressed. Objective: To set the useless junk space in the system to zero and then release the "zero" Byte space, use VBoxManage modifyhd tool to compress VDI disk image file which is improved below from http://www.bkjia.com/ OS /201301/184942.htmlWindows Virtual Machine 1. virtual Machine: delete System junk files and run the disk sorting program... 2. virtual Machine: Use SDelete to write "0", http://up.2cto.com/2013/0122/20130122102456864.zip, and execute "sdelete-c" under the command line "... shutdown... 3. physical HOST: Run "VBoxManage modifyhd/the-path-of-VDI.vdi -- compact"
Linux Virtual Machine 1. virtual Machine: cleanup and uninstallation of System junk files 2. virtual Machine: write "zero", as if "dd if =/dev/zero of =/fillerup. the zero method is not very effective. After several hardships, I found a very old "Ultimate Way" on the official website )! 2.1 start the virtual machine with a LiveCD (ubuntu) and use the System-Administration-GParted partition software to minimize the virtual hard disk space...
Create a new partition on www.2cto.com 2.2 in the space just vacated, and run "dd if =/dev/zero of =/dev /{?} ", Then delete this partition 2.3 back to the primary partition, restore all its space, application... shutdown... 3. Physical HOST: Execute" VBoxManage modifyhd/the-path-of-VDI.vdi -- compact"
Www.2cto.com OK!

Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.