You are not logged in.
Hi, I always have the VirtualBox menu open on a separate Desktop and when I restart/shutdown it gives me the message Logout canceled by '/usr/lib/virtualbox/VirtualBox'. When I try again the restart/shutdown process proceeds normally. How can I solve this?
Plus, at boot I open apps on specific Activities/Virtual Desktops (via Autostart + special application settings) and the icon-only application launcher in my bottom panel then shows red icons for some of the started apps (not all). For instance not for Spotify, Chrome but for VirtualBox and virt-manager I get these red icons. Then I have to hoover over them once and the red blinking is gone. Same question here, how can I prevent these apps from notifing themselves in the icon-only application launcher? (running on KDE Plasma). Thx, regards, Zach
Offline
Hi, trying to create a systemd unit file that executes "pkill VirtualBox" right before every Shutdown or Reboot. Can't get it to work. Enabled and started the .service file. Checked status. Still not working when restarting/shutting down via Plasma. Any help much appreciated, thx. Zach
Offline
Please tell us first *what* you want to do? I *think* you want to run VirtualBox guests as a service that start and stop automatically with the host (or on user login?). If that's your end-goal, you're probably going about it the wrong way, but let's establish your goals first.
Offline
Hi, i'm already starting and stopping a virtual machine with logon and logoff (systemd unit file + script). Works great. I also start the VirtualBox application (the menu) via an Autostart entry (Plasma). That way I can monitor the status of the VM's (saved, running, powered off, ...). The only (small but still annoying) issue is that when I want to shutdown I have to close the VirtualBox application first (the VM itself is being saved state by the systemd unit file). If I don't close VirtualBox (the menu) manually KDE Plasma messages: Logout canceled by '/usr/lib/virtualbox/VirtualBox' and I then have to press Shutdown again and then the shutdown runs fine. Now I want to create a script/systemd unit file to close the VirtualBox application just before I shutdown/restart. That's why I came up with pkill VirtualBox but can't get it to "magically" do its trick yet. Even better would be to understand why VirtualBox notifies itself at shutdown/restart while other applications don't show this behavior. Regards, Zach
Offline
Again, you're not really clearing stating what it is exactly you want to accomplish. I think you want to have some kind of auto-start/stop based on interactive login but somehow you have the actual VBox GUI open as well? There's no reason to have that running if you auto-start the guests.
FWIW you should take a look at the actual /usr/bin/VBox script (which /usr/bin/VirtualBox is symlinked to). That script itself is a wrapper around several VBox utilities depending on what parameters are passed. As to how or why /usr/lib/VirtualboxVM cancels the logout, that may by design if it detects that not all guests have been safely terminated, but that's just a guess. You will first have to determine what signal Plasma sends to the process upon logout. Maybe you can configure Plasma to have a specific close command for just that process?
But I think the true solution is to not have the VBox GUI itself running if there's no need for it if the guests are launched automatically already.
Offline
Hi, I start them headless and RDP/VNC/... into them with Remmina as needed. Having the GUI always open on a separate Virtual Desktop or Activity for me is handy. For instance as I sometimes need to open a VM in "normal" mode to be able to attach devices, quickly see which VM's are running, saved, ..., etc. Don't want to use the CLI for these actions with vboxmanage. Of course, one solution is to just always manually open and close the virtualbox gui menu. Thx for your thoughts, keep looking into it. Regards, Zach.
Offline
Hi, found out that it is a old issue and still unsolved: https://www.virtualbox.org/ticket/17528 and https://www.reddit.com/r/kde/comments/g … ere_a_fix/. Any progress? Regards, Zach
Offline
Any progress?
That's not how this works. Roll up your sleeves and do *something* - either learn how to code, or contribute in some other fashion (submit a feature request?), or at least be active inside the upstream community. Just tapping your foot and demanding progress reports isn't how community driven projects work.
Offline
Hi twelveeighty, if anything it wasn't my intention to seem lazy. And as you know I've rolled up my sleeves since (at least) the beginning of July to solve this issue. You don't want to know how many solutions directions I already tried out (systemd unit files, scripts, ...). I'll give it a try via VirtualBox forum, maybe there is progress there. In the meanwhile I keep being enthusiastic about KDE Plasma and working on any solution other than manually closing VirtualBox just before Shutdown/Reboot. Thank you for your help. Regards, Zach
Offline