Author Topic: Shortcut to start VM from host  (Read 1929 times)

Offline Fargo

  • Hero Member
  • *****
  • Posts: 839
Shortcut to start VM from host
« on: October 06, 2010, 12:12:52 PM »
Is it possible to put a shortcut on my host desktop (PCLOS2010) to start up my virtual machine OS (WinXP)?  Or even better to open up a program within the VM directly from the host OS?

Offline russell.eberhardt

  • Sr. Member
  • ****
  • Posts: 408
Re: Shortcut to start VM from host
« Reply #1 on: October 06, 2010, 01:18:08 PM »
Yes, you can like this start XP directly from the desktop by right clicking the desktop selecting
Create New>Link to Application

Then, on the Application tab enter any name you like for Description, VBoxManage startvm XP for Command (where XP is the name of your VM), and /home/{username}/.VirtualBox/ for the work path.

Russell.
Desktop: Gigabyte GA-MA770T-UD3 motherboard, NVIDIA GeForce 8400GS, AMD Phenom II Quad Core Processor 3GHz, 4GB ram, 250GB + 500GB SATA HD,

Offline Fargo

  • Hero Member
  • *****
  • Posts: 839
Re: Shortcut to start VM from host
« Reply #2 on: October 06, 2010, 01:45:20 PM »
Yes, you can like this start XP directly from the desktop by right clicking the desktop selecting
Create New>Link to Application

Then, on the Application tab enter any name you like for Description, VBoxManage startvm XP for Command (where XP is the name of your VM), and /home/{username}/.VirtualBox/ for the work path.

Russell.

Excellent.  That works.  Actually it took me two tries because I forgot that linux commands are case sensitive.  But after I corrected that, it booted up my WinXP VM just like I wanted.  Thank you. 

You know VBox has been coming together so nicely for me its almost scarry.  And I am a total newbie at this.  I've never installed a virtual machine before.  But I just clicked on the getvirtualbox command and later added a guest addition and everything has been working smoothly.  I don't even know what a guess addition is.  But it sure made it nice to move from within Windows and PCLOS seamlessly and it resizes XP to fit perfectly in the window its open in.

Now the only thing that would be better would be if I could link to the program I want to open directly and not even have to see XP.  I don't suppose you can tell me how to do that can you?  Basically I want Wine to be perfected to run any Windows programs.  But this will work for now.  Thanks again.

Offline shrinivas

  • Full Member
  • ***
  • Posts: 154
Re: Shortcut to start VM from host
« Reply #3 on: October 07, 2010, 12:03:32 AM »
Yes, you can like this start XP directly from the desktop by right clicking the desktop selecting
Create New>Link to Application

Then, on the Application tab enter any name you like for Description, VBoxManage startvm XP for Command (where XP is the name of your VM), and /home/{username}/.VirtualBox/ for the work path.

Russell.

Worked like a charm, thank you !
AMD ATHLON 64X2 5200, 2 GB RAM, nVidia 7600GT 256 RAM, HD0 320GB,HD1 80GB Triple-boot PCLinuxOs Zen Mini/WinXp/E17

Offline russell.eberhardt

  • Sr. Member
  • ****
  • Posts: 408
Re: Shortcut to start VM from host
« Reply #4 on: October 07, 2010, 03:30:22 AM »
Now the only thing that would be better would be if I could link to the program I want to open directly and not even have to see XP.  I don't suppose you can tell me how to do that can you?  Basically I want Wine to be perfected to run any Windows programs.  But this will work for now.  Thanks again.

Sorry, I haven't found a way to do that yet.  Would be nice though.  Perhaps someone more knowledgeable will jump in?

Russell.
Desktop: Gigabyte GA-MA770T-UD3 motherboard, NVIDIA GeForce 8400GS, AMD Phenom II Quad Core Processor 3GHz, 4GB ram, 250GB + 500GB SATA HD,

Offline shrinivas

  • Full Member
  • ***
  • Posts: 154
Re: Shortcut to start VM from host
« Reply #5 on: October 19, 2010, 06:56:08 PM »
Yes, you can like this start XP directly from the desktop by right clicking the desktop selecting
Create New>Link to Application

Then, on the Application tab enter any name you like for Description, VBoxManage startvm XP for Command (where XP is the name of your VM), and /home/{username}/.VirtualBox/ for the work path.

Russell.
Thank you !
AMD ATHLON 64X2 5200, 2 GB RAM, nVidia 7600GT 256 RAM, HD0 320GB,HD1 80GB Triple-boot PCLinuxOs Zen Mini/WinXp/E17

Offline pags

  • Hero Member
  • *****
  • Posts: 2515
  • Keep it clean.
Re: Shortcut to start VM from host
« Reply #6 on: October 20, 2010, 11:27:09 AM »
If you install seamlessrdp on your XP guest (http://www.cendio.com/seamlessrdp/, I installed it in c:\seamlessrdp\), and enable Remote Desktop access to your XP VM (http://www.microsoft.com/windowsxp/using/mobility/getstarted/remoteintro.mspx), you can use rdesktop to get what you want:
Code: [Select]
rdesktop -A -s "c:\seamlessrdp\seamlessrdpshell.exe path:\to\program\to\run" ip.of.xp.machine
A little extra googling should get you everything you need to get it up and running...

Offline Fargo

  • Hero Member
  • *****
  • Posts: 839
Re: Shortcut to start VM from host
« Reply #7 on: October 20, 2010, 12:37:47 PM »
If you install seamlessrdp on your XP guest (http://www.cendio.com/seamlessrdp/, I installed it in c:\seamlessrdp\), and enable Remote Desktop access to your XP VM (http://www.microsoft.com/windowsxp/using/mobility/getstarted/remoteintro.mspx), you can use rdesktop to get what you want:
Code: [Select]
rdesktop -A -s "c:\seamlessrdp\seamlessrdpshell.exe path:\to\program\to\run" ip.of.xp.machine
A little extra googling should get you everything you need to get it up and running...



Are you saying that by setting up Remote Desktop access I can run a program on my Windows VM without actually booting up windows?  Or did I misunderstand something?

Offline pags

  • Hero Member
  • *****
  • Posts: 2515
  • Keep it clean.
Re: Shortcut to start VM from host
« Reply #8 on: October 20, 2010, 12:43:23 PM »
If you install seamlessrdp on your XP guest (http://www.cendio.com/seamlessrdp/, I installed it in c:\seamlessrdp\), and enable Remote Desktop access to your XP VM (http://www.microsoft.com/windowsxp/using/mobility/getstarted/remoteintro.mspx), you can use rdesktop to get what you want:
Code: [Select]
rdesktop -A -s "c:\seamlessrdp\seamlessrdpshell.exe path:\to\program\to\run" ip.of.xp.machine
A little extra googling should get you everything you need to get it up and running...



Are you saying that by setting up Remote Desktop access I can run a program on my Windows VM without actually booting up windows?  Or did I misunderstand something?


Windows needs to be booted.  If you don't want to see it, look into the VBoxHeadless command.  This will run the VM without any visible interface.  You can then rdesktop into the XP guest, once you know the IP address (you can also rdesktop into the VM using the IP of the host, so you can reboot, and get into the BIOS of the VM, etc...that will give you the chance to find your IP).

...

Oh yeah, I forgot...you'll probably have to setup the VM guest's networking to connect directly (i.e, not through NAT), otherwise RDP attempts to the guest may be blocked...

Offline Fargo

  • Hero Member
  • *****
  • Posts: 839
Re: Shortcut to start VM from host
« Reply #9 on: October 20, 2010, 12:47:27 PM »
Thanks for the input.  I may have to give this a try.  Although at this point I might just use it as it is for a while just to get a feel for running something in a VM since I have never done this before.  Thanks again, I appreciate the tips.

Offline j-retired

  • Hero Member
  • *****
  • Posts: 983
  • To find out what 'busy' is, then try retiring!
Re: Shortcut to start VM from host
« Reply #10 on: October 20, 2010, 01:53:26 PM »
....................
Now the only thing that would be better would be if I could link to the program I want to open directly and not even have to see XP.  I don't suppose you can tell me how to do that can you?  Basically I want Wine to be perfected to run any Windows programs.  But this will work for now.  Thanks again.

If, when you want to leave your XP  hosted program, you use "Save machine state" instead of shutting down the program then shutting down XP, then when you restart VB (by whatever means) you will be back in your program!  Furthermore, you will be at the work point exactly where you left!
I have found this 100% reliable, which is more than I can say for win's suspend or hibernate options.

 :)
j

Offline Fargo

  • Hero Member
  • *****
  • Posts: 839
Re: Shortcut to start VM from host
« Reply #11 on: October 20, 2010, 02:07:00 PM »
....................
Now the only thing that would be better would be if I could link to the program I want to open directly and not even have to see XP.  I don't suppose you can tell me how to do that can you?  Basically I want Wine to be perfected to run any Windows programs.  But this will work for now.  Thanks again.

If, when you want to leave your XP  hosted program, you use "Save machine state" instead of shutting down the program then shutting down XP, then when you restart VB (by whatever means) you will be back in your program!  Furthermore, you will be at the work point exactly where you left!
I have found this 100% reliable, which is more than I can say for win's suspend or hibernate options.

 :)
j

That definitely sounds easy enough to give a try.  Thanks for the tip.

Offline russell.eberhardt

  • Sr. Member
  • ****
  • Posts: 408
Re: Shortcut to start VM from host
« Reply #12 on: October 21, 2010, 02:33:43 AM »
[
If, when you want to leave your XP  hosted program, you use "Save machine state" instead of shutting down the program then shutting down XP, then when you restart VB (by whatever means) you will be back in your program!  Furthermore, you will be at the work point exactly where you left!
I have found this 100% reliable, which is more than I can say for win's suspend or hibernate options.

 :)
j
This does indeed work well.  One warning though; shut down XP before updating from Synaptic otherwise you may find yourself with a new version of VirtualBox that is incompatible with your saved machine state.  Guess how I know :(

Russell.
Desktop: Gigabyte GA-MA770T-UD3 motherboard, NVIDIA GeForce 8400GS, AMD Phenom II Quad Core Processor 3GHz, 4GB ram, 250GB + 500GB SATA HD,

Offline rubentje1991

  • PCLinuxOS Tester
  • Hero Member
  • *******
  • Posts: 2110
  • Rubenus Parvus MCMXCI
Re: Shortcut to start VM from host
« Reply #13 on: October 21, 2010, 02:50:14 AM »
Yes, you have to be careful with that....

Offline rubentje1991

  • PCLinuxOS Tester
  • Hero Member
  • *******
  • Posts: 2110
  • Rubenus Parvus MCMXCI
Re: Shortcut to start VM from host
« Reply #14 on: October 21, 2010, 02:52:38 AM »
Here is a link to an explanation of starting applications from your host (your vm has to be started anyway I think)

http://www.virtualbox.org/manual/ch08.html#vboxmanage-guestcontrol

It is possible (but not with Visual Studio - which I tried => more files there with the same name; windows can set them seperate apparently, but I can't make a difference between them from my Linux Host)