Take the 2-minute tour ×
Ask Ubuntu is a question and answer site for Ubuntu users and developers. It's 100% free, no registration required.

I'm running Windows XP on a virtual machine (Orace VirtualBox 4.0.8) on a home server and I want to be able to connect to it from outside the network. I have the domain thanks to dyndns.com which points to the computer and the router is port-forwarded to the server computer. But am I supposed to forward to the server or the virtual machine's IP? Now when I try to connect I get an error: failed to connect.

And how does these authentication methods work: null, external, guest?

share|improve this question

4 Answers 4

up vote 5 down vote accepted

To connect to the services, you'll have to have a address on the local area network and not on a private "bridged" interface for the virtual machine.

  • Open Virtual Box
  • shutdown the Windows virtual machine if it's running
  • right-click on the virtual machine and select settings
  • Select Network and for Attached to: select Bridged Adaptor

Your virtual host should now have an address from the main network. Forward the ports to this address. And probably configure an appropriate static address in Windows.

share|improve this answer
    
Just to add, in general, you need a wired connection to the router for bridged mose. –  Journeyman Geek Jun 26 '12 at 0:16

Right click on your virtual machine and click settings then go to networks tab and then change the Attached to: setting to Bridged Adapter default is NAT.
Then start your virtual machine and you have an ip reference to the virtual machine from your network so just install vnc server on the vm like ultravnc and you're good.

share|improve this answer

It is not clear what connect means here. But if you are trying to connect to your VM using Remote Desktop then you have to forward the 3389 port on you router to the host ip (where host is the computer running the virtual machine, not the one running on the VM).

You will also need to have installed the Oracle Extension Pack and have enabled RDP in the Virtual Machine settings.

enter image description here

Sorry for the spanish screenshot, I hope that you find the place in your own language.

About the authentication:

  • None means that there is no authentication, the system will let you connect the same way that a local screen, i.e. it will only ask for a password if you are not logged or you had blocked the screen.

  • Extrenal uses some external method to authenticate. In a linux host that means that you will need to use a PAM server. Not really useful for personal use. One note: you can use this to hook into your own authentication lib, which is really geeky.

  • Guest uses your guest authentication system. If you are running a windows guest, that means that it will always ask you for your windows user and password to let you log in. This is the easiest way, but you will need to have the Guest Additions running on your guest to be able to use it.

You can find much more info in the user manual.

share|improve this answer
    
Thanks for the detailed response but I can still not make it work. I can't find any detailed tutorials on the issue. Am I supposed to assign the guest with it's own ip (Network = "bridged adaptor") or just go with the "NAT" option? With the server running, should I connect to the guest IP or the host IP? –  Niklas Jun 13 '11 at 15:55
    
It should work with any network setup, you should connect to the guest IP. –  Javier Rivera Jun 13 '11 at 16:16

If the virtual machine has an IP from the local network, you can connect via Samba, WWW, or rdesktop

If the virtual machine has an IP of the host's internal "Default" network, e.g., 192.168.122.x, you'll only be able to connect via VNC.

To connect via VNC, add new graphics hardware to the VM in Virtual Machine Manager, telling it to listen on all public interfaces. You can then forward a port from your router to the host's IP address, with the port listed in virt-manager, usually something like 5901.

-Eric

share|improve this answer
    
Downvote, sorry but this is wrong. He is using VirtualBox and you are answering like he is using KVM. This is going to confuse the user. –  Javier Rivera Jun 2 '11 at 7:17
1  
Good point! Missed that part completely. –  Eric Jun 2 '11 at 10:53

Your Answer

 
discard

By posting your answer, you agree to the privacy policy and terms of service.

Not the answer you're looking for? Browse other questions tagged or ask your own question.