VirtualBox

Ignore:
Timestamp:
Feb 3, 2023 7:20:53 PM (23 months ago)
Author:
vboxsync
Message:

Additions: X11: Add possibility restart VBoxClient processes during Guest Additions update, bugref:10359.

This commit makes VBoxClient processes to temporary release reference to vboxguest kernel module and then
restart itself. So module can be reloaded and newly started VBoxClient instance will utilize updated module.

When VBoxClient starts in demonized mode, it forks a child process which represents actual service. Parent
process continues to run and its main function is to restart child when it crashes or terminates with exit
status != 0. This commit makes child process to catch SIGUSR1 and terminate with exit
status VBGLR3EXITCODERELOAD (currently equal to 2). Parent process will detect this and in turn will release
its reference to vboxguest kernel module, allowing to reload it. The parent process will then wait for SIGUSR1
itself. Once received, it will restart itself (loading new, updated VBoxClient process image). This is a part
of the procedure to install and reload/restart Guest Additions kernel modules and user services without
requiring guest reboot.

File:
1 edited

Legend:

Unmodified
Added
Removed
  • trunk/src/VBox/Additions/x11/VBoxClient/seamless.cpp

    r98103 r98474  
    349349    "seamless",                 /* szName */
    350350    "Seamless Mode Support",    /* pszDescription */
    351     ".vboxclient-seamless.pid", /* pszPidFilePath */
     351    ".vboxclient-seamless",     /* pszPidFilePathTemplate */
    352352    NULL,                       /* pszUsage */
    353353    NULL,                       /* pszOptions */
Note: See TracChangeset for help on using the changeset viewer.

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