Date post: | 04-Apr-2018 |
Category: |
Documents |
Upload: | mallikarjuna-reddy-pallaki |
View: | 231 times |
Download: | 0 times |
of 18
7/29/2019 vmware commands
1/18
Using esxcfg
The following list of commands shows how to manage various components of the ESX Server configuration.
esxcfg-auth Used to configure an ESX Server host to support network-based authentication methods (e.g., Active
Directory [AD]).
- -enablead to configure Service Console for AD authentication
- -addomain to set the domain the Service Console will authenticate against
- -addc to set the domain controller to authenticate against for AD authentication
- -usecrack to enable the pam_cracklib for managing password complexity
esxcfg-firewall Used to query, enable, and disable services on the Service Console firewall. Note that everything
is blocked by default.
esxcfg-info Used to review the hardware information for Service Console and VMKernel.
-w to print hardware information
-s to print storage and disk information
-n to print network information
esxcfg-mpathUsed to view and configure the multipathing settings for an ESX Server hosts fibre channel or
iSCSI storage devices. Multipathing is the ability to connect to SAN or iSCSI storage devices through multiple pahs,
and it suppose that the host has at least (and it is enough) 2 HBA cards.
-p to set the policy for mru (most recently used), fixed, or rr (round-robin)
-P to define a path to operate on -s with on or off to enable or disale a specific path
-f to set a specified path as the preferred
Esxcfg-nas Used to configure NAS storage on ESX Server. NAS is supported by ESX but limits its features like
vMotion which is not allowed in this case (but still it is a low cost solution)
-l to list all NAS
-a to add a new NAS datastore on a specified host
-o to provide the name of the NAS host
-s to provide the name of the NAS share
-delete to delete a NAS datastore
esxcfg-nics Used to obtain information about and configure the physical network adapters installed in an ESX
Server host.
-s to set the speed of a card to 10,100,1000, or 10,000.
-d to set the duplex to half or full
7/29/2019 vmware commands
2/18
esxcfg-route Used to configure the default gateway for the VMkernel.
esxcfg-swiscsi Used to configure the software iSCSI component of ESX Server.
-e to enable software iSCSI
-d to disable software iSCSI
-q to query if software iSCSI is enabled
-s to scan for new LUNs using software iSCSI
esxcfg-vmhbadevs Used to obtain information about the LUNs available to the ESX Server.
-m to print the VMFS UUID if formatted as VMFS esxcfg-vmknic Used to configure the VMkernel NIC.
-a to add a VMkernel port group
-d to delete a VMKernel
-e to enable the VMkernel NIC
-D to disable the VMkernel port
-i to set the IP address of the VMkernel NIC
-n to set the network mask for the IP of the call
esxcfg-vswifUsed to set the parameters of the Service Console; the Service Console interface allow management
of the ESX.
-a to add a Service Console NIC (this option is predicated on having IP information and port group names)
-d to delete a the Service Console NIC
-e to enable the Service Console NIC
-D to disable the Service Console NIC
-p to set the port group name for the Service Console NIC
-i to set the IP address to be used for the Service Console NIC
-n to set the network mask of for the Service Console NIC
esxcfg-vswitch Used to add, remove, or modify a virtual switch. All network communications of virtual
machines go through virtual switches.
-l to list all existing virtual switches
-L to unlink a network adapter from a hosting provider
-U to link a network adapter
-v to set the vLAN ID for a port group
-A to add a new port group
-D to delete a port group
-C to query for the existence of a port group name
Using vicfg
Just to remid you, ESX 3.5i comes without the management virtual machine that everybody takes for the OS of
the ESX! In fact, the ESX 3.5i is a 32Mb OS, in other words, the least set of commands to manage VMs.
vicfgvicfg-nas Used to manipulate NAS/NFS.
- -add or -a to add a new NAS file system
- -delete or -d to delete a NAS file system
- -help to display help text
7/29/2019 vmware commands
3/18
- -nasserver or -o followed by to add the hostname of the new NAS file system
- -share or -s used with -a to provide the name of the directory that is exported on the NAS device
- -vihost or -h followed by to direct the command to a particular ESX Server host
vicfg-vmhbadevs Used to discover information about available LUNs.
- -help to display help text
- -query or -q to print the output in 2.6 compatibility mode
- -vihost or -h followed by to direct the command to a particular ESX Server host
- -vmfs or -m to print the VMFS UUID in addition to the HBA and /dev names for LUNs that are formatted as VMFS
vicfg-mpath Used to manipulate multipathing.
vicfg-rescan Used to perform a rescan for discovering new LUNs.
- -help to display help text
- -vihost or -h followed by to direct the command to a particular ESX Server host
to provide the name of the adapter to rescan (i.e., vmhba1)
vicfg-dumppart Used to query, set, and scan diagnostic partitions on ESXi.
vicfg-nics Used to report on and manage physical network adapters.
vicfg-vmknic Used to configure virtual network adapters.
vicfg-vswitch Used to configure virtual switches.
vicfg-route Used to configure the default route for VMkernel ports.
Vicfg-ntp Used to configure NTP settings.
vmware-cmd /vmfs/volume/vmfslabel/VMName/VMName.vmx getstate
Sample:getstat
Retrieve power state of the VM: off, on, suspended, stuck
Getstat
[root@esxhost root]# vmware-cmd /vmfs/volumes/44ebf538-51cc7998-2525-
00145e1b556a/printer/printer.vmx getstate
http://www.esxguide.com/esx/index.php?option=com_mambowiki&page=getstat&page_heading=&show_pageheading=&allowanonymoususers=http://www.esxguide.com/esx/index.php?option=com_mambowiki&page=getstat&page_heading=&show_pageheading=&allowanonymoususers=http://www.esxguide.com/esx/index.php?option=com_mambowiki&page=getstat&page_heading=&show_pageheading=&allowanonymoususers=http://www.esxguide.com/esx/index.php?option=com_mambowiki&page=getstat&page_heading=&show_pageheading=&allowanonymoususers=7/29/2019 vmware commands
4/18
Reboot
vmware-cmd vmfs/volume/vmfslabel/VMName/VMName.vmx reset trysoft
Sample:reboot
Reboot the VM. First try a nice shutdown, then if necessary force a shutdown before reboot
root@esxhost root]# vmware-cmd /vmfs/volumes/44ebf538-51cc7998-2525-
00145e1b556a/printer/printer.vmx reset trysoft
reset(trysoft) = 1
vmware-cmd VM Management in the console
vmware-cmd -l
Sample:vmware-cmd -l
List path and names of .registered VM vmx files on the present host
Very important!
Use the path with the UUID (vmfslabel) where requested in vmware-cmd
use vmware-cmd -l command to retrieve the UUID
Vmware-cmd -l
[root@esxhost root]# vmware-cmd -l
/vmfs/volumes/44ee9812-da790870-b7f7-00145e1b5242/cumuli/cumuli.vmx/vmfs/volumes/44ebf538-51cc7998-2525-00145e1b556a/printer/printer.vmx
vmware-cmd /vmfs/volume/vmfslabel/VMName/VMName.vmx getstate
Sample:getstat
Retrieve power state of the VM: off, on, suspended, stuck
Getstat
[root@esxhost root]# vmware-cmd /vmfs/volumes/44ebf538-51cc7998-2525-00145e1b556a/printer/printer.vmx
http://www.esxguide.com/esx/index.php?option=com_mambowiki&page=reboot&page_heading=&show_pageheading=&allowanonymoususers=http://www.esxguide.com/esx/index.php?option=com_mambowiki&page=reboot&page_heading=&show_pageheading=&allowanonymoususers=http://www.esxguide.com/esx/index.php?option=com_mambowiki&page=reboot&page_heading=&show_pageheading=&allowanonymoususers=http://www.esxguide.com/esx/index.php?option=com_mambowiki&page=vmware-cmd%20-l&page_heading=&show_pageheading=&allowanonymoususers=http://www.esxguide.com/esx/index.php?option=com_mambowiki&page=vmware-cmd%20-l&page_heading=&show_pageheading=&allowanonymoususers=http://www.esxguide.com/esx/index.php?option=com_mambowiki&page=vmware-cmd%20-l&page_heading=&show_pageheading=&allowanonymoususers=http://www.esxguide.com/esx/index.php?option=com_mambowiki&page=getstat&page_heading=&show_pageheading=&allowanonymoususers=http://www.esxguide.com/esx/index.php?option=com_mambowiki&page=getstat&page_heading=&show_pageheading=&allowanonymoususers=http://www.esxguide.com/esx/index.php?option=com_mambowiki&page=getstat&page_heading=&show_pageheading=&allowanonymoususers=http://www.esxguide.com/esx/index.php?option=com_mambowiki&page=getstat&page_heading=&show_pageheading=&allowanonymoususers=http://www.esxguide.com/esx/index.php?option=com_mambowiki&page=vmware-cmd%20-l&page_heading=&show_pageheading=&allowanonymoususers=http://www.esxguide.com/esx/index.php?option=com_mambowiki&page=reboot&page_heading=&show_pageheading=&allowanonymoususers=7/29/2019 vmware commands
5/18
getstate
getstate() = on
vmware-cmd vmfs/volume/vmfslabel/VMName/VMName.vmx reset trysoft
Sample:reboot
Reboot the VM. First try a nice shutdown, then if necessary force a shutdown before reboot
Reboot
[root@esxhost root]# vmware-cmd /vmfs/volumes/44ebf538-51cc7998-2525-00145e1b556a/printer/printer.vmx
reset trysoft
reset(trysoft) = 1
vmware-cmd vmfs/volume/vmfslabel/VMName/VMName.vmx start
Sample:startPower on the VM
Start
[root@esxhost root]# vmware-cmd /vmfs/volumes/44ebf538-51cc7998-2525-00145e1b556a/printer/printer.vmx
start
start() = 1
vmware-cmd vmfs/volume/vmfslabel/VMName/VMName.vmx stop trysoftvmware-cmd vmfs/volume/vmfslabel/VMName/VMName.vmx stop hard
Sample:shutdown
Shutdown/halt the VM. First try a nice shutdown, then if necessary force a shutdown. Finally power off.
http://www.esxguide.com/esx/index.php?option=com_mambowiki&page=reboot&page_heading=&show_pageheading=&allowanonymoususers=http://www.esxguide.com/esx/index.php?option=com_mambowiki&page=reboot&page_heading=&show_pageheading=&allowanonymoususers=http://www.esxguide.com/esx/index.php?option=com_mambowiki&page=reboot&page_heading=&show_pageheading=&allowanonymoususers=http://www.esxguide.com/esx/index.php?option=com_mambowiki&page=start&page_heading=&show_pageheading=&allowanonymoususers=http://www.esxguide.com/esx/index.php?option=com_mambowiki&page=start&page_heading=&show_pageheading=&allowanonymoususers=http://www.esxguide.com/esx/index.php?option=com_mambowiki&page=shutdown&page_heading=&show_pageheading=&allowanonymoususers=http://www.esxguide.com/esx/index.php?option=com_mambowiki&page=shutdown&page_heading=&show_pageheading=&allowanonymoususers=http://www.esxguide.com/esx/index.php?option=com_mambowiki&page=shutdown&page_heading=&show_pageheading=&allowanonymoususers=http://www.esxguide.com/esx/index.php?option=com_mambowiki&page=shutdown&page_heading=&show_pageheading=&allowanonymoususers=http://www.esxguide.com/esx/index.php?option=com_mambowiki&page=start&page_heading=&show_pageheading=&allowanonymoususers=http://www.esxguide.com/esx/index.php?option=com_mambowiki&page=reboot&page_heading=&show_pageheading=&allowanonymoususers=7/29/2019 vmware commands
6/18
Shutdown
[root@esxhost root]# vmware-cmd /vmfs/volumes/44ebf538-51cc7998-2525-00145e1b556a/printer/printer.vmxstop trysoft
stop(trysoft) = 1
vmware-cmd vmfs/volume/vmfslabel/VMName/VMName.vmx suspend
Sample:suspendSuspend the VM
Suspend
[root@esxhost root]# vmware-cmd /vmfs/volumes/44ebf538-51cc7998-2525-00145e1b556a/printer/printer.vmx
suspend
suspend() = 1
vmware-cmd vmfs/volume/vmfslabel/VMName/VMName.vmx hassnapshot
Sample:hassnapshots
Query if VM has a snapshot
Hassnapshots
[root@esxhost root]# vmware-cmd /vmfs/volumes/44ebf538-51cc7998-2525-00145e1b556a/printer/printer.vmxhassnapshot
hassnapshot() =
vmware-cmd createsnapshot name description quiesce memory
Sample:createsnapshot
http://www.esxguide.com/esx/index.php?option=com_mambowiki&page=suspend&page_heading=&show_pageheading=&allowanonymoususers=http://www.esxguide.com/esx/index.php?option=com_mambowiki&page=suspend&page_heading=&show_pageheading=&allowanonymoususers=http://www.esxguide.com/esx/index.php?option=com_mambowiki&page=hassnapshots&page_heading=&show_pageheading=&allowanonymoususers=http://www.esxguide.com/esx/index.php?option=com_mambowiki&page=hassnapshots&page_heading=&show_pageheading=&allowanonymoususers=http://www.esxguide.com/esx/index.php?option=com_mambowiki&page=hassnapshots&page_heading=&show_pageheading=&allowanonymoususers=http://www.esxguide.com/esx/index.php?option=com_mambowiki&page=createsnapshot&page_heading=&show_pageheading=&allowanonymoususers=http://www.esxguide.com/esx/index.php?option=com_mambowiki&page=createsnapshot&page_heading=&show_pageheading=&allowanonymoususers=http://www.esxguide.com/esx/index.php?option=com_mambowiki&page=createsnapshot&page_heading=&show_pageheading=&allowanonymoususers=http://www.esxguide.com/esx/index.php?option=com_mambowiki&page=createsnapshot&page_heading=&show_pageheading=&allowanonymoususers=http://www.esxguide.com/esx/index.php?option=com_mambowiki&page=hassnapshots&page_heading=&show_pageheading=&allowanonymoususers=http://www.esxguide.com/esx/index.php?option=com_mambowiki&page=suspend&page_heading=&show_pageheading=&allowanonymoususers=7/29/2019 vmware commands
7/18
Quiesce will quiesce file system writes
Memory will grab the memory state (will lose pings during this)
Createsnapshot
[root@esxhost root]# vmware-cmd /vmfs/volumes/44ebf538-51cc7998-2525-00145e1b556a/printer/printer.vmxcreatesnapshot "snap1" "before patching" quiesce memory
createsnapshot(snap1 before patching quiesce memory) = 1[root@esxhost root]# vmware-cmd /vmfs/volumes/44ebf538-51cc7998-2525-00145e1b556a/printer/printer.vmx
hassnapshot
hassnapshot() = 1
Retrieved from "http://10.3.0.105/esx/components/com_mambowiki/index.php/Createsnapshot"
vmware-cmd vmfs/volume/vmfslabel/VMName/VMName.vmx revertsnapshot
Sample:reverttosnapshot
Revert to previous created snapshot (you loose the current VM state!)
Reverttosnapshot
[root@vs03 root]# vmware-cmd /vmfs/volumes/44ebf538-51cc7998-2525-00145e1b556a/printer/printer.vmx
revertsnapshotrevertsnapshot() = 1
vmware-cmd vmfs/volume/vmfslabel/VMName/VMName.vmx removesnapshots
Sample:removesnapshot
Remove previous created snapshots (you keep the current VM state!)
Removesnapshot
[root@esxhost root]# vmware-cmd /vmfs/volumes/44ebf538-51cc7998-2525-00145e1b556a/printer/printer.vmxremovesnapshotsremovesnapshots() = 1
http://10.3.0.105/esx/components/com_mambowiki/index.php/Createsnapshothttp://10.3.0.105/esx/components/com_mambowiki/index.php/Createsnapshothttp://www.esxguide.com/esx/index.php?option=com_mambowiki&page=reverttosnapshot&page_heading=&show_pageheading=&allowanonymoususers=http://www.esxguide.com/esx/index.php?option=com_mambowiki&page=reverttosnapshot&page_heading=&show_pageheading=&allowanonymoususers=http://www.esxguide.com/esx/index.php?option=com_mambowiki&page=reverttosnapshot&page_heading=&show_pageheading=&allowanonymoususers=http://www.esxguide.com/esx/index.php?option=com_mambowiki&page=removesnapshot&page_heading=&show_pageheading=&allowanonymoususers=http://www.esxguide.com/esx/index.php?option=com_mambowiki&page=removesnapshot&page_heading=&show_pageheading=&allowanonymoususers=http://www.esxguide.com/esx/index.php?option=com_mambowiki&page=removesnapshot&page_heading=&show_pageheading=&allowanonymoususers=http://www.esxguide.com/esx/index.php?option=com_mambowiki&page=removesnapshot&page_heading=&show_pageheading=&allowanonymoususers=http://www.esxguide.com/esx/index.php?option=com_mambowiki&page=reverttosnapshot&page_heading=&show_pageheading=&allowanonymoususers=http://10.3.0.105/esx/components/com_mambowiki/index.php/Createsnapshot7/29/2019 vmware commands
8/18
vmware-cmd -s register vmfs/volume/vmfslabel/VMName/VMName.vmx
Sample:register
Register VM (add to inventory)
Register
[root@esxhost root]# vmware-cmd -s register /vmfs/volumes/44ebf538-51cc7998-2525-
00145e1b556a/printer/printer.vmxregister(/vmfs/volumes/44ebf538-51cc7998-2525-00145e1b556a/printer/printer.vmx) = 1
vmware-cmd -s unregister vmfs/volume/vmfslabel/VMName/VMName.vmx
Sample:unregister
Unregister VM (add to inventory)
Unregister
[root@esxhost root]# vmware-cmd -s unregister /vmfs/volumes/44ebf538-51cc7998-2525-
00145e1b556a/printer/printer.vmxunregister(/vmfs/volumes/44ebf538-51cc7998-2525-00145e1b556a/printer/printer.vmx) = 1
vmware-cmd vmfs/volume/vmfslabel/VMName/VMName.vmx answer
Sample:answer
answer pending request for userinput
Answer
[root@esxhost root]# vmware-cmd /vmfs/volumes/44ebf538-51cc7998-2525-00145e1b556a/printer/printer.vmx
answers
No questions pending.
In this case there is no pending input request. If there is any panding input request you will be promptet for theanswser.
http://www.esxguide.com/esx/index.php?option=com_mambowiki&page=register&page_heading=&show_pageheading=&allowanonymoususers=http://www.esxguide.com/esx/index.php?option=com_mambowiki&page=register&page_heading=&show_pageheading=&allowanonymoususers=http://www.esxguide.com/esx/index.php?option=com_mambowiki&page=register&page_heading=&show_pageheading=&allowanonymoususers=http://www.esxguide.com/esx/index.php?option=com_mambowiki&page=unregister&page_heading=&show_pageheading=&allowanonymoususers=http://www.esxguide.com/esx/index.php?option=com_mambowiki&page=unregister&page_heading=&show_pageheading=&allowanonymoususers=http://www.esxguide.com/esx/index.php?option=com_mambowiki&page=unregister&page_heading=&show_pageheading=&allowanonymoususers=http://www.esxguide.com/esx/index.php?option=com_mambowiki&page=answer&page_heading=&show_pageheading=&allowanonymoususers=http://www.esxguide.com/esx/index.php?option=com_mambowiki&page=answer&page_heading=&show_pageheading=&allowanonymoususers=http://www.esxguide.com/esx/index.php?option=com_mambowiki&page=answer&page_heading=&show_pageheading=&allowanonymoususers=http://www.esxguide.com/esx/index.php?option=com_mambowiki&page=answer&page_heading=&show_pageheading=&allowanonymoususers=http://www.esxguide.com/esx/index.php?option=com_mambowiki&page=unregister&page_heading=&show_pageheading=&allowanonymoususers=http://www.esxguide.com/esx/index.php?option=com_mambowiki&page=register&page_heading=&show_pageheading=&allowanonymoususers=7/29/2019 vmware commands
9/18
vmkfstools manage VM Disks
This tool is from VMware. It is used for Virtual-disk and VMFS management.
Be aware, always use Virtual Center GUI to create VMFS Volumes. Otherwise you will end up with
an unaligned VMFS partition and decreased performance.
vmkfstools VM-Disk and VMFS Management in the console
vmkfstools -X
Extend virtual Disk
vmkfstools -X 12G ./testing.vmdk
To extend an existing Virtual Disk to 12GB. Instead of G you can use M for Megabytes
With the same command you can shrink the disk (only for ESX Version prior to 3.0) if you choose a smaller tha
the shrinked size is smaller as the partition size in the guest there might be a data losse or a corrupted system resulti
In some cases the shrink command must be issued with the --force option:
vmkfstools -X 4G ./testing.vmdk --force
For shrinking on ESX 3.0x use the VMWare Converter (download from the VMware Website for freee).
destination to the same ESX Host.
If you receive an error one parameter was incrorrect the size might be smaller as the original size!
If you have blanks in the file or directoryname, mask the full path with '
vmkfstools -i
To export or clone a virtual disk from VMFS
vmfsktools -i -d diskformat
Example:
Copy from one vmfs to another:
Source=/vmfs/volumes/esxpublic/testvm2.vmdk
Destination=/vmfs/volumes/production/testvmnew2.vmdk
7/29/2019 vmware commands
10/18
vmkfstools -i /vmfs/volumes/esxpublic/testvm2.vmdk /vmfs/volumes/production/testvmnew2.vmdk
Export to ext3 partition:
Source=/vmfs/volumes/esxpublic/testvm2.vmdk
Destination=/vmimages/testvm2.vmdk
vmkfstools -i /vmfs/esxpublic/testvm2.vmdk -d 2gbsparse /vmimages/testvm2.vmdk
vmkfstools -E
Rename files associated with a specified virtual disk
vmkfstools -U
Delete VirtualdiskDelete files associated with the specified virtual disk.
vmkfstools -c 4000M ./file.vmdk
To create a new empty virtual disk
vmkfstools -c 300G -a lsilogic /vmfs/volume/vmfslabel/directory/newdisk.vmdk
or in current directory
vmkfstools -c 300G -a lsilogic ./newdisk.vmdk
This command is very useful because you can use user-friendly names for the disks
For further options enter man vmkfstools
esxcfg VMware console tool
7/29/2019 vmware commands
11/18
esxcfg is a new management tool from VMware. Be careful, some commands could crash your system!
esxcfg tool Management in the console
esxcfg-rescan
esxcfg-rescan vmhba1
esxcfg-rescan vmhba2
Rescan vmhbas
esxcfg-mpath -l
VMware ESX Server multipathing information
Disk vmhba1:3:6 /dev/sdu(225280MB) has 2 paths and policy of Most Recently Used
FC 2:1.0 210000e08b0246af201400a0b81167e2 vmhba1:3:6 On active preferred
FC 4:1.0 210000e08b02e4a0201500a0b81167e2 vmhba2:3:6 Standby
Multipathing
of HBAS
listing and configure
esxcfg-vmhbadevs -m
See the relationship between vmhba and devnames. This produces an output like so:
vmhba1:3:6:1 /dev/sdu144ebf538-51cc7998-2525-00145e1b556a
vdf
/vmfs/volumes/44ebf538-51cc7998-2525-00145e1b556a230424576 44748800 185675776 19% /vmfs/volumes/CoreDomain
Relationship between
Vmhbas and devname
ls /vmfs/devices/disks/ Not an esxcfg command
7/29/2019 vmware commands
12/18
list all your disks/luns like so:vmhba0:0:0:0
vmhba0:1:0:0vmhba1:2:0:0vmhba1:3:0:0vmhba1:4:0:0vmhba1:5:0:0vmhba1:6:0:0vml.02000000003343453035595041202020203731303638315430535831373334vml.0200000000334345303634504b202020203731303545464853535831373334vml.0200000000334345304150415420202020373131384b51305a535831373334vml.0200000000334345304244584e202020203731313835485231535831373334vml.0200000000334345304446543230303030373132314e4c5a57535431373334vml.02000000005546413350323330375352544d414e333336vml.02000000005546413350323330375442444d414e333336
You can then use fdisk to work out if the disks are blank of partitioned with:
fdisk /vmfs/devices/disks/vmhba1:5:0:0
Identify the LUN Disk and Partition
vmhbax:y:z:v
x=Hostbusadapter (0=mostly internal SCSI Adapter, 1=mostliy fibrechannel 1...x)y=LUNz=Diskv=Partition
esxcfg-firewall
esxcfg-firewall --openPort
esxcfg-firewall --closePort
port: Apllication PortProtocol:tcp or udpDirection: in or outname: Descriptive name of rule
esxcfg-firewall -q to query settings
Example:
esxcfg-firewall --openPort 14247,tcp,out,IBMDirector
You cannot configure unsupported services through the VI Client.
Firewall settings
7/29/2019 vmware commands
13/18
esxcfg-vmhbadevs
vmhba0:0:0 /dev/sda
vmhba0:1:0 /dev/sdb
vmhba0:2:0 /dev/sdc
Map of VMkernel storage devices to service console devices
VMkernel storage devic
devices
esxcfg-vswitch
esxcfg-vswif -i 192.168.1.55 -n 255.255.255.0 vswf0
Creates and updates virtual machine network settings
Change IP Address an
vmware-cmd
A command line tool to perform VM operations. This tool is found in /usr/bin
vmware-cmd s register /home/ali/vmware/newVM/newVM.vmx
vmware-cmd s unregister /
vmware-cmd l
vmware-cmd /home/user/vmware/server/server.vmx stop soft
vmware-cmd /home/user/vmware/server/server.vmx getheartbeat
vmware-cmd /home/user/vmware/server/server.vmx getstate
7/29/2019 vmware commands
14/18
vmware-cmd /home/user/vmware/server/server.vmx getid
vmware-cmd /home/user/vmware/server/server.vmx getpid
VMM: Troubleshooting P2V Conversion Issues.
Possible Symptoms/Causes of P2V Issues
Possible Symptoms/Cause Resolution
P2V conversion fails during the conversion
of a VMware virtual machine to a Hyper-V
or Virtual Server virtual machine.
This issue occurs if you did not remove
VMware Tools from the source VMware
virtual machine before you began the P2V
conversion.
To resolve this issue, uninstall VMware Tools, and then try the P2V conversion
again.
P2V fails during an offline P2V conversion.
You may receive the following error
message:
Error (3133) Virtual Machine Manager
could not connect to source computer
servername.domainname.com after it
restarted into Windows PE (temporary
To resolve this issue if a network driver is missing, follow the steps in KB article
970921:
How to add NIC drivers for offline P2V in VMM 2008
Also, see the followingblog posting from Jonathans Virtual Blog:
http://support.microsoft.com/kb/970921http://support.microsoft.com/kb/970921http://support.microsoft.com/kb/9709217/29/2019 vmware commands
15/18
computer name is computername). Automatic
restart to the original operating system is
scheduled to occur within 15 minutes.
Recommended Action If
servername.domainname.com does notrestart in 15 minutes, manually restart it back
into the original operating system by using
the start menu.
P2V conversion will fail if the correct
network or mass storage drivers for the
source computer are missing from the
Windows Preinstallation Environment
(Windows PE).
Error 3133 occurs if the network adapter
driver for the source computer is missing.
Therefore, VMM cannot contact the source
computer after it reboots into Windows PE.
Drivers Required for Offline P2VHow to Download, Extract and Stage
Important When you download a missing driver (network or storage), ensure
that the driver is for Windows Vista/Windows Server 2008 or later. You must do
this because the version of Windows PE that is used is based on Windows Server
2008.
If the source computer has a network adapter or an internal SCSI controller
(typical in older hardware to attach the boot device) where a Windows Server 2008
driver is not available, you can try the following:
For the network adapter or SCSI controller, install the Windows Server
2003 version of the driver (if available), and then try the offline
conversion again.
In the case of a network driver, you can temporarily install a newer NIC
(with a Windows Server 2008 driver) in the source computer just for the
P2V conversion. You can remove it after P2V conversion completes.
If offline conversion still does not work, you can try the following workarounds:
Upgrade the source computer to Windows Server 2003 with SP2 and
perform an online conversion. (This is not recommended for a domain
controller.)
Build a new virtual machine and migrate applications and services from
the Windows 2000 physical server.
Volume Shadow Copy Service (VSS) fails to
take a snapshot of the contents of the source
computer's drives.
Review the System and Application event logs on the source computer for VSS
errors. If you are unable to resolve the VSS errors on the source computer, perform
an offline P2V, which does not use VSS.
Installation of the VMM agent on the source
computer fails.
View the VMM*.log on the source computer to gather additional information.
On computers with the Windows 2000 Server, Windows XP, or WindowsServer 2003 operating system, the log files are stored in C:\Documents
and Settings\All Users\Application Data\VMMLogs. On computers with the Windows Vista or Windows Server 2008
operating system, the log files are stored in C:\Users\All
Users\VMMLogs.
http://blogs.technet.com/jonjor/archive/2009/01/05/drivers-required-for-offline-p2v-how-to-download-extract-and-stage.aspxhttp://blogs.technet.com/jonjor/archive/2009/01/05/drivers-required-for-offline-p2v-how-to-download-extract-and-stage.aspxhttp://blogs.technet.com/jonjor/archive/2009/01/05/drivers-required-for-offline-p2v-how-to-download-extract-and-stage.aspxhttp://blogs.technet.com/jonjor/archive/2009/01/05/drivers-required-for-offline-p2v-how-to-download-extract-and-stage.aspxhttp://blogs.technet.com/jonjor/archive/2009/01/05/drivers-required-for-offline-p2v-how-to-download-extract-and-stage.aspx7/29/2019 vmware commands
16/18
The source computer for an offline P2V
conversion has less than 512 MB of RAM
available.
Add more RAM to the source computer to equal at least 512 MB.
During a P2V conversion with a Hyper-V
destination host, the conversion completes.
However, you receive a 1322x warning
message that indicates that the installation of
Hyper-V Integration Services fails. For
example:
Unable to install Virtual Guest Services on
virtual machine . The
Hyper-V Integration Services setup exited
with error code 60001.
This issue may occur if the operating system
on the source computer is not supported on
Hyper-V virtual machines.
Ensure that the operating system on the source computer is supported as a guest
operating system on Hyper-V virtual machines.
See the TechNet Library articleP2V: Requirements for Physical Source
Computersfor a list of guest operating systems that are supported on Hyper-V
virtual machines.
To work around this issue, you can try to install virtual guest services manually.
The firewall on the source computer does not
allow an exception for the Remote
Administration service.
Use the Group Policy Editor console (gpedit.msc) to add an exception for the IP
address of the VMM host, for open ports, and for authorized applications.
To open the console, in the Run box, type gpedit.msc. To open the Windows
Firewall settings, in the Group Policy Editor console, expandComputer
Configuration, expand Administrative Templates, expand Network,
expand Network Connections, and then clickWindows Firewall.
The source virtual machine is on a perimeter
network.
VMM cannot perform a P2V conversion if
the source virtual machine is on a perimeter
network. (A perimeter network, which is also
known as a screened subnet, is a collection of
devices and subnets placed between an
intranet and the Internet to help protect the
intranet from unauthorized Internet users.)
Connect the source computer to any other network topology in which the VMM
server can connect to the source machine to temporarily install an agent and can
make Windows Management Instrumentation (WMI) calls to the source computer.
http://go.microsoft.com/fwlink/?LinkID=163803http://go.microsoft.com/fwlink/?LinkID=163803http://go.microsoft.com/fwlink/?LinkID=163803http://go.microsoft.com/fwlink/?LinkID=163803http://go.microsoft.com/fwlink/?LinkID=163803http://go.microsoft.com/fwlink/?LinkID=1638037/29/2019 vmware commands
17/18
Offline P2V conversion is slow.
This issue may occur when the network has
100 Mb full duplex enabled on the switch
end.
See Michael Michaels blog posting for a possible resolution:
How to fix slow offline P2V times in VMM because of duplex switches
The CPU load average high, this calculated over a five minute interval
Either need to increase the number of CPUs or decrease the number of virtual machines that currently running on the VMware
ESX Server.
The percent of CPU utilized per physical CPU on the ESX Server is very high.
Either reduce the number of running VMs or stop processes which might be consuming large amounts of CPU.
The disk read activity is high
If this condition is caused by excessive paging consider adding more physical memory to the system. Otherwise consider movingfrequently accessed application files across multiple physical disks to relieve disk bottlenecks.
Amount of available free memory for the VMware sever is low
Either need to increase the memory or decrease the number of virtual machines.
The Status of the VMware ESX Server is unreachable
Please check if the VmPerl Scripting APIs are correctly configured by issuing the vmware-cmd to the VMware ESX Server.Check if there is network connectivity between the agent and the VMware ESX Server or if the VMware ESX Server has gone offlinefor a known reason.
The vmkernel is not loaded
Please check your system configuration and ensure that the system is healthy.
The virtual machine is powered off
Please determine if the virtual machine was intentionally powered off. To restart the virtual machine use the 'start virtual machine'
action.
The virtual machine is in a stuck state
Check to see if the virtual machine's guest OS is waiting on user input
The virtual machine is in a suspended state
Please determine if the virtual machine was intentionally suspended. You can resume the virtual machine by using the 'start virtualmachine' action
http://blogs.technet.com/m2/archive/2010/03/08/how-to-fix-slow-offline-p2v-times-in-vmm.aspxhttp://blogs.technet.com/m2/archive/2010/03/08/how-to-fix-slow-offline-p2v-times-in-vmm.aspxhttp://portal.emea.ime.reuters.com/sites/Engineering_Transformation/Programmes/Virtualization/VI_Ops/Lists/VI%20Event%20Dictionary/DispForm.aspx?ID=54http://portal.emea.ime.reuters.com/sites/Engineering_Transformation/Programmes/Virtualization/VI_Ops/Lists/VI%20Event%20Dictionary/DispForm.aspx?ID=54http://portal.emea.ime.reuters.com/sites/Engineering_Transformation/Programmes/Virtualization/VI_Ops/Lists/VI%20Event%20Dictionary/DispForm.aspx?ID=55http://portal.emea.ime.reuters.com/sites/Engineering_Transformation/Programmes/Virtualization/VI_Ops/Lists/VI%20Event%20Dictionary/DispForm.aspx?ID=56http://portal.emea.ime.reuters.com/sites/Engineering_Transformation/Programmes/Virtualization/VI_Ops/Lists/VI%20Event%20Dictionary/DispForm.aspx?ID=56http://portal.emea.ime.reuters.com/sites/Engineering_Transformation/Programmes/Virtualization/VI_Ops/Lists/VI%20Event%20Dictionary/DispForm.aspx?ID=60http://portal.emea.ime.reuters.com/sites/Engineering_Transformation/Programmes/Virtualization/VI_Ops/Lists/VI%20Event%20Dictionary/DispForm.aspx?ID=60http://portal.emea.ime.reuters.com/sites/Engineering_Transformation/Programmes/Virtualization/VI_Ops/Lists/VI%20Event%20Dictionary/DispForm.aspx?ID=61http://portal.emea.ime.reuters.com/sites/Engineering_Transformation/Programmes/Virtualization/VI_Ops/Lists/VI%20Event%20Dictionary/DispForm.aspx?ID=61http://portal.emea.ime.reuters.com/sites/Engineering_Transformation/Programmes/Virtualization/VI_Ops/Lists/VI%20Event%20Dictionary/DispForm.aspx?ID=62http://portal.emea.ime.reuters.com/sites/Engineering_Transformation/Programmes/Virtualization/VI_Ops/Lists/VI%20Event%20Dictionary/DispForm.aspx?ID=62http://portal.emea.ime.reuters.com/sites/Engineering_Transformation/Programmes/Virtualization/VI_Ops/Lists/VI%20Event%20Dictionary/DispForm.aspx?ID=63http://portal.emea.ime.reuters.com/sites/Engineering_Transformation/Programmes/Virtualization/VI_Ops/Lists/VI%20Event%20Dictionary/DispForm.aspx?ID=63http://portal.emea.ime.reuters.com/sites/Engineering_Transformation/Programmes/Virtualization/VI_Ops/Lists/VI%20Event%20Dictionary/DispForm.aspx?ID=64http://portal.emea.ime.reuters.com/sites/Engineering_Transformation/Programmes/Virtualization/VI_Ops/Lists/VI%20Event%20Dictionary/DispForm.aspx?ID=64http://portal.emea.ime.reuters.com/sites/Engineering_Transformation/Programmes/Virtualization/VI_Ops/Lists/VI%20Event%20Dictionary/DispForm.aspx?ID=65http://portal.emea.ime.reuters.com/sites/Engineering_Transformation/Programmes/Virtualization/VI_Ops/Lists/VI%20Event%20Dictionary/DispForm.aspx?ID=65http://portal.emea.ime.reuters.com/sites/Engineering_Transformation/Programmes/Virtualization/VI_Ops/Lists/VI%20Event%20Dictionary/DispForm.aspx?ID=64http://portal.emea.ime.reuters.com/sites/Engineering_Transformation/Programmes/Virtualization/VI_Ops/Lists/VI%20Event%20Dictionary/DispForm.aspx?ID=63http://portal.emea.ime.reuters.com/sites/Engineering_Transformation/Programmes/Virtualization/VI_Ops/Lists/VI%20Event%20Dictionary/DispForm.aspx?ID=62http://portal.emea.ime.reuters.com/sites/Engineering_Transformation/Programmes/Virtualization/VI_Ops/Lists/VI%20Event%20Dictionary/DispForm.aspx?ID=61http://portal.emea.ime.reuters.com/sites/Engineering_Transformation/Programmes/Virtualization/VI_Ops/Lists/VI%20Event%20Dictionary/DispForm.aspx?ID=60http://portal.emea.ime.reuters.com/sites/Engineering_Transformation/Programmes/Virtualization/VI_Ops/Lists/VI%20Event%20Dictionary/DispForm.aspx?ID=56http://portal.emea.ime.reuters.com/sites/Engineering_Transformation/Programmes/Virtualization/VI_Ops/Lists/VI%20Event%20Dictionary/DispForm.aspx?ID=55http://portal.emea.ime.reuters.com/sites/Engineering_Transformation/Programmes/Virtualization/VI_Ops/Lists/VI%20Event%20Dictionary/DispForm.aspx?ID=64http://portal.emea.ime.reuters.com/sites/Engineering_Transformation/Programmes/Virtualization/VI_Ops/Lists/VI%20Event%20Dictionary/DispForm.aspx?ID=63http://portal.emea.ime.reuters.com/sites/Engineering_Transformation/Programmes/Virtualization/VI_Ops/Lists/VI%20Event%20Dictionary/DispForm.aspx?ID=62http://portal.emea.ime.reuters.com/sites/Engineering_Transformation/Programmes/Virtualization/VI_Ops/Lists/VI%20Event%20Dictionary/DispForm.aspx?ID=61http://portal.emea.ime.reuters.com/sites/Engineering_Transformation/Programmes/Virtualization/VI_Ops/Lists/VI%20Event%20Dictionary/DispForm.aspx?ID=60http://portal.emea.ime.reuters.com/sites/Engineering_Transformation/Programmes/Virtualization/VI_Ops/Lists/VI%20Event%20Dictionary/DispForm.aspx?ID=56http://portal.emea.ime.reuters.com/sites/Engineering_Transformation/Programmes/Virtualization/VI_Ops/Lists/VI%20Event%20Dictionary/DispForm.aspx?ID=55http://portal.emea.ime.reuters.com/sites/Engineering_Transformation/Programmes/Virtualization/VI_Ops/Lists/VI%20Event%20Dictionary/DispForm.aspx?ID=64http://portal.emea.ime.reuters.com/sites/Engineering_Transformation/Programmes/Virtualization/VI_Ops/Lists/VI%20Event%20Dictionary/DispForm.aspx?ID=63http://portal.emea.ime.reuters.com/sites/Engineering_Transformation/Programmes/Virtualization/VI_Ops/Lists/VI%20Event%20Dictionary/DispForm.aspx?ID=62http://portal.emea.ime.reuters.com/sites/Engineering_Transformation/Programmes/Virtualization/VI_Ops/Lists/VI%20Event%20Dictionary/DispForm.aspx?ID=61http://portal.emea.ime.reuters.com/sites/Engineering_Transformation/Programmes/Virtualization/VI_Ops/Lists/VI%20Event%20Dictionary/DispForm.aspx?ID=60http://portal.emea.ime.reuters.com/sites/Engineering_Transformation/Programmes/Virtualization/VI_Ops/Lists/VI%20Event%20Dictionary/DispForm.aspx?ID=56http://portal.emea.ime.reuters.com/sites/Engineering_Transformation/Programmes/Virtualization/VI_Ops/Lists/VI%20Event%20Dictionary/DispForm.aspx?ID=55http://portal.emea.ime.reuters.com/sites/Engineering_Transformation/Programmes/Virtualization/VI_Ops/Lists/VI%20Event%20Dictionary/DispForm.aspx?ID=64http://portal.emea.ime.reuters.com/sites/Engineering_Transformation/Programmes/Virtualization/VI_Ops/Lists/VI%20Event%20Dictionary/DispForm.aspx?ID=63http://portal.emea.ime.reuters.com/sites/Engineering_Transformation/Programmes/Virtualization/VI_Ops/Lists/VI%20Event%20Dictionary/DispForm.aspx?ID=62http://portal.emea.ime.reuters.com/sites/Engineering_Transformation/Programmes/Virtualization/VI_Ops/Lists/VI%20Event%20Dictionary/DispForm.aspx?ID=61http://portal.emea.ime.reuters.com/sites/Engineering_Transformation/Programmes/Virtualization/VI_Ops/Lists/VI%20Event%20Dictionary/DispForm.aspx?ID=60http://portal.emea.ime.reuters.com/sites/Engineering_Transformation/Programmes/Virtualization/VI_Ops/Lists/VI%20Event%20Dictionary/DispForm.aspx?ID=56http://portal.emea.ime.reuters.com/sites/Engineering_Transformation/Programmes/Virtualization/VI_Ops/Lists/VI%20Event%20Dictionary/DispForm.aspx?ID=55http://portal.emea.ime.reuters.com/sites/Engineering_Transformation/Programmes/Virtualization/VI_Ops/Lists/VI%20Event%20Dictionary/DispForm.aspx?ID=64http://portal.emea.ime.reuters.com/sites/Engineering_Transformation/Programmes/Virtualization/VI_Ops/Lists/VI%20Event%20Dictionary/DispForm.aspx?ID=63http://portal.emea.ime.reuters.com/sites/Engineering_Transformation/Programmes/Virtualization/VI_Ops/Lists/VI%20Event%20Dictionary/DispForm.aspx?ID=62http://portal.emea.ime.reuters.com/sites/Engineering_Transformation/Programmes/Virtualization/VI_Ops/Lists/VI%20Event%20Dictionary/DispForm.aspx?ID=61http://portal.emea.ime.reuters.com/sites/Engineering_Transformation/Programmes/Virtualization/VI_Ops/Lists/VI%20Event%20Dictionary/DispForm.aspx?ID=60http://portal.emea.ime.reuters.com/sites/Engineering_Transformation/Programmes/Virtualization/VI_Ops/Lists/VI%20Event%20Dictionary/DispForm.aspx?ID=56http://portal.emea.ime.reuters.com/sites/Engineering_Transformation/Programmes/Virtualization/VI_Ops/Lists/VI%20Event%20Dictionary/DispForm.aspx?ID=55http://portal.emea.ime.reuters.com/sites/Engineering_Transformation/Programmes/Virtualization/VI_Ops/Lists/VI%20Event%20Dictionary/DispForm.aspx?ID=64http://portal.emea.ime.reuters.com/sites/Engineering_Transformation/Programmes/Virtualization/VI_Ops/Lists/VI%20Event%20Dictionary/DispForm.aspx?ID=63http://portal.emea.ime.reuters.com/sites/Engineering_Transformation/Programmes/Virtualization/VI_Ops/Lists/VI%20Event%20Dictionary/DispForm.aspx?ID=62http://portal.emea.ime.reuters.com/sites/Engineering_Transformation/Programmes/Virtualization/VI_Ops/Lists/VI%20Event%20Dictionary/DispForm.aspx?ID=61http://portal.emea.ime.reuters.com/sites/Engineering_Transformation/Programmes/Virtualization/VI_Ops/Lists/VI%20Event%20Dictionary/DispForm.aspx?ID=60http://portal.emea.ime.reuters.com/sites/Engineering_Transformation/Programmes/Virtualization/VI_Ops/Lists/VI%20Event%20Dictionary/DispForm.aspx?ID=56http://portal.emea.ime.reuters.com/sites/Engineering_Transformation/Programmes/Virtualization/VI_Ops/Lists/VI%20Event%20Dictionary/DispForm.aspx?ID=55http://portal.emea.ime.reuters.com/sites/Engineering_Transformation/Programmes/Virtualization/VI_Ops/Lists/VI%20Event%20Dictionary/DispForm.aspx?ID=64http://portal.emea.ime.reuters.com/sites/Engineering_Transformation/Programmes/Virtualization/VI_Ops/Lists/VI%20Event%20Dictionary/DispForm.aspx?ID=63http://portal.emea.ime.reuters.com/sites/Engineering_Transformation/Programmes/Virtualization/VI_Ops/Lists/VI%20Event%20Dictionary/DispForm.aspx?ID=62http://portal.emea.ime.reuters.com/sites/Engineering_Transformation/Programmes/Virtualization/VI_Ops/Lists/VI%20Event%20Dictionary/DispForm.aspx?ID=61http://portal.emea.ime.reuters.com/sites/Engineering_Transformation/Programmes/Virtualization/VI_Ops/Lists/VI%20Event%20Dictionary/DispForm.aspx?ID=60http://portal.emea.ime.reuters.com/sites/Engineering_Transformation/Programmes/Virtualization/VI_Ops/Lists/VI%20Event%20Dictionary/DispForm.aspx?ID=56http://portal.emea.ime.reuters.com/sites/Engineering_Transformation/Programmes/Virtualization/VI_Ops/Lists/VI%20Event%20Dictionary/DispForm.aspx?ID=55http://portal.emea.ime.reuters.com/sites/Engineering_Transformation/Programmes/Virtualization/VI_Ops/Lists/VI%20Event%20Dictionary/DispForm.aspx?ID=65http://portal.emea.ime.reuters.com/sites/Engineering_Transformation/Programmes/Virtualization/VI_Ops/Lists/VI%20Event%20Dictionary/DispForm.aspx?ID=64http://portal.emea.ime.reuters.com/sites/Engineering_Transformation/Programmes/Virtualization/VI_Ops/Lists/VI%20Event%20Dictionary/DispForm.aspx?ID=63http://portal.emea.ime.reuters.com/sites/Engineering_Transformation/Programmes/Virtualization/VI_Ops/Lists/VI%20Event%20Dictionary/DispForm.aspx?ID=62http://portal.emea.ime.reuters.com/sites/Engineering_Transformation/Programmes/Virtualization/VI_Ops/Lists/VI%20Event%20Dictionary/DispForm.aspx?ID=61http://portal.emea.ime.reuters.com/sites/Engineering_Transformation/Programmes/Virtualization/VI_Ops/Lists/VI%20Event%20Dictionary/DispForm.aspx?ID=60http://portal.emea.ime.reuters.com/sites/Engineering_Transformation/Programmes/Virtualization/VI_Ops/Lists/VI%20Event%20Dictionary/DispForm.aspx?ID=56http://portal.emea.ime.reuters.com/sites/Engineering_Transformation/Programmes/Virtualization/VI_Ops/Lists/VI%20Event%20Dictionary/DispForm.aspx?ID=55http://portal.emea.ime.reuters.com/sites/Engineering_Transformation/Programmes/Virtualization/VI_Ops/Lists/VI%20Event%20Dictionary/DispForm.aspx?ID=54http://blogs.technet.com/m2/archive/2010/03/08/how-to-fix-slow-offline-p2v-times-in-vmm.aspx7/29/2019 vmware commands
18/18