Vmware migration question

webservio

Renowned Member
May 13, 2009
106
1
83
For the past few months I have read this section several times:

http://pve.proxmox.com/wiki/Migration_of_servers_to_Proxmox_VE

However I think some points are not clear:

1. Vmware virtualization utility creates several .vmdk files (in chunks) that is not usable which you must use the following utility vmware-vdiskmanager. I looked at several website about using this utility but still not clear on the exact command. Can some one who had success can you please explain? I know it seems like an easy step but no one has very much explained the exact step on how to convert these darn small .vmdk files into one large one.
2. Lets assume that you create one large .vmdk: In proxmox 1.5 the drop down choiice for disk format states that it supports .vmdk, is that true or you must convert to qcow2? Please explain?


Thanks in advance
 
For the past few months I have read this section several times:

http://pve.proxmox.com/wiki/Migration_of_servers_to_Proxmox_VE

However I think some points are not clear:

1. Vmware virtualization utility creates several .vmdk files (in chunks) that is not usable which you must use the following utility vmware-vdiskmanager. I looked at several website about using this utility but still not clear on the exact command. Can some one who had success can you please explain? I know it seems like an easy step but no one has very much explained the exact step on how to convert these darn small .vmdk files into one large one.

the wiki pages describes the command, e.g.
Code:
vmware-vdiskmanager -r win2003.vmdk -t 0 win2003-pve.vmdk
2. Lets assume that you create one large .vmdk: In proxmox 1.5 the drop down choiice for disk format states that it supports .vmdk, is that true or you must convert to qcow2? Please explain?
Thanks in advance

convert to raw, best performance.
 
Do you so the following command for each small .vmdk files?

vmware-vdiskmanager -r win2003.vmdk -t 0 win2003-pve.vmdk

That is the part that I still not sure.
 
you need one vmdk file per disk if you have 2 GB vmdk slices so you need to convert it (but only then):

here is the help file from the VMware Virtual Disk Manager explaining the parameters:

Code:
VMware Virtual Disk Manager - build 261024.
Usage: vmware-vdiskmanager.exe OPTIONS <disk-name> | <mount-point>
Offline disk manipulation utility
  Operations, only one may be specified at a time:
     -c                   : create disk.  Additional creation options must
                            be specified.  Only local virtual disks can be
                            created.
     -d                   : defragment the specified virtual disk. Only
                            local virtual disks may be defragmented.
     -k                   : shrink the specified virtual disk. Only local
                            virtual disks may be shrunk.
     -n <source-disk>     : rename the specified virtual disk; need to
                            specify destination disk-name. Only local virtual
                            disks may be renamed.
     -p                   : prepare the mounted virtual disk specified by
                            the mount point for shrinking.
     -r <source-disk>     : convert the specified disk; need to specify
                            destination disk-type.  For local destination disks
                            the disk type must be specified.
     -x <new-capacity>    : expand the disk to the specified capacity. Only
                            local virtual disks may be expanded.
     -R                   : check a sparse virtual disk for consistency and attempt
                            to repair any errors.
     -D                   : make disk deletable.  This should only be used on disks
                            that have been copied from another product.

  Other Options:
     -q                   : do not log messages

  Additional options for create and convert:
     -a <adapter>         : (for use with -c only) adapter type
                            (ide, buslogic, lsilogic). Pass lsilogic for other adapter types.
     -s <size>            : capacity of the virtual disk
     -t <disk-type>       : disk type id

  Options for remote disks:
     -h <hostname>        : hostname of remote server
     -u <username>        : username for remote server
     -f <filename>        : file containing password
     -P <port>            : optional TCP port number (default: 902)
     -S                   : specifies that the source disk is remote, by default

                            the remote options are assumed to refer to the
                            destination.
  Disk types:
      0                   : single growable virtual disk
      1                   : growable virtual disk split in 2GB files
      2                   : preallocated virtual disk
      3                   : preallocated virtual disk split in 2GB files
      4                   : preallocated ESX-type virtual disk
      5                   : compressed disk optimized for streaming
      6                   : thin provisioned virtual disk - ESX 3.x and above

     The capacity can be specified in sectors, KB, MB or GB.
     The acceptable ranges:
                           ide adapter : [1MB, 2040.0GB]
                           scsi adapter: [1MB, 2040.0GB]
        ex 1: vmware-vdiskmanager.exe -c -s 850MB -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 36GB myDisk.vmdk
        ex 5: vmware-vdiskmanager.exe -n sourceName.vmdk destinationName.vmdk
        ex 6: vmware-vdiskmanager.exe -r sourceDisk.vmdk -t 4 -h esx-name.mycompany.com \
              -u username -f passwordfile "[storage1]/path/to/targetDisk.vmdk"
        ex 7: vmware-vdiskmanager.exe -k myDisk.vmdk
        ex 8: vmware-vdiskmanager.exe -p <mount-point>
              (A virtual disk first needs to be mounted at <mount-point>)
 
Do you so the following command for each small .vmdk files?
vmware-vdiskmanager -r win2003.vmdk -t 0 win2003-pve.vmdk
That is the part that I still not sure.

look at the vm config in vmware host: for each virtual disk, you have to find the vmdk file configured. all the others you can find in the vm folder are used from vmware an you don't need to convert.
i converted the "vmdk file configured" and used -r (convert) with -t 2 (preallocated virtual disk) and saved the destination vmdk(s) to another folder.

there were 2 files (copied.vmdk small and copied-flatvmdk big) then, converted the "big" vmdk with qemu-img to raw. then moved this to /var/lib/vz/images/<yourvmid> and added from pve gui
just worked.

see
-rwxr--r-- 1 dadmin dadmin 8589934592 2010-08-05 13:20 copied-flat.vmdk
-rw-r--r-- 1 root root 8589934592 2010-08-05 13:28 copied.raw
-rwxr--r-- 1 dadmin dadmin 350 2010-08-05 13:20 copied.vmdk
d

Marco
 
Last edited:
...why should it be not available, if you have running vmware machines? anyway, it comes with free products from vmware, so you can get it.
Perhaps you intended: <<what if i wish to use other tools, and not those freely available from vmware>>?

Marco
 

About

The Proxmox community has been around for many years and offers help and support for Proxmox VE, Proxmox Backup Server, and Proxmox Mail Gateway.
We think our community is one of the best thanks to people like you!

Get your subscription!

The Proxmox team works very hard to make sure you are running the best software and getting stable updates and security enhancements, as well as quick enterprise support. Tens of thousands of happy customers have a Proxmox subscription. Get yours easily in our online shop.

Buy now!