markba
September 29th, 2008, 10:22 AM
I would like to present my latest Open Source project: VBoxTool
It provides easy control of virtual machines of VirtualBox on a Linux headless server, published as free and open source software.
Currently VirtualBox lacks a decent management environment for controlling virtual sessions on a headless server environment. VBoxTool mimics partly Virtual Machine Manager which controls sessions for other virtualization solutions like Qemu, KVM, etc. Unfortunately, VirtualBox is not in the list of supported engines (nor will be in the near future).
Features
Heart of the framework is a script which can do several actions (start, save, backup, etc.) on all registered VirtualBox sessions in batch mode. It is a wrapper around VBoxManage (the commandline interface of VirtualBox), so execution is also by command line.
Show info of all registered sessions. Name, status (running, saved, etc.) and other info like the configured VRDP port are shown with the command 'vbox show'. When a session is running, also CPU load and memory usage are shown. As an alternative, 'vbox showrun' shows info only of running sessions.
Mass operation: save, start, stop. Save all running sessions with one command: 'vbox save'. Start all saved sessions with 'vbox start'. Stop all running sessions with 'vbox stop'.
Mass backup. Backup all sessions using rsync with one command: 'vbox backup'. When a session is running, it is saved and restarted after the backup. The next level of backup, could mean that online backup (thus without bringing the session offline) is possible*.
Batch start. Controlled start of several sessions, defined in a configuration file, /etc/vboxtool/machines.conf. Only sessions named in that file will be started by 'vboxtool autostart'.
Mass configuration of VRDP port and port forwarding. Configure VRDP port and port forwarding for all sessions, all at once in one command: 'vboxtool autostart'. Configuration takes place in /etc/vboxtool/machines.conf. When using port forwarding, there's no need for host interfacing anymore (in Linux, a tedious, complex task).
Autostart at host boot. When the host boots, all sessions registered in /etc/vboxtool/machines.conf will be started in the background, issuing a 'vboxtool autostart' command under the named vbox_user in /etc/vboxtool/vboxtool.conf.
Autosave at host halt. When the host has a controlled down, i.e. halted, all running sessions are automatically saved.
*System monitoring. Monitor server status, session cpu load and memory in a graphical image. This will be done by developing and implementing a Munin plugin. Munin is a system monitoring platform with a plugin structure.
*Webserver. Next to develop is a webserver which points to the automation script. With this you can activate all functions from the script, all by a web page, so without requiring shell access.
* Not (yet) implemented.
** Partly implemented.
Command: vbox autostart
Through autostart, sessions can be started in a controlled way: only the sessions in the configuration file will be started. As a bonus, the VRDP port and portforwarding pairs (also configurable) can be set at startup time. Option autostart depends on a configuration file, /etc/vbox/machines.conf. Each line in this file is a separate machine.
Structure of each line: <session-name>,<vrdp-port>,<hostport-guestport>|<...>.
The given VRDP port is set statically to the session, prior to starting; state is discarded when session is in savestate. You can issue as many portwarding pairs as you like.
Example for /etc/vbox/machines.conf:
Ubuntu Desktop,3391,2022-22
Ubuntu JeOS,3392,2022-22|80-80
Resources
VBoxTool website (http://vboxtool.sourceforge.net/)
Sourceforge project (http://sourceforge.net/projects/vboxtool)
Download (http://sourceforge.net/project/showfiles.php?group_id=239993)
I'm looking forward for any feedback from anyone who thinks this software is usefull.
It provides easy control of virtual machines of VirtualBox on a Linux headless server, published as free and open source software.
Currently VirtualBox lacks a decent management environment for controlling virtual sessions on a headless server environment. VBoxTool mimics partly Virtual Machine Manager which controls sessions for other virtualization solutions like Qemu, KVM, etc. Unfortunately, VirtualBox is not in the list of supported engines (nor will be in the near future).
Features
Heart of the framework is a script which can do several actions (start, save, backup, etc.) on all registered VirtualBox sessions in batch mode. It is a wrapper around VBoxManage (the commandline interface of VirtualBox), so execution is also by command line.
Show info of all registered sessions. Name, status (running, saved, etc.) and other info like the configured VRDP port are shown with the command 'vbox show'. When a session is running, also CPU load and memory usage are shown. As an alternative, 'vbox showrun' shows info only of running sessions.
Mass operation: save, start, stop. Save all running sessions with one command: 'vbox save'. Start all saved sessions with 'vbox start'. Stop all running sessions with 'vbox stop'.
Mass backup. Backup all sessions using rsync with one command: 'vbox backup'. When a session is running, it is saved and restarted after the backup. The next level of backup, could mean that online backup (thus without bringing the session offline) is possible*.
Batch start. Controlled start of several sessions, defined in a configuration file, /etc/vboxtool/machines.conf. Only sessions named in that file will be started by 'vboxtool autostart'.
Mass configuration of VRDP port and port forwarding. Configure VRDP port and port forwarding for all sessions, all at once in one command: 'vboxtool autostart'. Configuration takes place in /etc/vboxtool/machines.conf. When using port forwarding, there's no need for host interfacing anymore (in Linux, a tedious, complex task).
Autostart at host boot. When the host boots, all sessions registered in /etc/vboxtool/machines.conf will be started in the background, issuing a 'vboxtool autostart' command under the named vbox_user in /etc/vboxtool/vboxtool.conf.
Autosave at host halt. When the host has a controlled down, i.e. halted, all running sessions are automatically saved.
*System monitoring. Monitor server status, session cpu load and memory in a graphical image. This will be done by developing and implementing a Munin plugin. Munin is a system monitoring platform with a plugin structure.
*Webserver. Next to develop is a webserver which points to the automation script. With this you can activate all functions from the script, all by a web page, so without requiring shell access.
* Not (yet) implemented.
** Partly implemented.
Command: vbox autostart
Through autostart, sessions can be started in a controlled way: only the sessions in the configuration file will be started. As a bonus, the VRDP port and portforwarding pairs (also configurable) can be set at startup time. Option autostart depends on a configuration file, /etc/vbox/machines.conf. Each line in this file is a separate machine.
Structure of each line: <session-name>,<vrdp-port>,<hostport-guestport>|<...>.
The given VRDP port is set statically to the session, prior to starting; state is discarded when session is in savestate. You can issue as many portwarding pairs as you like.
Example for /etc/vbox/machines.conf:
Ubuntu Desktop,3391,2022-22
Ubuntu JeOS,3392,2022-22|80-80
Resources
VBoxTool website (http://vboxtool.sourceforge.net/)
Sourceforge project (http://sourceforge.net/projects/vboxtool)
Download (http://sourceforge.net/project/showfiles.php?group_id=239993)
I'm looking forward for any feedback from anyone who thinks this software is usefull.