[Pkg-virtualbox-devel] Bug#813072: Remove broken ExecStopPost in vboxweb.service

Gianfranco Costamagna costamagnagianfranco at yahoo.it
Fri Jan 29 11:09:06 UTC 2016


Hi Michael!




>vboxweb.service contains the following:
>ExecStopPost=/usr/bin/rm /run/vboxweb.pid
>
>This is broken in Debian:
>$ type rm
>rm is /bin/rm


lol, true!

>And leads to a failure if you try to stop vboxweb.service:
>
># systemctl status vboxweb.service 
>● vboxweb.service - VirtualBox Web Service
>   Loaded: loaded (/lib/systemd/system/vboxweb.service; enabled; vendor preset: enabled)
>   Active: failed (Result: exit-code) since Fr 2016-01-29 05:28:55 CET; 3s ago
>  Process: 5499 ExecStopPost=/usr/bin/rm /run/vboxweb.pid (code=exited, status=203/EXEC)
>  Process: 829 ExecStart=/usr/bin/vboxwebsrv --pidfile /run/vboxweb.pid --background (code=exited, status=0/SUCCESS)
>Main PID: 902 (code=killed, signal=TERM)
>   CGroup: /system.slice/vboxweb.service

>           └─944 /usr/lib/virtualbox/VBoxSVC --auto-shutdown

thanks a lot for the report

>The fix is rather simple: Simply drop the ExecStopPost line.
>As you can see in the documentation [¹], systemd will automatically
>clean up stale pid files, so there is no need to do that manually.


sure, I just forgot that (I actually wondered about removing that line, but I tried to keep the
service file the same as fedora, to keep things simpler)

>Trivial patch attached.


thanks, it wasn't needed, but appreciated :)

>Btw, it would be great if /etc/init.d/virtualbox would have an
>equivalent systemd service file. Most of the script seems to be about
>loading kernel modules. Maybe that can be dropped completely due to
>kernel auto-loading or could be replaced by a simple
>/usr/lib/modules-load.d/ snippet.


here a service file would be so appreciated, it is a difficult task for
me, even if I already did many of them, but virtualbox is a little bit scary

I could try this one
https://github.com/rpmfusion/VirtualBox/blob/master/vboxservice.service


But I'm wondering about how should I change the rules file to make it work correctly
(because we need to install both, and I'm not sure about the changes)

thanks!

Gianfranco



More information about the Pkg-virtualbox-devel mailing list