VirtualBox

Ignore:
Timestamp:
Jan 28, 2025 2:18:42 PM (3 months ago)
Author:
vboxsync
svn:sync-xref-src-repo-rev:
167214
Message:

Installer: Linux: Ask VBoxSVC to terminate gacefully and wait for it if it is running during installation, bugref:10850.

This behavior was in place before, however we did not send SIGUSR1 to VBoxSVC
in case of .run installer (or did it in condition which was never true) and we
were waiting too litle to give it a chance to terminate.

File:
1 edited

Legend:

Unmodified
Added
Removed
  • trunk/src/VBox/Installer/linux/debian/preinst

    r106061 r107964  
    6565  VBOXSVC_PID=`pidof VBoxSVC 2>/dev/null || true`
    6666  if [ -n "$VBOXSVC_PID" ]; then
    67     # ask the daemon to terminate immediately
     67    # Ask VBoxSVC to terminate gracefully if it is not
     68    # busy with handling client requests.
    6869    kill -USR1 $VBOXSVC_PID
    69     sleep 1
     70    # Wait for VBoxSVC to terminate.
     71    for attempt in 1 2 3 4 5 6 7 8 9 10; do
     72      [ -n "$(pidof VBoxSVC 2> /dev/null)" ] && sleep 1
     73    done
     74    # Still running?
    7075    if pidof VBoxSVC > /dev/null 2>&1; then
    7176      db_fset virtualbox/old-running seen false || true
Note: See TracChangeset for help on using the changeset viewer.

© 2025 Oracle Support Privacy / Do Not Sell My Info Terms of Use Trademark Policy Automated Access Etiquette