Take the 2-minute tour ×
Super User is a question and answer site for computer enthusiasts and power users. It's 100% free, no registration required.

There are some questions regarding this here already but people just dont tell how - like this one http://superuser.com/questions/165572/setting-up-virtual-pc-virtual-box-as-a-web-server. I am trying the same approach. Cant get it working following isntructions...

Can someone help please. Enviroment is zend server ce (already working on guest OS (ubuntu server - newest version) Zend Studio on windows host (win 7)

share|improve this question

1 Answer 1

up vote 1 down vote accepted

There are two networking modes that you need to choose from:

Bridged mode, where the virtual machine is effectively plugged into your router by a wire alongside the connection between the host computer and the router. The guest gets its IP address etc from the router, just like having an extra physical machine, and has access to and is accessable from, the outside world in the same way as a physical machine connected to your router.

The other networking mode that you could use is Host-only. In this case the virtual machine and the (virtual) second network socket on the host are both connected to a router that is built into Virtualbox, so it has its own DHCP server etc. This virtual router has no connection to the outside world so the virtual limited is only able to see and be seen by the outside world via the host machine.

Once you have chosen the network mode you want, you need to be able to find the address of the virtual machine (using ifconfig on the virtual machine will work) and away you go.

share|improve this answer
    
Hang on (and thanks for getting the time to answer... For the first option (bridge) you mean my computer needs to be wired plugged into the router to make it work. Currently my "router" is my wireless modem/router that provide access to my laptop and other stuff like ps3, my wifes computer... So to make the bridge work I would need to be wired? Does the second option (host only) works with a wireless connection? I tried everything - the only that works only half way (guest can ping host and can access internet) is the NAT. For this second option what should be my steps? –  Ronaldo Santana Aug 15 '10 at 21:04
    
By steps I mean: 1 - Set the network option on the VBox settings to HostOnly. 2 - Boot my Ubuntu v-machine 3 - Be happy?? Or do I need to change any configuration? I'm assuming that the /etc/network/interfaces file needs to be set to DHCP since its going to be ïn touch" with the virtual DHCP you mentioned. Do I need to change any windows configuration on the network setting for this to work properly or any windows firewall setting? If so, please let me know how. If this works - will put the link to this answer in every forum I've been on (a lot) during this weekend trying to make this work :) –  Ronaldo Santana Aug 15 '10 at 21:08
    
Wireless is fine - I was just trying to make the point that in bridged mode, the virtual machine uses your real router and appears on your network like a real machine. I use bridged mode myself - it means I can basically ignore whether a machine is a real machine or a virtual machine. –  Neal Aug 16 '10 at 10:56
    
Right - but what more you set. Or you just set the virtual machine network to work as bridge and thats it? install it and it works? I tried the second approach last night - and the first - almost giving up. It just don't work. My modem/router is the DHCP server - it will serve IP from 192.168.2.100 to 115. My laptop gets the 100. The modem itself gets the 192.168.2.1. Is there any different configuration I need to do or the way it is should work? –  Ronaldo Santana Aug 16 '10 at 20:54
    
Hi - I am able to connect now. My zend server is working, mysql, and even a installation of perforce. The thing is, on the network configuration, I had to change to bridge and then change the card name to my wireless one. can ping both ways and everything is working. Thanks –  Ronaldo Santana Aug 17 '10 at 12:41

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.