Rom Walton
f7df3c380a
VBOX: Only add the guest additions ISO to the VM if the file has actually been detected on the file system.
...
Some Linux systems separate the VirtualBox packages so that the guest additions ISO is in a separate package. We were attempting to add a DVD device for a file that did not exist.
2015-04-02 16:55:57 -04:00
Rom Walton
fc621bf1c8
VBOX: Clean-up Vbox 4.2/4.3/5.0 support.
2015-04-01 15:29:18 -04:00
Rom Walton
228e82a4b7
VBOX: Add COM support for VirtualBox 5.0 Beta 1.
2015-04-01 14:53:43 -04:00
Rom Walton
3a399ea0f5
VBOX: If polling for the current VM state fails for any reason, like vboxsvc crashing, do a temp exit for 24 hours.
...
Before COM, polling for the current state wasn't as critical. If the poll operation failed, we would try again in one second anyway.
After COM, it is used as a test to see if the communication channel between the wrapper and VirtualBox is still operational. If not, temp exit and hope things work the next attempt.
2015-03-27 16:34:09 -04:00
Rom Walton
70def08644
VBOX: Add additional check for a valid pointer to prevent crash condition.
2015-03-26 17:32:52 -04:00
Rom Walton
46648d0d38
VBOX: Add better error checks when handling COM error conditions.
2015-03-26 17:22:17 -04:00
Rom Walton
07752ba4dd
VBOX: Remove unneeded error string
2015-03-26 08:55:32 -04:00
Rom Walton
a8a9f23ae9
VBOX: Add option to use 'savestate' instead of 'poweroff' during graceful VM shutdown.
2015-03-25 16:54:22 -04:00
Rom Walton
04285a19df
VBOX: Add a configuration option to turn-off automatic check-pointing.
...
Projects may want to handle check-pointing within their own application and skip the disk intensive requirements of a VM snapshot.
2015-03-25 16:09:07 -04:00
Rom Walton
16ae8d57c9
VBOX: Enable/Disable network after the network type has been specified.
2015-03-22 15:19:08 -04:00
Rom Walton
32fe92acd0
VBOX: When attempting to deregister the VM, if we are unable to acquire the session lock, exit the routine with an error. Avoid a crash.
2015-03-20 10:08:06 -04:00
Rom Walton
1901b2bc7e
VBOX: Same with the temporary exit trigger file
2015-03-20 09:58:37 -04:00
Rom Walton
f0293098d3
VBOX: Take care of a false positive. The completion file string size must be greater than zero.
2015-03-20 09:56:08 -04:00
Rom Walton
8b997f0cfe
VBOX: If we experience a timeout when attempting to start the VM, dump the log files.
2015-03-20 09:49:42 -04:00
Christian Beer
833c877f3a
BUILD: add example apps into the build process
...
- By default apps won't be built. In order to build the example apps use --enable-apps as option to ./configure. Not all apps are supported as some need further external libraries.
- Also fix a copy/paste error in the vboxmonitor Makefile
2015-02-12 16:58:14 +01:00
Rom Walton
1e5dc8b61b
HTMLGFX: Completed the move of all platform independent code to source files that will be shared between platforms.
...
All that should be required for new platforms is to implement a 'run' function that creates a window that hosts an HTML control and queries determine_state_url() and determine_exit_state() once a second.
2015-01-17 17:05:09 -05:00
Rom Walton
96c0317f90
Merge branch 'master' of ssh://isaac.ssl.berkeley.edu/boinc-v2
2015-01-16 00:49:41 -05:00
Rom Walton
8bdf177e4e
HTMLGFX: Checkpoint (Continuation of previous commit.)
...
* Custom IE Javascript interface is gone, it was replaced with a cross-browser Web RPC.
In the HTML doc you can add:
<script type='text/javascript' src='/api/static/boinc.js'></script>
In the JavaScript code you can:
var boinc = new BOINC();
From there you can get the username like:
var userName = boinc.getUserName();
* Default resources are embedded within the executable in much the same way XPM images are embedded in the manager.
/api/static/index.html
/api/static/boinc.png
/api/static/boinc.js
2015-01-16 00:49:17 -05:00
Charlie Fenton
8cac4bd2b5
VBOX: Update Xcode project for building vboxwrapper on Mac OS X
2015-01-15 15:51:00 -08:00
Rom Walton
e31d3c86b4
VBOX: Add missing header
2015-01-15 18:16:59 -05:00
Rom Walton
9dc2161436
VBOX: Configure a bunch of virtual functions to be purely abstract to avoid a bunch of compiler warnings in gcc
2015-01-15 18:14:35 -05:00
Rom Walton
9784669271
VBOX: Fix makefiles for building vboxwrapper on Linux and Mac OS X
2015-01-15 17:19:45 -05:00
Rom Walton
725982c7eb
VBOX: Add missing header on *nix based builds
2015-01-15 16:31:01 -05:00
Julien Nabet
d75222ebf3
cppcheck: Prefer prefix ++/-- operators for non-primitive types
2015-01-14 21:18:29 +01:00
Rom Walton
82dbec6671
HTMLGFX: Checkpoint (Move most of the platform specific stuff to the HTTP server side of the house, it becomes cross-browser/cross-platform)
2015-01-12 15:47:34 -05:00
Rom Walton
38af455fa7
HTMLGFX: Remove the secret handling stuff, it would prevent loading static images and other resources from the slot directory.
2015-01-06 11:03:41 -05:00
Rom Walton
8168008631
WRAPPER: Make creating/writing the graphics status file part of the job file configuration. No need to write it if there is not going to be a running graphics application.
2015-01-05 22:53:50 -05:00
Rom Walton
106ef1e837
VBOX: Make creating/writing the graphics status file part of the job file configuration. No need to write it if there is not going to be a running graphics application.
2015-01-05 22:45:37 -05:00
Rom Walton
f082889e85
WINBUILD: Fix build breaks introduced with graphics status function changes.
2015-01-05 20:37:51 -05:00
Rom Walton
46f8b9232e
HTMLGFX: When debugging, ignore the last update time in the graphics status file.
...
If the worker application hasn't been running for awhile we do not want to automatically close the graphics application.
2015-01-02 00:52:22 -05:00
Rom Walton
d28247589e
VBOX: Always report the web graphics port to the client except when a 'graphics_app' is defined
2014-12-31 10:53:17 -05:00
Rom Walton
91bb400ce1
VBOX: Bug fix for persisting remote desktop/web api port information
2014-12-31 03:11:21 -05:00
Rom Walton
ed431ced86
HTMLGFX: Implement a simple authentication scheme.
...
Using the formal HTTP authentication scheme was too cumbersome and I couldn't pre-fill out that information as part of the request. IE11 emulation ignores any credentials as part of the URI. The web browser control insists on displaying a credentials dialog when challenged.
So for now, look for a 'secret' header which just contains a thread identifier.
Authentication is skipped if the app was started with the --debug command line argument. You'll be able to attach and debug your HTML application via the port number written in the Window title.
2014-12-30 23:20:48 -05:00
Rom Walton
2f3a8cb3ec
HTMLGFX: Fix a bunch of potential cross-site scripting issues.
...
* Implement a mini HTTP server to service file requests from the slot
directory. Have the browser control download the file(s) via the
HTTP protocol instead of the FILE protocol.
TODO: Lock down the authentication mechanism so that it is reasonably
protected even though it is only bound to the loopback adapter.
* Configure the browser emulation level for the executable to
Internet Explorer 11.
2014-12-30 18:03:12 -05:00
Rom Walton
df7b112357
HTMLGFX: Remove unneeded files.
2014-12-30 01:05:15 -05:00
Rom Walton
9e1e50a4e7
HTMLGFX: Normalize the URLs configured by way of the configuration file. MSHTML would attempt to use HTTP when only a filename was given.
2014-12-29 23:09:54 -05:00
Rom Walton
33dbfbe975
HTMLGFX: It helps to actually put in the correct format specifier.
2014-12-29 00:28:32 -05:00
Rom Walton
f8b223714b
HTMLGFX: Minor comment fix
2014-12-29 00:26:55 -05:00
Rom Walton
9bf3be87ca
HTMLGFX: Log any configured state urls
2014-12-29 00:25:39 -05:00
Rom Walton
3e11ed3b93
HTMLGFX: Bug fixes for running against stock T4T.
2014-12-29 00:15:49 -05:00
Rom Walton
e1ab59eaee
HTMLGFX: Finish up the embedded HTML file which is used as a last resort.
2014-12-28 22:49:41 -05:00
Rom Walton
f305295f5b
HTMLGFX: Remap the JavaScript methods and properties to camel case to match the JavaScript standards.
2014-12-28 20:38:15 -05:00
Rom Walton
28bd2b81b2
HTMLGFX: Do not overwrite the State URLs if a project also exposes a Web API port as well. A project may choose to have a running HTML page that makes JSON calls to a web server running within a VM or science application.
2014-12-28 14:53:21 -05:00
Rom Walton
9dab824fc3
HTMLGFX: Make sure we do not overwrite the default URL with an empty state URL.
2014-12-28 00:34:06 -05:00
Rom Walton
fafbb9f27e
HTMLGFX: Determine the real path of the graphics description file with boinc_resolve_filename API.
2014-12-27 13:09:23 -05:00
Rom Walton
29eaf3944b
HTMLGFX: Streamline things a bit.
2014-12-27 11:28:43 -05:00
Rom Walton
c47052fa92
HTMLGFX: parse a boinc_graphics.xml file for a list of optional urls the htmlgfx can use for various states (running, suspended, network suspended, exiting).
...
HTMLGFX: look for and use various vboxwrapper state files for extracting the remote desktop port number and the webapi port number.
2014-12-27 01:25:10 -05:00
Rom Walton
bdd71e0129
HTMLGFX: Remove progress bar for now. It appears to be a bit too fancy and is distorting the page layout.
2014-12-26 21:36:51 -05:00
Rom Walton
19f680b8cf
HTMLGFX: Add a javascript based progress control to show fraction done
2014-12-26 21:07:30 -05:00
Rom Walton
94c6360035
HTMLGFX: Prevent a memory leak with the project_preferences init_data entry
2014-12-26 19:32:42 -05:00
Rom Walton
37974055a8
HTMLGFX: When in screensaver mode, exit with any mouse or keyboard activity
2014-12-26 19:22:32 -05:00
Rom Walton
e22d7b7b50
HTMLGFX: Hookup the graphics_status API polling.
2014-12-26 18:56:31 -05:00
Rom Walton
8963495ec4
WRAPPER: Use new graphics_status API to inform htmlgfx what is going on.
2014-12-26 17:43:00 -05:00
Rom Walton
f8be188baf
VBOX: Use new graphics_status API to inform htmlgfx what is going on.
2014-12-26 17:32:05 -05:00
Rom Walton
8ecf54ae41
VBOX: Write console messages to stderrgfx.log
2014-12-26 13:19:09 -05:00
Rom Walton
345bc273b9
VBOX: Initialize the HTML Document with a blank page
2014-12-26 13:02:09 -05:00
Rom Walton
cbda95ad3e
VBOX: Prevent new windows from being displayed either from HTML or from script.
2014-12-26 12:59:49 -05:00
Rom Walton
d43638c0e3
VBOX: Remove the Log() method from the HTML Document extension, hook into the console instead.
2014-12-26 12:58:58 -05:00
Rom Walton
24c5e2bdff
HTMLGFX: Add some more infrastructure for passing APP_INIT_DATA stuff to the HTML web page via the DOM.
2014-12-24 20:30:19 -05:00
Rom Walton
58c5dd9676
HTMLGFX: Reintroduce the HTML DOM Extension, embed the typelib in the executable.
...
Force the COM libraries to look within the executable instead of going out to the registry for the typelib information.
2014-12-24 14:01:35 -05:00
Rom Walton
24ef08bbb6
HTMLGFX: Add a default HTML page that mimics the screen saver bouncing BOINC logo.
...
HTMLGFX: Remove attempt at using the 'window.external' DOM extension, it was requiring a typelib.
2014-12-24 01:59:37 -05:00
Rom Walton
ad9616e143
HTMLGFX: Remove obsolete source files
2014-12-23 19:11:41 -05:00
Rom Walton
0c717ac635
VBOX: Decoupled the HTML Graphics application from vboxwrapper.
2014-12-23 16:54:03 -05:00
Rom Walton
b5ff288693
VBOX: Add the ability to add trace statements to stderrgfx.txt from an HTML based application
...
VBOX: Prepare for another refactor job to make a generic HTML based graphics application
2014-12-23 16:11:22 -05:00
Rom Walton
275e385148
VBOX: Introducing a basic graphics application for vboxwrapper based on HTML rendering. Basic plumbing is done.
...
TODO:
* Add vbox job elements to point to various URLs for various states. (running/suspended/not running)
* Add window timer to poll for shared memory changes
* Exit if running in screen saver mode and keyboard/mouse activity is detected.
2014-12-22 23:49:10 -05:00
Rom Walton
0ca76008f1
VBOX: Juha pointed out that I took one line of code out to many on a code cleanup pass. I'm adding it back in.
2014-12-22 16:35:10 -05:00
Rom Walton
58fcffc859
VBOX: Refactor vboxwrapper to streamline logging and prepare for vboxhtmlgfx.
2014-12-19 09:55:48 -05:00
Rom Walton
f2a7c28fc0
VBOX: Fix crash if DVD-ROM media had been ejected by some external event. Technically this shouldn't be happening, but something funky is going on with VirtualBox and we need to handle things that may cause a crash when cleaning up the VM.
2014-12-08 11:56:33 -05:00
Rom Walton
cb6c328151
VBOX: Make the vboxmanage interface work on Windows again.
...
VBOX: Make the service install scenario work again.
2014-11-23 23:22:57 -05:00
Rom Walton
1e04a9f150
VBOX: Fix check-pointing. I broke it with my error path cleanup.
2014-11-23 12:47:38 -05:00
Rom Walton
18abc0db07
VBOX: Get rid of unneeded variables
2014-11-23 12:47:37 -05:00
Rom Walton
a09b30353f
VBOX: Cleanup error handling code, remove duplication.
2014-11-23 12:47:37 -05:00
Rom Walton
85f364485c
VBOX: When checking for the existence of a VM registered to a given slot directory, also check for the ISO Contextualization image and cache disk image. If any type of media is registered to a given slot directory, close it regardless if it is attached to a VM or not.
2014-11-23 12:47:36 -05:00
Rom Walton
cbf93cdc86
VBOX: Fix build breaks (Part 2)
2014-11-23 12:47:35 -05:00
Rom Walton
7d3bb4803c
VBOX: Fix build breaks
2014-11-23 12:47:35 -05:00
Rom Walton
7713406f6f
VBOX: Bug fix for previous commit.
2014-11-23 12:47:34 -05:00
Rom Walton
715e0b2bb8
VBOX: When starting a VM, include its name and slot number in the stderr text.
2014-11-23 12:47:34 -05:00
Rom Walton
b2c9ab132b
VBOX: Make the conditions for one type of error case a bit clearer.
2014-11-23 12:47:33 -05:00
Rom Walton
017ac68c55
VBOX: last_checkpoint_cpu_time != last_checkpoint_elapsed_time. When to checkpoint is based on elapsed time, what we reported to boinc is the cpu time. Keep track of both values.
2014-11-23 12:47:32 -05:00
Rom Walton
660ade42bb
VBOX: When deregistering a VM, organize the medium list by most recent child first and then release as needed.
2014-11-23 12:47:32 -05:00
Rom Walton
56bfdd7ec9
VBOX: Use the same COM classes for consistency.
2014-11-23 12:47:31 -05:00
Rom Walton
3941d5153c
VBOX: Hookup COM support for both VirtualBox 4.2 and VirtualBox 4.3. It appears to be working.
2014-11-23 12:47:30 -05:00
Rom Walton
62578717e4
VBOX: Duplicate symbols have been removed from the link step.
2014-11-23 12:47:29 -05:00
Rom Walton
58ba52954a
VBOX: Source was a useful piece of information to dump.
2014-11-23 12:47:29 -05:00
Rom Walton
bf0b56c073
VBOX: Introduce the notion of Virtualbox COM namespaces. We currently support VirtualBox 4.2 and VirtualBox 4.3.
2014-11-23 12:47:05 -05:00
Rom Walton
6fcf9cbb5f
VBOX: Rename mscom to mscom43 to show that it contains VirtualBox 4.3 COM Interface files.
2014-11-23 12:47:03 -05:00
Rom Walton
a08f521036
VBOX: Add VirtualBox 4.2 COM Interface files
2014-11-23 12:47:02 -05:00
Rom Walton
8d6d54434b
VBOX: Do not attempt to restore the current snapshot if the VM hasn't been running long enough to generate one.
2014-11-23 12:47:01 -05:00
Rom Walton
31603fae79
VBOX: If something fails during create_vm(), we must release the write lock before deregister_vm() is called. Handle machine and session cleanup at the end if the routine.
2014-11-23 12:47:00 -05:00
Rom Walton
785c133882
VBOX: Actually wait for the VM to shutdown before doing anything drastic.
2014-11-23 12:46:59 -05:00
Rom Walton
7c0fa017ef
VBOX: Update error dump function with ATL Wrapper classes.
2014-11-23 12:46:59 -05:00
Rom Walton
e9acbfc8a8
VBOX: Cleanup some edge cases discovered while running T4T jobs with anon platform.
2014-11-23 12:46:58 -05:00
Rom Walton
fa325188fe
VBOX: Bug fixes related to running T4T jobs
2014-11-23 12:46:58 -05:00
Rom Walton
59152902b0
VBOX: Convert cleanup_snapshots() and various bug fixes
2014-11-23 12:46:57 -05:00
Rom Walton
56aeda1233
VBOX: Convert deregister_vm(), deregister_stale_vm()
2014-11-23 12:46:56 -05:00
Rom Walton
03a4fe3280
VBOX: Convert is_extpack_installed(), is_hdd_registered(), restore_snapshot(), create_snapshot()
2014-11-23 12:46:56 -05:00
Rom Walton
481a9fcb54
VBOX: Convert is_system_ready(), set_cpu_usage(), set_network_usage()
2014-11-23 12:46:55 -05:00
Rom Walton
78ca154407
VBOX: Fix get_default_network_interface()
2014-11-23 12:46:55 -05:00
Rom Walton
2f51aec2e2
VBOX: Convert create_vm()
2014-11-23 12:46:54 -05:00
Rom Walton
bb0e905bd7
VBOX: Convert get_vm_network_bytes_sent() and get_vm_network_bytes_received()
2014-11-23 12:46:53 -05:00
Rom Walton
2f79a92b5c
VBOX: Add a flag for GBAC functionality.
2014-11-23 12:46:53 -05:00
Rom Walton
b739badb44
VBOX: Write a stderr message when BOINC is notified about a web application for a particular task.
2014-11-23 12:46:52 -05:00
Rom Walton
fb98a4c644
VBOX: Guest additions may not be available on all hosts. If not found, skip it.
2014-11-23 12:46:52 -05:00
Rom Walton
5037444962
VBOX: Introduce the notion of a temporary exit trigger file.
...
When the file is detected, the wrapper will call boinc_temporary_exit() and restart the VM at a later date.
2014-11-23 12:46:51 -05:00
Rom Walton
810047d4eb
VBOX: Move common code to VBOX_BASE class, VBOX_VM derives from it by extending virtual functions calling Vboxmanage or Native API functions. Use ATL on Windows to wrap COM Objects and data types.
2014-11-23 12:46:28 -05:00
Rom Walton
72fd80a203
VBOX: Move common code to VBOX_BASE class, VBOX_VM derives from it by extending virtual functions calling Vboxmanage or Native API functions. Use ATL on Windows to wrap COM Objects and data types.
2014-11-23 12:45:03 -05:00
Rom Walton
c399c433f6
VBOX: Update set_network_access(), get_guest_additions(), and get_version_information()
2014-11-23 12:43:56 -05:00
Rom Walton
91b236a6a9
VBOX: Fix missing error codes for newly converted functions.
2014-11-23 12:43:56 -05:00
Rom Walton
dbcff881d5
VBOX: Finish start function and complete the poll function.
2014-11-23 12:43:55 -05:00
Rom Walton
557c15dbf0
VBOX: Begin refactoring for supporting the native VirtualBox API set on Windows. Use the code in the deprecated directory as a baseline.
2014-11-23 12:43:35 -05:00
David Anderson
444dc38a38
vboxmonitor: code format
2014-11-07 14:15:20 -08:00
Rom Walton
97b9d947b8
VBOX: Add a flag for GBAC functionality.
2014-10-24 11:54:11 -04:00
Rom Walton
f8dbde1dbf
VBOX: Write a stderr message when BOINC is notified about a web application for a particular task.
2014-10-22 15:35:56 -04:00
Rom Walton
a8a6eab086
VBOX: Unify port forwarding scheme for web applications within VMs.
2014-10-22 12:05:18 -04:00
Rom Walton
609a2924b3
VBOX: Guest additions may not be available on all hosts. If not found, skip it.
2014-10-20 10:07:16 -04:00
Rom Walton
3919da9524
VBOX: Introduce the notion of a temporary exit trigger file.
...
When the file is detected, the wrapper will call boinc_temporary_exit() and restart the VM at a later date.
2014-10-14 13:09:12 -04:00
David Anderson
317dc915b0
wrapper: let job.xml specify the process priorities of sub-tasks
...
Add optional <priority>N</priority> to <task> element to job.xml.
Lets you specify the process priority of the task;
in particular, task can run at high priority.
Apparently this is needed to make bitcoin ASIC apps perform well.
2014-10-13 11:35:16 -07:00
David Anderson
0f65225da8
wrapper (Win): fix possible bug in prioritizing child process
2014-10-12 11:42:19 -07:00
David Anderson
385e06562a
wrapper: set process priority of tasks, not thread priority.
2014-10-09 14:46:10 -07:00
David Anderson
8d849304d2
wrapper: fix Win compile warnings
2014-10-09 12:32:59 -07:00
David Anderson
1cb8585ec0
wrapper: add <no_priority_change> task option; run task at normal priority
2014-10-09 12:27:10 -07:00
Rom Walton
197a98f80a
VBOX: Add the COM Interface files for use on Windows
2014-10-04 09:58:47 +02:00
Rom Walton
b781e409f9
VBOX: Add support for intermediate uploads
2014-10-03 10:03:11 +02:00
Attila Csaba Marosi
456b008773
VBOX: GBAC main files added
2014-10-02 16:28:23 +02:00
Rom Walton
6518dddabd
VBOX: Attempt to fix a possible crash seen on T4T with an incompatible version of VirtualBox running on Linux.
2014-10-01 14:15:29 +02:00
Rom Walton
91cbe26810
VBOX: Try and prevent vboxwrapper from starting the VM if BOINC has signaled boinc_status.quit_requit or boinc_status.no_heartbeat.
2014-09-30 09:34:16 +02:00
Rom Walton
e5a4f0345d
VBOX: Always report the completion message.
2014-09-24 13:34:22 -04:00
Rom Walton
e1da8323bd
VBOX: Bubble up completion file notices to the client software.
2014-09-24 13:18:38 -04:00
Rom Walton
99c8c678dd
VBOX: Make the VM memory size something that can be overridden via the command line.
...
TODO: Refactor how command line options and vbox_job.xml options are handled. This was a ugly hack.
2014-09-24 13:06:05 -04:00
Rom Walton
c0c70fd82d
VBOX: Make the guest additions available to all VMs. This does not mean the VM will use them, but they will be available.
2014-09-20 12:53:44 -04:00
Rom Walton
8621a2ca03
VBOX: Do not disable the host I/O cache for virtualized disk controllers that do not support async I/O within VirtualBox.
2014-09-16 17:46:42 -04:00
Rom Walton
c768866118
VBOX: Look for the fraction done file in the shared directory by default
2014-09-15 17:21:11 -04:00
Rom Walton
9c80adb5a1
VBOX: Initialize completion file values before parsing.
2014-09-12 11:50:22 -04:00
Rom Walton
17cef8372c
VBOX: Increase the buffer used for parsing 'Guest Log:' entries from 8k to 16k.
2014-09-12 11:29:41 -04:00
Rom Walton
afd34b8072
VBOX: Check for the completion file regardless if the VM is running or not.
2014-09-12 11:18:43 -04:00
Rom Walton
952c064f18
* Fix version resource information for wrapper and vboxwrapper.
...
(From: Teemu Mannermaa)
2014-09-08 12:37:15 -04:00
Rom Walton
837948ff24
VBOX: Use the 'Name' field instead of the internal virtualbox name for the default network interface.
2014-08-22 15:22:39 -04:00
Rom Walton
4b60c60fa8
VBOX: When the bridged network option is selected, don't forget to set which network interface it is supposed to bridge with.
2014-08-22 14:18:53 -04:00
Rom Walton
498a3b79ae
VBOX: Fix typo
2014-08-20 10:35:19 -04:00
David Anderson
e55297a8f0
vboxwrapper: change option name to "network_bridged_mode"
2014-08-19 19:28:38 -07:00
Rom Walton
188a13b2fb
VBOX: Rename bridged_mode to enable_network_bridged_mode.
...
VBOX: Set the network configuration at VM creation time. set_network_access() is called whenever the network is suspended or resumed. It'll cause multiple DHCP requests to be spawned on a network resume.
2014-08-19 14:48:10 -04:00
David Anderson
c7aaf64423
vboxwrapper: add <bridge_mode/> otion for bridged mode networking
2014-08-18 20:33:51 -07:00
Rom Walton
0bea6cb296
VBOX: Do not use a VM's XML file to determine valid disk controller combinations, vboxmanage attempts to maintain backwards compatibility so we do not have too.
2014-08-17 21:49:22 -04:00
Rom Walton
d1c28266fa
VBOX: with VirtualBox 4.3 they renamed the 'IntelAHCI' disk controller to 'AHCI'. Automatically adjust depending on the installer version of VirtualBox.
2014-08-14 23:53:01 -04:00
David Anderson
6ab3a999c7
Merge branch 'master' of ssh://boinc.berkeley.edu/boinc-v2
2014-08-13 21:27:57 -07:00
David Anderson
e2e08e313d
vboxwrapper: small code cleanup
2014-08-13 21:27:30 -07:00
Rom Walton
ea6c073082
VBOX: Configure guest VM BOIS so that it can boot off of DVD ISO images.
2014-08-13 16:56:05 -04:00
Rom Walton
355c911d9b
VBOX: If <enable_isocontextualization/> is enabled, update which drive controller to use and attach the guest additions to the VM. This should allow uCernVM to update the guest additions it uses on boot.
2014-08-13 14:15:37 -04:00
Rom Walton
27cc7a8c42
VBOX: Acquire the location of the guest additions for future use.
2014-08-13 13:46:38 -04:00
David Anderson
7ed32661cb
vboxwrapper: fix bug in forwarding multiple ports
2014-08-12 09:18:35 -07:00
Charlie Fenton
b482a8241e
Mac: update VBoxWrapper Xcode project for compatibility (fix compile breaks) with Apple LLVM 5.0 compiler under Xcode 5.
2014-08-11 15:36:45 -07:00
David Anderson
ab9b146054
vboxwrapper: add a general port-forwarding mechanism
...
All vbox_job.xml to specify ranges of port forwardings,
and whether the access to the host ports is remote or local.
This is to support MPI for Rytis.
Notes:
- the existing feature (pf_guest_port) is used only for web graphics.
The host port is always dynamically assigned;
there's no reason to have <pf_host_port>; I removed it from the doc.
There's no reason to write the host port to a file; I removed that.
- The new feature is only for fixed host ports.
- The checkpoint file can stay the way it is.
2014-08-02 23:07:22 -07:00
David Anderson
d43f78f97a
vboxwrapper: compile fix, and error-check kill_program().
...
Note: utility functions like kill_program() should return
BOINC error codes, not Unix codes
2014-07-29 13:19:07 -07:00
Rom Walton
7a9b572fb5
VBOX: If the VM doesn't gracefully shutdown, attempt to terminate it.
2014-07-27 14:11:32 -04:00
David Anderson
b3392bb195
scheduler: fix bug in plan class spec logic
2014-07-25 15:04:04 -07:00
David Anderson
64184333a7
wrapper: comment tweak
2014-07-16 19:28:33 -07:00
Rom Walton
d80f2e271c
VBOX: Make sure we only check for the VM exit code if we have a valid handle.
2014-07-14 12:26:10 -04:00
Rom Walton
fa7ebdca4e
VBOX: Do not go off the rails if a process handle cannot be obtained for the VM process. Changing process priority of a Virtualbox 4.3.14 VM does not currently work.
2014-07-12 15:27:03 -04:00
Rom Walton
6ad292cbdc
VBOX: resolve build breaks caused by a bad merge.
2014-07-07 16:30:31 -04:00
Rom Walton
d252088210
Add filename to log
...
Signed-off-by: Carlos Aguado Sanchez <carlos.aguado@epfl.ch>
2014-07-07 16:18:54 -04:00
Carlos Aguado Sanchez
acf54750a8
Fix naming scheme for cache and iso
...
Signed-off-by: Carlos Aguado Sanchez <carlos.aguado@epfl.ch>
2014-07-07 16:04:11 -04:00
Rom Walton
a57cbb7987
Add implementation for an extra cache disk
...
This commit adds two extra options:
- enable_cache_disk
- cache_disk_filename
This allows to attach a cache disk image to extend the storage
needs initially provided by the OS image.
In context-based systems such as uCernVM, this image can be
used to store the local cache of artifacs coming from CVMFS.
Note this image is attached without further checking on the content
and is entirely up to the main OS to make good use of it.
Signed-off-by: Carlos Aguado Sanchez <carlos.aguado@epfl.ch>
2014-07-07 16:03:46 -04:00
Rom Walton
56ae3415a4
VBOX: remove unneeded variable
2014-07-07 15:47:31 -04:00
Rom Walton
7ec9e95822
Enable VM contextualization via ISO9660 image
...
This commit allows to attach an ISO9660 image to a vbox VM
from a well-known file. The purpose is to enable the dynamic
configuration of the VM in first boot so that the volunteer VM
can be kept generic. This process is otherwise widely known as
contextualization of virtual machines.
The actual content of the ISO9660 image is application dependent
and outside the scope of this implementation.
Signed-off-by: Carlos Aguado Sanchez <carlos.aguado@epfl.ch>
2014-07-07 15:46:59 -04:00
David Anderson
658547ccf6
wrapper: add --trickle X cmdline option to periodically report runtime
...
Add logic in wrapper to maintain and checkpoint total runtime.
Also vboxwrapper: slight refactor.
Note: we often use "elapsed time" where we mean "runtime".
Should use the latter.
2014-07-04 12:19:31 -07:00
Rom Walton
8821d735a6
VBOX: Fix another typo.
2014-07-03 00:10:53 -04:00
Rom Walton
124223fd41
VBOX: Fix typos in launch_vboxvm() logic. It isn't currently used, but I do want to try and get that working at some point in the future.
2014-07-02 23:41:58 -04:00
Rom Walton
f230391349
VBOX: If recent copies of VirtualBox log files are missing, use the last cached copy of the log file we successfully retrieved for dumping out log data on premature shutdowns.
2014-07-02 19:44:05 -04:00
David Anderson
89b27cabf9
vboxwrapper: temporary change to completion trigger file:
...
pause for 60 seconds before exiting, and don't read trigger file.
For ATLAS@home. Undo when they update their VM.
2014-07-01 23:01:42 -07:00
David Anderson
56c30c8427
vboxwrapper: fix function names to use consistent style.
2014-07-01 13:43:43 -07:00
David Anderson
b8627bace1
vboxwrapper: add "completion trigger file" mechanism.
...
When it's finished, the VM app can write a file of a given name
(specified in vbox_job.xml) in the shared dir.
This file can optionally contain an exit code and stderr text.
If vboxwrapper finds this file, it cleans up the VM and calls boinc_finish().
This works around a problem where the VM doesn't exit properly
and the task hangs forever.
2014-07-01 13:31:25 -07:00
Rom Walton
b22d2a7855
VBOX: Late saved file
2014-07-01 15:22:05 -04:00
Rom Walton
f1981368f8
VBOX: Partial commit for completion trigger files (David taking over)
2014-07-01 15:19:17 -04:00
Oliver Bock
88e840fc95
Normalized line breaks according to latest updates of .gitattributes
...
* As discussed with Rom
* See also: d81607b
, e93af6a
, 26ca219
, 8dad345
2014-06-27 10:12:11 +02:00
David Anderson
1a33c1465d
vboxwrapper: add support for "trickle trigger files"
2014-06-20 19:33:10 -07:00
David Anderson
0441285cf2
wrapper: fix comment
2014-06-20 19:32:53 -07:00
David Anderson
8992189045
tweaks (fix comments, compile warnings)
2014-06-20 17:15:04 -07:00
Rom Walton
ad32ed3ecc
VBOX: Switch back to using elapsed time in determining checkpoint based timings.
2014-05-30 23:16:34 -04:00
Rom Walton
26e16ac48e
VBOX: When restarting and restoring from a checkpoint, make sure we do not checkpoint again until after the minimum checkpoint interval.
2014-05-30 19:32:35 -04:00
Rom Walton
112a3f5ae7
Merge branch 'master' of ssh://isaac.ssl.berkeley.edu/boinc-v2
2014-05-30 19:25:46 -04:00
Rom Walton
817dfd87ef
VBOX: Only get the updated CPU time every tenth iteration through the main loop.
2014-05-30 19:25:28 -04:00
David Anderson
b3ae21d528
Merge branch 'master' of ssh://boinc.berkeley.edu/boinc-v2
2014-05-30 14:59:03 -07:00
Rom Walton
189a17ef07
VBOX: If vboxwrapper is running in standalone mode (not under BOINC), run the VM in head full mode.
2014-05-30 17:35:48 -04:00
David Anderson
25422782a3
wrapper: macro-subsitute GPU_DEVICE_NUM in cmdline passed to app
2014-05-30 14:27:07 -07:00
Rom Walton
eb2d2de370
Merge branch 'master' of ssh://isaac.ssl.berkeley.edu/boinc-v2
2014-05-30 16:10:38 -04:00
Rom Walton
081dcca1f0
VBOX: Setting the minimum checkpoint interval should not cause the wrapper to believe that it should run in headfull mode.
2014-05-30 16:08:48 -04:00
David Anderson
e6f01ecb77
Merge branch 'master' of ssh://boinc.berkeley.edu/boinc-v2
2014-05-30 12:29:39 -07:00
David Anderson
4d6ebcf6a1
change "core client" to "client" in some comments.
2014-05-30 12:29:08 -07:00
Rom Walton
31a40f74e1
VBOX: Ugh, I missed assigning the starting_cpu_time variable when restoring from a checkpoint.
2014-05-30 14:35:24 -04:00
Rom Walton
81bbafc5c5
VBOX: Make the minimum checkpoint interval project configurable.
...
VBOX: Accumulate CPU Time across restarts of the wrapper.
2014-05-30 13:50:29 -04:00
Rom Walton
45df1256fc
VBOX: Base checkpoints on CPU time instead of elapsed time.
2014-05-29 10:01:56 -04:00
Rom Walton
c30bd62227
VBOX: Report CPU Time instead of elapsed time to boinc_report_app_status()
2014-05-29 09:46:10 -04:00
Rom Walton
1f4098aaa9
VBOX: Write the desired checkpoint interval to stderr on startup and every time it changes.
2014-05-29 01:20:16 -04:00
Rom Walton
817cb0eabd
VBOX: Write output from vboxmonitor (running within the guest VM) to stderr as soon as it is written to the guest VM log.
...
VirtualBox recreates the guest VM log every time the guest VM is launched. If the VM is using vboxmonitor to write the status of the job or any potential failures of mounting the shared directory it might have been lost under the old policy.
2014-05-29 01:12:24 -04:00
Rom Walton
af9f2e83bc
VBOX: Fix typo
2014-05-28 20:39:27 -04:00
David Anderson
f15f6d2ba0
API/client/vboxwrapper: show notice if need Vbox upgrade
...
Vboxwrapper detects known buggy versions of Vbox and calls
boinc_temporary_exit().
The "Incompatible version" message appears in the task status
in the BOINC Manager, where some users may never see it.
It needs to appear as a notice, telling the user to upgrade VBox.
To do this, I added an optional argument to boinc_temporary_exit()
saying that the message should be delivered as a notice.
This is conveyed to the client by adding
a line containing "notice" to the temp exit file.
I changed the client and vboxwrapper to use this.
2014-05-28 11:05:56 -07:00
Rom Walton
9f5e9a0b7e
VBOX/WRAPPER: Introduce versioning information to the two wrappers. It is now compiled into the executable instead of relying on file name.
2014-05-21 13:57:16 -04:00
David Anderson
f3366ec5ba
client: track and report network, disk, and memory usage
...
- store final network usage in RESULT; write/parse in state file
- final disk and memory usage weren't being written to state file; do so.
- add --network_usage option to example app, to test this stuff
2014-05-01 13:05:30 -07:00
David Anderson
aacf0b0344
wrapper: log task completion as well as start
2014-04-30 15:36:28 -07:00
Rom Walton
91570a3e46
WRAPPER: remove outdated build script
2014-04-18 17:10:11 -04:00
Rom Walton
df17079ef5
WRAPPER: Remove the pthread library when building for Android.
2014-04-18 17:09:17 -04:00
Rom Walton
36d41d9edc
WRAPPER: Fix for previous commit
2014-04-18 16:08:46 -04:00
Rom Walton
673271c618
WRAPPER: Conditionally include pthread based on what platform we are compiling for.
2014-04-18 16:02:17 -04:00
Rom Walton
04eb8512fd
WRAPPER: Use the correct C++ compiler
2014-04-18 15:41:41 -04:00
Rom Walton
3bde3f7d60
ANDROID: Introduce build scripts for building the wrapper on Android.
2014-04-18 15:19:31 -04:00
David Anderson
563a020bed
vboxwrapper: do sanity checks on elapsed time increments
2014-04-14 15:01:42 -07:00
David Anderson
5bcdacfa64
Condor interface: race condition fix, from Jamie
2014-04-14 13:29:04 -07:00
Rom Walton
bac89be769
VBOX: Only increment the elapsed time is both boinc_status.suspended is false and vm.suspended is false.
...
VBOX: Only change the elapsed time is the stop watch elapsed time is a positive value.
This is just weird (http://lhcathome2.cern.ch/test4theory/result.php?resultid=4289098 ):
2014-04-08 15:52:43 (6732): Status Report: Job Duration: '86400.000000'
2014-04-08 15:52:43 (6732): Status Report: Elapsed Time: '54506.443735'
2014-04-08 16:06:16 (6732): Status Report: Job Duration: '86400.000000'
2014-04-08 16:06:16 (6732): Status Report: Elapsed Time: '450358026.129327'
2014-04-10 12:12:33 -04:00
Rom Walton
14d24440dc
VBOX: Print out the decimal value for the random checkpoint value instead of a double.
2014-04-05 15:28:06 -04:00
Rom Walton
6f55578937
VBOX: Initialize the random number generator before asking for a random number.
2014-04-05 15:23:39 -04:00
Rom Walton
1a744614b6
VBOX: Introduce a random checkpoint offset value on initial start up to interleave the disk I/O when multiple vboxwrappers are running.
2014-04-05 14:28:33 -04:00
David Anderson
f3b7a30548
vboxwrapper: fix comments and code formatting
2014-03-24 15:00:49 -07:00
Charlie Fenton
3637e0f6da
lib, nvcuda: Fix warnings from cppcheck reported by Toralf Förster.
2014-03-20 05:20:04 -07:00
Rom Walton
ea7c24e387
VBOX: Replace calls to GetProcessWorkingSetSizeEx() with GetProcessWorkingSetSize(). Some versions of Windows XP do not support the API.
2014-03-19 16:05:05 -04:00
David Anderson
7008db6c24
Merge branch 'master' of ssh://boinc.berkeley.edu/boinc-v2
2014-03-13 13:21:22 -07:00
David Anderson
12b4f43793
Condor interface: when unzipping output file, use job-specific name for temp file to avoid conflict between jobs
2014-03-13 13:07:16 -07:00
Rom Walton
488ed2f43b
VBOX: Tweak the process priority of vboxheadless/virtualbox.exe so that it is above regular science applications.
...
On systems with comparatively slow disk subsystems, the I/O can become saturated. This leads the Linux Kernel on guest OS's dumping out warning messages to the console of failure to write data to disk. Since the device drivers are timer sensitive we will boost the priority of the process to boost its disk I/O requests above the other disk I/O of science applications. Science applications themselves generally don't have timeouts when checkpointing and the like.
2014-03-13 12:39:01 -04:00
David Anderson
cd042dd566
vboxwrapper: fix compile warnings on Linux
2014-03-04 13:02:04 -08:00
Rom Walton
d50d1009f7
VBOX: When parsing for a 32-bit exit code from VboxManage compare against std::string:npos instead of just checking for a non-null value.
2014-02-18 11:27:39 -05:00
Rom Walton
c6047d3011
VBOX: Provide status report log entries that show the min and max working set size on Windows.
2014-02-14 11:15:34 -05:00
Rom Walton
9b4347c3fc
VBOX: One additional fix for RPC_S_SERVER_UNAVAILABLE.
2014-02-11 16:25:28 -05:00
Rom Walton
0116f9485f
VBOX: Look for RPC_S_SERVER_UNAVAILABLE errors across all platforms.
2014-02-11 16:24:03 -05:00
Rom Walton
980b8c6d69
VBOX: VboxManage returns an exit code of 0 when a RPC_S_SERVER_UNAVAILABLE error occurs. Special case the error.
2014-02-11 16:17:43 -05:00
Rom Walton
35d2786797
VBOX: Fix a dump hypervisor log format issue
2014-02-11 10:31:49 -05:00
Rom Walton
9b041f7004
VBOX: Fix case of virtualbox and vboxheadless for platforms that are case sensitive. The code is currently disabled anyway, but if we re-enable it at some point we might as well avoid the bug.
2014-02-06 10:15:52 -05:00
Rom Walton
106653ffe4
VBOX: If vboxmanage returns a CO_E_SERVER_EXEC_FAILURE error, go again and retry the command anyway.
...
Vboxsvc may be running and working but some other oddity prevented vboxmanage from communicating with vboxsvc. Evidence suggests future attempts may not fail. Trace logs indicates that the clean-up routines did not fail when we attempted to cleanup the environment before reporting a failure.
2014-02-05 16:23:46 -05:00
Rom Walton
c1e980870d
VBOX: If the volunteer abort the job while we are running, capture all the error logs in case they aborted because of an error.
2014-02-04 18:02:29 -05:00
Rom Walton
0ed3f27db2
VBOX: Sanitize vboxmanage's output before writing it to the trace log.
2014-02-04 15:51:28 -05:00
Rom Walton
ab9f75c155
VBOX: If we fail to terminate vboxmanage on a TIMEOUT, log the reason why.
2014-02-04 15:13:49 -05:00
Rom Walton
8a1d2b49e0
VBOX: Missed one temp exit.
2014-02-03 18:35:10 -05:00
Rom Walton
cd40976187
VBOX: Change the default temp exit timeout from 5 minutes to a day.
2014-02-03 18:33:40 -05:00
Rom Walton
b971791e59
VBOX: If an error occurs, dump 8k of the VM trace log as well. Hopefully we can figure out what the duplicate UUID issue is as well as some of the snapshot issues.
2014-02-03 18:30:57 -05:00
Charlie Fenton
2c6032d26e
VBOX: Fix compiler error and compiler warning on Mac
2014-01-28 02:38:03 -08:00
Rom Walton
4dda6f53e1
VBOX: Start success is when both vm_pid and vm_pid_handle are non-zero values.
2014-01-23 07:30:16 -05:00
Rom Walton
4115e9a454
VBOX: Only look for the VM pid if no error code was returned from vbm_popen().
2014-01-22 19:55:14 -05:00
Rom Walton
52258d9359
VBOX: Bring back the method of using vboxmanage to launch the VM.
...
We are getting some funky results launching the VM directly and the next update window for RNAWorld is this Friday. So using the old method for that release is the right thing to do.
2014-01-22 19:52:26 -05:00
Rom Walton
b8b768fbf6
VBOX: Vboxsvc doesn't return error codes in the same format as vboxmanage. Special case vboxsvc error code RPC_S_SERVER_UNAVAILABLE.
2014-01-22 16:33:21 -05:00
Rom Walton
f3f9a19d23
VBOX: Do not retry the closemedium commands when unregistering stale VMs. VirtualBox has probably deleted the files. This is kept around for older versions of VirtualBox.
2014-01-22 16:12:38 -05:00
Rom Walton
d32dfbb63d
VBOX: Make the guest log feature function correctly with less than 16k worth of output.
2014-01-22 15:21:58 -05:00
Rom Walton
b9e2af9c14
VBOX: It is also useful to know whether commands had to be retried after a timeout
2014-01-22 14:38:42 -05:00
Rom Walton
6cfdbf88f1
VBOX: Introducing the replay and trace logs for vboxwrapper.
...
The replay log stores the commands that were executed in a near shell script state. Ideally we should be able to use this to pass bugs back upstream to VirtualBox.
The trace log shows the date, time, thread id, command, return value, and output of the above commands.
2014-01-22 14:34:20 -05:00
Rom Walton
5778cd653f
VBOX: Unify the code that strips the carriage returns from various output of VirtualBox commands
2014-01-22 11:52:06 -05:00
Rom Walton
a09e6f145b
VBOX: Only consider launch_vboxvm() a success if the VM process is still running after our read output buffer loop
2014-01-22 11:32:06 -05:00
Rom Walton
5f2fbe9dfc
VBOX: Fortify the launch_vboxvm() function and print out any error information if virtualbox/vboxheadless fails wthin the first second of execution.
...
VBOX: Rework the delete stale snapshot mechanism to avoid the 'multiple child hard drive' errors.
VBOX: Treat the RPC_S_SERVER_UNAVAILABLE error when restoring the current snapshot as unrecoverable (vboxsvc has crashed) and exit without attempting to cleaning up. Other VMs running and being monitored by BOINC will crash as well.
2014-01-22 10:44:38 -05:00
Rom Walton
d189767b0e
VBOX: Fix the guest log parser
2014-01-21 11:29:13 -05:00
David Anderson
07e8026caa
example app comment typo
2014-01-20 23:39:59 -08:00
David Anderson
04327eb7e7
vboxwrapper: fix VM-launch code for UNIX
2014-01-20 23:34:35 -08:00
Rom Walton
8c0139937c
VBOX: Fix another formatting issue
2014-01-21 00:47:10 -05:00
Rom Walton
ce48f695f4
VBOX: Fix format issue
2014-01-21 00:26:25 -05:00
Rom Walton
87f6f0c2ea
VBOX: Change how we launch the VirtualBox VM process. Directly execute virtualbox.exe or vboxheadless.exe depending on configuration.
2014-01-21 00:18:56 -05:00