Install vmware tools on CentOS 7 VM

Install the opem-vm-tools:

# yum install open-vm-tools
Loaded plugins: fastestmirror
Loading mirror speeds from cached hostfile
 * base: repos.dfw.quadranet.com
 * epel: mirrors.develooper.com
 * extras: mirror.chpc.utah.edu
 * updates: mirror.chpc.utah.edu
Resolving Dependencies
--> Running transaction check
---> Package open-vm-tools.x86_64 0:10.1.5-3.el7 will be installed
--> Processing Dependency: xmlsec1-openssl for package: open-vm-tools-10.1.5-3.el7.x86_64
--> Processing Dependency: pciutils for package: open-vm-tools-10.1.5-3.el7.x86_64
--> Processing Dependency: net-tools for package: open-vm-tools-10.1.5-3.el7.x86_64
--> Processing Dependency: libfuse.so.2(FUSE_2.6)(64bit) for package: open-vm-tools-10.1.5-3.el7.x86_64
--> Processing Dependency: libfuse.so.2(FUSE_2.5)(64bit) for package: open-vm-tools-10.1.5-3.el7.x86_64
--> Processing Dependency: fuse for package: open-vm-tools-10.1.5-3.el7.x86_64
--> Processing Dependency: libxmlsec1.so.1()(64bit) for package: open-vm-tools-10.1.5-3.el7.x86_64
--> Processing Dependency: libmspack.so.0()(64bit) for package: open-vm-tools-10.1.5-3.el7.x86_64
--> Processing Dependency: libicuuc.so.50()(64bit) for package: open-vm-tools-10.1.5-3.el7.x86_64
--> Processing Dependency: libicui18n.so.50()(64bit) for package: open-vm-tools-10.1.5-3.el7.x86_64
--> Processing Dependency: libicudata.so.50()(64bit) for package: open-vm-tools-10.1.5-3.el7.x86_64
--> Processing Dependency: libfuse.so.2()(64bit) for package: open-vm-tools-10.1.5-3.el7.x86_64
--> Processing Dependency: libdnet.so.1()(64bit) for package: open-vm-tools-10.1.5-3.el7.x86_64
--> Running transaction check
---> Package fuse.x86_64 0:2.9.2-8.el7 will be installed
---> Package fuse-libs.x86_64 0:2.9.2-8.el7 will be installed
---> Package libdnet.x86_64 0:1.12-13.1.el7 will be installed
---> Package libicu.x86_64 0:50.1.2-15.el7 will be installed
---> Package libmspack.x86_64 0:0.5-0.5.alpha.el7 will be installed
---> Package net-tools.x86_64 0:2.0-0.22.20131004git.el7 will be installed
---> Package pciutils.x86_64 0:3.5.1-2.el7 will be installed
---> Package xmlsec1.x86_64 0:1.2.20-7.el7_4 will be installed
---> Package xmlsec1-openssl.x86_64 0:1.2.20-7.el7_4 will be installed
--> Finished Dependency Resolution

Dependencies Resolved

================================================================================================================================================
 Package                             Arch                       Version                                       Repository                   Size
================================================================================================================================================
Installing:
 open-vm-tools                       x86_64                     10.1.5-3.el7                                  base                        663 k
Installing for dependencies:
 fuse                                x86_64                     2.9.2-8.el7                                   base                         85 k
 fuse-libs                           x86_64                     2.9.2-8.el7                                   base                         93 k
 libdnet                             x86_64                     1.12-13.1.el7                                 base                         31 k
 libicu                              x86_64                     50.1.2-15.el7                                 base                        6.9 M
 libmspack                           x86_64                     0.5-0.5.alpha.el7                             base                         64 k
 net-tools                           x86_64                     2.0-0.22.20131004git.el7                      base                        305 k
 pciutils                            x86_64                     3.5.1-2.el7                                   base                         93 k
 xmlsec1                             x86_64                     1.2.20-7.el7_4                                updates                     177 k
 xmlsec1-openssl                     x86_64                     1.2.20-7.el7_4                                updates                      76 k

Transaction Summary
================================================================================================================================================
Install  1 Package (+9 Dependent packages)

Total download size: 8.4 M
Installed size: 29 M

Read moreInstall vmware tools on CentOS 7 VM

Find and Start/Stop VM on ESXI

How to find and Start/Stop VM on ESXI.
SSH to the ESXI server.

# esxcli vm process list
# esxcli vm process list
WebHost
   World ID: 35689
   Process ID: 0
   VMX Cartel ID: 35686
   UUID: 56 4d 72 7c da 4c 82 f1-9f 10 9c e3 d6 7d a4 9d
   Display Name: WebHost
   Config File: /vmfs/volumes/54c1dfef-00e03f4b-784e-6805ca0a3085/WebHost/WebHost.vmx

Windows
   World ID: 4150543
   Process ID: 0
   VMX Cartel ID: 4150542
   UUID: 56 4d 49 5f 12 7e 26 96-d8 31 37 05 21 64 5d 46
   Display Name: Windows
   Config File: /vmfs/volumes/54c1dfef-00e03f4b-784e-6805ca0a3085/Windows/Windows.vmx

Monitor
   World ID: 2487010
   Process ID: 0
   VMX Cartel ID: 2487009
   UUID: 56 4d 99 de b0 13 a1 76-bd 2d 95 8a be 25 35 39
   Display Name: Monitor
   Config File: /vmfs/volumes/54c1dfef-00e03f4b-784e-6805ca0a3085/Monitor/Monitor.vmx

Mail
   World ID: 2487029
   Process ID: 0
   VMX Cartel ID: 2487028
   UUID: 56 4d 4f 88 c8 bf a6 37-b5 5b 96 6f b4 23 c5 fb
   Display Name: Mail
   Config File: /vmfs/volumes/54c1dfef-00e03f4b-784e-6805ca0a3085/Mail/Mail.vmx

Stop a VM:

# esxcli vm process kill -t soft --world-id 4150543

Review to verify the VM is off:

 # esxcli vm process list
WebHost
   World ID: 35689
   Process ID: 0
   VMX Cartel ID: 35686
   UUID: 56 4d 72 7c da 4c 82 f1-9f 10 9c e3 d6 7d a4 9d
   Display Name: WebHost
   Config File: /vmfs/volumes/54c1dfef-00e03f4b-784e-6805ca0a3085/WebHost/WebHost.vmx

Monitor
   World ID: 2487010
   Process ID: 0
   VMX Cartel ID: 2487009
   UUID: 56 4d 99 de b0 13 a1 76-bd 2d 95 8a be 25 35 39
   Display Name: Monitor
   Config File: /vmfs/volumes/54c1dfef-00e03f4b-784e-6805ca0a3085/Monitor/Monitor.vmx

Mail
   World ID: 2487029
   Process ID: 0
   VMX Cartel ID: 2487028
   UUID: 56 4d 4f 88 c8 bf a6 37-b5 5b 96 6f b4 23 c5 fb
   Display Name: Mail
   Config File: /vmfs/volumes/54c1dfef-00e03f4b-784e-6805ca0a3085/Mail/Mail.vmx

How to start a Guest VM from Command line:

Get a list of VMs on a host using the command:


# vim-cmd vmsvc/getallvms 
Vmid    Name                   File                       Guest OS          Version   Annotation
32     Monitor   [datastore1] Monitor/Monitor.vmx   centos64Guest           vmx-08
44     Mail      [datastore1] Mail/Mail.vmx         ubuntu64Guest           vmx-08
58     WebHost   [datastore1] WebHost/WebHost.vmx   centos64Guest           vmx-08
61     Plesk     [datastore1] Plesk/Plesk.vmx       centos64Guest           vmx-08
62     Windows   [datastore1] Windows/Windows.vmx   windows8Server64Guest   vmx-08

NOTE: The important fields will be the the VMID of your desired VM

Double check the power state of the VM:


vim-cmd vmsvc/power.getstate <vmid>

# vim-cmd vmsvc/power.getstate 62
Retrieved runtime info
Powered off

Start


vim-cmd vmsvc/power.on <vmid>
# vim-cmd vmsvc/power.on 62
Powering on VM:

Windows 2012 virtual machines using E1000/E1000e driver experience loss of network connectivity

Source: https://kb.vmware.com/selfservice/microsites/search.do?language=en_US&cmd=displayKC&externalId=2109922

Virtual machine loses network connectivity intermittently
In the Windows Event Viewer (Expand Windows Logs and select System), you see entries similar to:

Intel(R) 82574L Gigabit Network Connection Network link is disconnected

or

Intel(R) 82574L Gigabit Network Connection Network link has been established at 1Gbps full duplex
This issue would occur in these environments:
The virtual machine is Windows2012 or Windows 2012 R2
The virtual machine is using E1000 or E1000E driver

Cause

This issue occurs due to the driver bundled with Microsoft Windows 2012.
Resolution
VMware is investigating this issue with the partners.

Currently, there is no resolution

To work around this issue, use VMXNET3 instead of E1000 or E1000e driver.

CentOS Linux install kernel headers to build vmware and vmon error

You don’t have development package for building kernel modules to match the kernel. It is required to build 3rd party modules such as vmware or graphics card drivers.

There is a package called kernel-devel. This package provides kernel headers and makefiles sufficient to build modules against the kernel package.

Login as the root, and use yum command to install the same:


# yum install kernel-devel

So I rebuilt the modules with these commands

vmware-modconfig –console –build-mod vmmon

vmware-modconfig –console –build-mod vmnet

vmware-modconfig –console –build-mod vmci

Then reloaded the modules


# modprobe vmmon

# modprobe vmnet

# modprobe vmci

Now I get;


[root@gemini ~]# service vmware restart

Stopping VMware services:

   VMware Authentication Daemon                            [  OK  ]

   VM communication interface socket family                [  OK  ]

   Virtual machine communication interface                 [  OK  ]

   Virtual machine monitor                                 [  OK  ]

   Blocking file system                                    [  OK  ]

Starting VMware services:

   Virtual machine monitor                                 [  OK  ]

   Virtual machine communication interface                 [  OK  ]

   VM communication interface socket family                [  OK  ]

   Blocking file system                                    [  OK  ]

   Virtual ethernet                                        [  OK  ]

   VMware Authentication Daemon                            [  OK  ]

   Shared Memory Available                                 [  OK  ]