Page 1 of 1

Run Script when VM Resumes from Suspend State?

Posted: 29. Apr 2011, 08:13
by eheaton
I'm relatively knew to VirtualBox- I like what I see so far. I was wondering, is there a way to notify my guest OS (winXP) of when its being resumed from a VirtualBox suspended state? I'm looking to have a script run on launch of the VM. I know I could do a startup/login script- thought I'm using my VM for an automated task and would like to speed up the startup/boot as fast as possible.

Thanks in advance for any ideas.

Re: Run Script when VM Resumes from Suspend State?

Posted: 29. Apr 2011, 20:10
by eheaton
I'll actually answer my own question. I ended up writing a windows script that launched the VM from VBoxManage, waited for it to launch, then ran the "VBoxManage guestcontrol exec" command to run a script on the guest host. Worked like a charm.