Expand the virtual hard disk size in VMWARE (*. vmdk)

Source: Internet
Author: User

 

Http://blog.csdn.net/bshawk/archive/2008/01/28/2070587.aspx

 

 

When I recently compiled the kernel 2.6.22, I found that the FC6 hard disk space on the virtual machine was insufficient. As a result, I wanted to expand the hard disk size. After checking the information, someone on the Internet said that a new. vmdk would be created and mounted to FC6. I personally think this method is not good. Is there a way to directly expand the size of the original vmdk. After checking some information, click "vmwareself-help" and find the tool "vmware-vdiskmanager.exe" (located in the vmware installation path: C:/Program Files/VMware Workstation.

Let's take a look at the help book of vmware-vdiskmanager.exe(directly run vmware-vdiskmanager.exe without getting started ):

VMware Virtual Disk Manager-build 34685.
Usage: vmware-vdiskmanager.exe options diskname | drive-letter:
Offline disk manipulation Utility
Options:
-C: create disk; need to specify other create options
-D: defragment the specified Virtual Disk
-K: shrink the specified virtual disk
-N <source-disk>: rename the specified virtual disk; need
Specify destination disk-name
-P: prepare the mounted virtual disk specified
The drive-letter for shrinking
-Q: do not log messages
-R <source-disk>: convert the specified disk; need to specify
Destination disk-type
-X <New-capacity>: Expand the disk to the specified capacity
 
Additional options for create and convert:
-A <adapter>: (for use with-C only) adapter type (IDE, buslogic or lsilogic)
-S <size>: capacity of the Virtual Disk
-T <disk-type>: disk type ID
 
Disk types:
0: single growable virtual disk
1: growable virtual disk split in 2 Gb files
2: preallocated virtual disk
3: preallocated virtual disk split in 2 Gb files
 
The capacity can be specified in sectors, Kb, Mb or Gb.
The acceptable ranges:
Ide adapter: [100.0 Mb, 950.0 Gb]
SCSI adapter: [100.0 MB, 950.0 GB]
Vmware-vdiskmanager.exe-C-s 850 mb-A ide-T 0 myidedisk. vmdk
Ex 2: vmware-vdiskmanager.exe-D mydisk. vmdk
Ex 3: vmware-vdiskmanager.exe-r sourcedisk. vmdk-T 0 destinationdisk. vmdk
Ex 4: vmware-vdiskmanager.exe-x 36 GB mydisk. vmdk
Vmware-vdiskmanager.exe-N sourcename. vmdk destinationname. vmdk
Ex 6: vmware-vdiskmanager.exe-K mydisk. vmdk
Ex 7: vmware-vdiskmanager.exe-p m:
(A Virtual Disk first needs to be mounted at M:
Using the VMware diskmount utility .)

No, the above ex4 has provided the command to expand the hard disk. For example, if I want to expand to 10 Gb, the command is as follows:

Vmware-vdiskmanager.exe-x 10 Gb linux-fc6.vmdk

Other references:

Vmware official information: http://www.vmware.com/support/ws45/doc/disks_vdiskmanager_eg_ws.html

 

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.