I am worried that the hard disk capacity of the created virtual machine will be too large to occupy the real hard disk space, and the hard disk capacity will be set to a small value. However, after installing the system for the virtual machine, I will install other software, hard disk capacity is insufficient. This requires a way to expand the Ubuntu root partition. I will introduce this method below. 1.modify the hard disk size. The installation directory of wmwarehas an executable file named vmware-vdiskmanager.exe. Open the console in windows and enter the WMware installation directory. Run the following command (assume that
I am worried that the hard disk capacity of the created virtual machine will be too large to occupy the real hard disk space, and the hard disk capacity will be set to a small value. However, after installing the system for the virtual machine, I will install other software, hard disk capacity is insufficient. This requires a way to expand the Ubuntu root partition. I will introduce this method below.
1. Modify the hard disk size
In the wmwareinstallation directory, there is an executable file named vmware-vdiskmanager.exe. Open the console in windows and enter the WMware installation directory, and run the following command (assume that my VM file is in E: \ VMware \ Ubuntu. vmdk ):
Vmware-vdiskmanager.exe-x 16 Gb e: \ VMware \ Ubuntu. vmdk
Among them:-x 16 Gb means to expand the hard disk to 16 Gb, followed by e: \ VMware \ Ubuntu. vmdk is a virtual machine file.
After this process is completed, turn on vmware again and run the VM. The size of the hard disk displayed on the VM has changed.
The following information is displayed when the operation is correct:
Note:
1. If space exists in the path, enclose the path with double quotation marks.
2. the above process is performed on the windows console.
3. the above process must be completed when vmware is disabled.
2. Hard Disk partitioning
Run the fdisk-l command to view the hard disk:
At this time, the hard disk size has changed to 16 GB (17.2 GB), because the new hard disk is not partitioned, so it does not appear below, the following sda1, sda2, sda5 is a usable hard disk, the total volume is still the original 6 GB. Now we need to partition the new hard disk. There is a software called gparted, can operate Linux partition like partitionmagic in Windows, on the official website we can download to the gparted-live-0.8.0-5.iso (http://nchc.dl.sourceforge.net/project/gparted/gparted-live-stable/0.8.0-5/gparted-live-0.8.0-5.iso) this file, then load in VMware's optical drive and restart the virtual machine, when the VM is enabled, Press ESC to enable the BIOS of the VM from the optical drive, for example:
Select GParted Live (Default settings) in the following interface and click Enter:
Then go to the following interface to partition:
Finally, partition the hard disk. We want to expand the size of the Ubuntu root partition, so we can increase sda1. However, if the swap partition is behind sda1 and sda1 cannot be adjusted, you can delete the swap first, increase sda1, and leave the swap as much space as the memory, then convert the space into a swap partition. Click restart to restart the application. Run the fdisk-l command to see that the Ubuntu root partition has become larger:
GParted: Click here
GParted: Click here
Reading:
Ubuntu combines partition http://www.linuxidc.com/Linux/2010-06/26689.htm with GParted
Lossless http://www.linuxidc.com/Linux/2010-06/26737.htm for Linux partitions and NTFS partitions using GParted and acronis
GParted: First aid your hard drive data http://www.linuxidc.com/Linux/2011-02/32525.htm
Ubuntu 10.04 compiles the latest GParted 0.8.0, and supports hard disks with sectors> bytes! Http://www.linuxidc.com/Linux/2011-05/35690.htm
Use GParted-LiveCD to resize Ubuntu partition http://www.linuxidc.com/Linux/2013-06/85747.htm
Good partition tool GParted under Ubuntu [text] http://www.linuxidc.com/Linux/2008-06/13642.htm
For more information about Ubuntu, see Ubuntu special page http://www.linuxidc.com/topicnews.aspx? Tid = 2
This article permanently updates the link address: Http://www.linuxidc.com/Linux/2015-03/115027.htm