Is it possible to remotely startup a VM?
Here's my situation:
I have one Windows VB host with several Windows VM's on it for each user/client.
When a client/user has shutdown it's VM remotely, how can he start his VM again. It is not possible for the user to login to te host (the user is not an network administrator, only a simple VM user)
I already googled a couple of hours without any result.
Start a VM across the network/remotely
-
scottgus1
- Site Moderator
- Posts: 20945
- Joined: 30. Dec 2009, 20:14
- Primary OS: MS Windows 10
- VBox Version: VirtualBox+Oracle ExtPack
- Guest OSses: Windows, Linux
Re: Start a VM across the network/remotely
You can start a VM using a script (Windows is your host OS? then they're called batch files: notepad documents with a .cmd extension). See VBoxManage in the Virtualbox help files for the command (and you'll need to use the whole disk & path to VBoxManage.exe in a Windows environment, such as "C:\Program FIles\Oracle\VBoxManage.exe" with quotes in the batch file).
That will enable starting VMs with a script, but your users will need to get onto the host somehow to start the script that starts the VM. Microsoft Sysinternals' PsExec might be useful if you can let the users have enough permissions. Or a VBS script running in the background, which monitors a folder for specially-crafted text files from your users that will start the desired VM, and a client script that generates the text file. Then you'd just need to let the users save text files on a shared folder on the host (FTP site, Dropbox, etc.)
If your VMs are the professional version of Windows, you can use Group Policy Editor to remove the ability to shut down the VM, maybe only allow reboots?
That will enable starting VMs with a script, but your users will need to get onto the host somehow to start the script that starts the VM. Microsoft Sysinternals' PsExec might be useful if you can let the users have enough permissions. Or a VBS script running in the background, which monitors a folder for specially-crafted text files from your users that will start the desired VM, and a client script that generates the text file. Then you'd just need to let the users save text files on a shared folder on the host (FTP site, Dropbox, etc.)
If your VMs are the professional version of Windows, you can use Group Policy Editor to remove the ability to shut down the VM, maybe only allow reboots?
-
noteirak
- Site Moderator
- Posts: 5231
- Joined: 13. Jan 2012, 11:14
- Primary OS: Debian other
- VBox Version: OSE Debian
- Guest OSses: Debian, Win 2k8, Win 7
- Contact:
Re: Start a VM across the network/remotely
Virtualbox doesn't require Administrator priviledges to run a VM, so they should be able to do it themselves.
Unless you've put in place restrictions? If yes, which ones?
Unless you've put in place restrictions? If yes, which ones?
Hyperbox - Virtual Infrastructure Manager - https://apps.kamax.lu/hyperbox/
Manage your VirtualBox infrastructure the free way!
Manage your VirtualBox infrastructure the free way!
Re: Start a VM across the network/remotely
Is the host on a local LAN or at a remote site? If it's on the local LAN you can setup a remote access app like VNC, use it to access the remote server and turn them back on. If it's at a remote site and not accessible across the LAN/WAN do you have remote access to the remote network? A VPN, if so then the previous solution will work, although perhaps rather slowly.
Why not allow a user to log onto the host? Setup a separate limited privilege account and setup batch files to start the VMs? Setup shortcuts to these batch files and place them on this users desktop.
I had a similar situation, although it wasn't a VM host. I gave the users access to a very clamped down user. I also wanted to make sure they logged off when finished. I used a small util named screen launcher (Google it), and set it up to run a batch file that logged the user off (Google it too, it's a simple command) when the screensaver ran, that way after someone walked away it would log off the user. I set it to run after 5 minutes.
Why not allow a user to log onto the host? Setup a separate limited privilege account and setup batch files to start the VMs? Setup shortcuts to these batch files and place them on this users desktop.
I had a similar situation, although it wasn't a VM host. I gave the users access to a very clamped down user. I also wanted to make sure they logged off when finished. I used a small util named screen launcher (Google it), and set it up to run a batch file that logged the user off (Google it too, it's a simple command) when the screensaver ran, that way after someone walked away it would log off the user. I set it to run after 5 minutes.
-
jorgensen
- Posts: 589
- Joined: 20. Oct 2009, 01:22
- Primary OS: MS Windows 10
- VBox Version: VirtualBox+Oracle ExtPack
- Guest OSses: Windows
Re: Start a VM across the network/remotely
If the guests are Windows, why not disable the normal Shutdown and replace it with a LogOff.
In Group Policy go to User Configuration:Administrative Templates:Start Menu and Taskbar where you will find these settings.
In Group Policy go to User Configuration:Administrative Templates:Start Menu and Taskbar where you will find these settings.