In short, can I run an application from within a guest, just by specifying command line parameters to a vmanage from the host?
My clients send me a lot of untrusted applications that's why I use a persistent VM to run those, and that makes a it a lot of clicking within the VM.
Is there a possibility to execute applications inside the VM by running a shell script from the HOST?
Thank you in advance.
Running applications withing a VM from a host command-line
-
- Volunteer
- Posts: 7639
- Joined: 7. Jun 2007, 21:53
Re: Running applications withing a VM from a host command-line
VBoxManage guestcontrol execute Guest Command
For the exact syntax read User Manual.
For the exact syntax read User Manual.
German Howto (Linux): http://www.linuxforen.de/forums/showthread.php?t=236444
User Manual / Download Section: http://www.virtualbox.de/wiki/Downloads
FAQ: http://www.virtualbox.de/wiki/User_FAQ http://forums.virtualbox.org/viewtopic.php?t=8669
User Manual / Download Section: http://www.virtualbox.de/wiki/Downloads
FAQ: http://www.virtualbox.de/wiki/User_FAQ http://forums.virtualbox.org/viewtopic.php?t=8669
-
- Posts: 8
- Joined: 10. Nov 2009, 20:13
- Primary OS: MS Windows XP
- VBox Version: PUEL
- Guest OSses: XP, Linux (Ubuntu), FreeBSD
Re: Running applications withing a VM from a host command-line
thanks a lot
I appreciate it
I appreciate it
-
- Posts: 93
- Joined: 24. Nov 2009, 11:01
- Primary OS: FreeBSD
- VBox Version: OSE other
- Guest OSses: FreeBSD, OpenSolaris, and several Linuxes
Re: Running applications withing a VM from a host command-line
Hello,
On the minus side:
- You don't get any feedback on the command output (unless you redirect it somewhere (for example with output redirection, "tee" or "script" on Unix guests) and use other commands to analyse it)
On the plus side:
- It works without Guest Additions (GA)
- It always work, even when you're installing the OS inside the guest (too early to have GA inside)
- It's not limited to actions on commands (for example, you can send events to GUI apps)
You'll find a small shell library to ease the use of scancodes and a whole example in which an host controls the installation and configuration of an OS in a Guest there:
http://www.projet-hev.org/dist/generateur1.tar.bz2
Best regards,
Hubert
It's also possible to do it with "VBoxManage controlvm <uuid>|<name> keyboardputscancode <hex> [<hex> ...]".stefan.becker wrote:VBoxManage guestcontrol execute Guest Command
On the minus side:
- You don't get any feedback on the command output (unless you redirect it somewhere (for example with output redirection, "tee" or "script" on Unix guests) and use other commands to analyse it)
On the plus side:
- It works without Guest Additions (GA)
- It always work, even when you're installing the OS inside the guest (too early to have GA inside)
- It's not limited to actions on commands (for example, you can send events to GUI apps)
You'll find a small shell library to ease the use of scancodes and a whole example in which an host controls the installation and configuration of an OS in a Guest there:
http://www.projet-hev.org/dist/generateur1.tar.bz2
Best regards,
Hubert
-
- Posts: 8
- Joined: 10. Nov 2009, 20:13
- Primary OS: MS Windows XP
- VBox Version: PUEL
- Guest OSses: XP, Linux (Ubuntu), FreeBSD
Re: Running applications withing a VM from a host command-line
Thank you for the additional info,
that's really works for me,
Thanks
that's really works for me,
Thanks
-
- Posts: 93
- Joined: 24. Nov 2009, 11:01
- Primary OS: FreeBSD
- VBox Version: OSE other
- Guest OSses: FreeBSD, OpenSolaris, and several Linuxes
Re: Running applications withing a VM from a host command-line
Hello,
Here's a little video capture of my generator running in debug mode plus VNC display (both are not needed):
http://www.projet-hev.org/dist/hev1.flv
The OS is installed twice (the first time in a small 1GB swap-less rescue partition, the second time in the main partition) and with very little configuration (because there's a second generator which takes care of that). The disk geometry and the partitions sizes are input parameters...
Best regards,
Hubert
Here's a little video capture of my generator running in debug mode plus VNC display (both are not needed):
http://www.projet-hev.org/dist/hev1.flv
The OS is installed twice (the first time in a small 1GB swap-less rescue partition, the second time in the main partition) and with very little configuration (because there's a second generator which takes care of that). The disk geometry and the partitions sizes are input parameters...
Best regards,
Hubert