VMware Tools init script is missing from the /etc/init.d directory on Linux virtual machines
search cancel

VMware Tools init script is missing from the /etc/init.d directory on Linux virtual machines

book

Article ID: 316551

calendar_today

Updated On:

Products

VMware vSphere ESXi

Issue/Introduction

Symptoms:
After VMware Tools is installed on virtual machines running recent Linux distributions, such as RedHat Enterprise Linux 6 and Ubuntu 6.1 & higher version, you may experience these symptoms:
  • VMware Tools installed on some Linux virtual machines does not have an init script in the /etc/init.d directory.
  • VMware Tools cannot stop or restart.


Environment

VMware vSphere ESXi 6.5
VMware vSphere ESXi 6.7
VMware vSphere ESXi 7.0.0
VMware vSphere ESXi 6.0

Cause

This issue occurs because the /sbin/init program (init) from the sysvinit package has been replaced with Upstart in recent Linux distributions. For more information on Upstart, see the RedHat Customer Portal.

Resolution

  • The init script may be found in one of two locations, depending on how VMware Tools was installed and configured on your system.​
  • In one case, the /etc/init directory contains the configuration files. The vmware-tools script is in the /etc/init/vmware-tools.conf file. The command overview is in init(8) and the syntax is described in init(5).​
  • In the other case, the vmware-tools script is in /etc/init/vmware-tools-services.sh, which calls the script /etc/vmware-tools/init/vmware-tools-services​.
 
To work around this issue, you can manually start, stop, or restart VMware Tools with the commands:
  • /etc/vmware-tools/services.sh start
  • /etc/vmware-tools/services.sh stop
  • /etc/vmware-tools/services.sh restart
Open VMware Tools
  • /etc/init.d/open-vm-tools status
  • /etc/init.d/open-vm-tools stop
  • /etc/init.d/open-vm-tools restart
  • /etc/init.d/open-vm-tools start

Note: You can also run the commands from the vmware-tools.conf file if it is present on your system.​

To verify the status of VMware Tools, use the command:

status vmware-tools

Or 

Add to /etc/rc.d/rc.local the follow line
/etc/vmware-tools/services.sh start
And Vmware-tools start at boot time


Under RHEL6 at least, vmware-tools is not supposed to use an init.d script to start, it should use Upstart initctl to start.

We found the issue to be vmware tools configured to run using the kernel modules instead of vmware provide modules. Running the below command to reconfigure will clobber the kernel module and use the vmware provided modules. That fixed the issue with vmtoolsd not starting automatically.

# configure to use vmware provided modules
vmware-config-tools.pl -d -p --clobber-kernel-modules='vmci,vsock,vmmemctl,vmxnet3,pcnet32,pvscsi'


Additional Information

VMware Tools の init スクリプトが Linux 仮想マシンの /etc/init.d ディレクトリで見つからない
Linux 虚拟机上的 /etc/init.d 目录中缺失 VMware Tools init 脚本