VMware Tools power-onscript did not run

Bug #1741207 reported by AdlerHorst
8
This bug affects 1 person
Affects Status Importance Assigned to Milestone
open-vm-tools (Ubuntu)
Incomplete
Undecided
Unassigned

Bug Description

On every VM-start the attached Pop-up appears.
If I'm not fast enough to click OK Ubuntu does not start. If I'm fast enough Ubuntu start without problem and everything works except shared directory.

Host: Windows 8.1
Guest: Ubuntu 17.10

VMWare version: 14.1.0 build-7370693

Revision history for this message
AdlerHorst (adlerhorst) wrote :
Revision history for this message
Christian Ehrhardt  (paelzer) wrote :

Hi Adler,
I lack an env to repro but looking through search engines I think you want to check what the guest has in:

$ find /etc/vmware-tools/scripts

Check if the files there have the exec bit set (and add it if not) - I found reports of those being lost triggering the issue.

You likely have only:
 /etc/vmware-tools/scripts/vmware/network

You can test how it reacts to events by:
$ bash -x /etc/vmware-tools/scripts/vmware/network poweron-vm; echo $?
$ bash -x /etc/vmware-tools/scripts/vmware/network suspend-vm; echo $?
$ bash -x /etc/vmware-tools/scripts/vmware/network resume-vm; echo $?

If in your case the first (or others) fail we'd need to debug why.

Potentially related issues
https://github.com/vmware/open-vm-tools/issues/43
https://github.com/vmware/open-vm-tools/issues/174

Changed in open-vm-tools (Ubuntu):
status: New → Incomplete
Revision history for this message
AdlerHorst (adlerhorst) wrote :
Download full text (3.3 KiB)

excec bit is set.

---------------
bash -x /etc/vmware-tools/scripts/vmware/network poweron-vm; echo $?
------
++ date
+ echo Fre Jan 5 14:37:15 CET 2018 ': Executing '\''/etc/vmware-tools/scripts/vmware/network'\'''
Fre Jan 5 14:37:15 CET 2018 : Executing '/etc/vmware-tools/scripts/vmware/network'
+ echo

++ dirname /etc/vmware-tools/scripts/vmware/network
+ . /etc/vmware-tools/scripts/vmware/../../statechange.subr
/etc/vmware-tools/scripts/vmware/network: Zeile 33: /etc/vmware-tools/scripts/vmware/../../statechange.subr: Datei oder Verzeichnis nicht gefunden
+ main poweron-vm
+ exitCode=0
+ activeList=/var/run/vmware-active-nics
+ case "$1" in
+ rm -f /var/run/vmware-active-nics
+ return 0
0
---------------
bash -x /etc/vmware-tools/scripts/vmware/network suspend-vm; echo $?
------
++ date
+ echo Fre Jan 5 14:39:32 CET 2018 ': Executing '\''/etc/vmware-tools/scripts/vmware/network'\'''
Fre Jan 5 14:39:32 CET 2018 : Executing '/etc/vmware-tools/scripts/vmware/network'
+ echo

++ dirname /etc/vmware-tools/scripts/vmware/network
+ . /etc/vmware-tools/scripts/vmware/../../statechange.subr
/etc/vmware-tools/scripts/vmware/network: Zeile 33: /etc/vmware-tools/scripts/vmware/../../statechange.subr: Datei oder Verzeichnis nicht gefunden
+ main suspend-vm
+ exitCode=0
+ activeList=/var/run/vmware-active-nics
+ case "$1" in
+ TranquilizeNetworkManager
++ which dbus-send
+ dbusSend=/usr/bin/dbus-send
+ rc=0
+ '[' 0 -ne 0 ']'
++ /usr/bin/dbus-send --system --print-reply --dest=org.freedesktop.NetworkManager /org/freedesktop/NetworkManager org.freedesktop.DBus.Properties.Get string:org.freedesktop.NetworkManager string:State
++ awk '/variant/ {print $3;}'
+ nm_state=70
+ '[' -z 70 ']'
+ case $nm_state in
+ /usr/bin/dbus-send --system --print-reply --dest=org.freedesktop.NetworkManager /org/freedesktop/NetworkManager org.freedesktop.NetworkManager.Enable boolean:false
method return time=1515159572.911180 sender=:1.10 -> destination=:1.79 serial=376 reply_serial=2
+ rc=0
+ '[' 0 -eq 0 ']'
+ return 0
+ exitCode=0
+ '[' 0 '!=' 0 ']'
+ return 0
0
---------------
bash -x /etc/vmware-tools/scripts/vmware/network suspend-vm; echo $?
------
++ date
+ echo Fre Jan 5 14:40:44 CET 2018 ': Executing '\''/etc/vmware-tools/scripts/vmware/network'\'''
Fre Jan 5 14:40:44 CET 2018 : Executing '/etc/vmware-tools/scripts/vmware/network'
+ echo

++ dirname /etc/vmware-tools/scripts/vmware/network
+ . /etc/vmware-tools/scripts/vmware/../../statechange.subr
/etc/vmware-tools/scripts/vmware/network: Zeile 33: /etc/vmware-tools/scripts/vmware/../../statechange.subr: Datei oder Verzeichnis nicht gefunden
+ main resume-vm
+ exitCode=0
+ activeList=/var/run/vmware-active-nics
+ case "$1" in
+ WakeNetworkManager
++ which dbus-send
+ dbusSend=/usr/bin/dbus-send
+ rc=0
+ '[' 0 = 0 ']'
+ /usr/bin/dbus-send --system --print-reply --dest=org.freedesktop.NetworkManager /org/freedesktop/NetworkManager org.freedesktop.NetworkManager.Enable boolean:true
method return time=1515159644.893170 sender=:1.10 -> destination=:1.84 serial=473 reply_serial=2
+ rc=0
+ '[' 0 = 0 ']'
+ return 0
+ exitCode=0
+ '[' 0 '!=' 0 ']'
+ return 0
0
---------------

Interesting I got this error only on System boot...

Read more...

description: updated
Revision history for this message
Christian Ehrhardt  (paelzer) wrote :

Odd, even the poweron-vm that fails on boot works in this retest.

If there is only /etc/vmware-tools/scripts/vmware/network and no others as it usually is we might then need to find what happens on boot to fail there.

I wonder if you could try to modify /etc/vmware-tools/scripts/vmware/network to
a) be verbose (like the set -x)
b) generally log all to a file that you can later examine. Something like [1] maybe?

[1]: https://stackoverflow.com/a/22373735/6361589

Revision history for this message
AdlerHorst (adlerhorst) wrote :

I added

LOG_FILE=/tmp/both.log
exec > >(tee -a ${LOG_FILE} )
exec 2> >(tee -a ${LOG_FILE} >&2)

in the head of /etc/vmware-tools/scripts/vmware/network
but I do not get any log.

Revision history for this message
Christian Ehrhardt  (paelzer) wrote :

maybe tmp is cleaned afterwards?
I didn't check yet when vmware is calling these.

since this is only sh (dash in this case I'd think) it didn't like all the syntax.
The following worked for me in a quick test:

set -x
LOG_FILE=/var/log/vmware-nethook-both.log
exec >>${LOG_FILE}
exec 2>>${LOG_FILE}

Revision history for this message
AdlerHorst (adlerhorst) wrote :

I tried a bit with this script but I never got any Data into the Log File.

Now I did a Ubuntu Reinstallation. Now every thing worked and Ubuntu is Booting way faster.

Maybe out of topic:
If I boot into VMWARE Bios there is a "Large Disk Access Mode" This is set to DOS. Some Article in Internet says that it should be set to OTHER. What is correct?

Revision history for this message
Christian Ehrhardt  (paelzer) wrote :

Glad that you have no issue anymore, even thou we don't really know what the reason was :-/

I have to beg your pardon, but I have no extra experience with large disk access mdoe other than seeing a few forum/blog entries referring to it - there were no related bugs nor a lot of official documentation on it that I'd know about.

To post a comment you must log in.
This report contains Public information  
Everyone can see this information.

Other bug subscribers

Remote bug watches

Bug watches keep track of this bug in other bug trackers.