I installed VirtualBox on my Windows 7 machine. Through VirtualBox, I installed Ubuntu 9.10 with apache2. I can view http://localhost from Ubuntu, but is there anyway I can view it from my windows machine too? i.e. run the apache server on ubuntu, and view it from windows? I figured it would open a port or something that would be visible to my whole computer regardless of its virtualness, but I guess not. How do I get around this?

link|improve this question

38% accept rate
feedback

3 Answers

Open port 80 in the VM, then go to the IP address of the VM in your browser.

link|improve this answer
how do I open port 80? – Mark Apr 5 '10 at 17:02
I don't actually know Ubuntu well enough to be able to tell you. Take a look under System | Administration. – Ignacio Vazquez-Abrams Apr 5 '10 at 17:04
According to the tutorial I found, I had to do it through the host OS/Windows actually... – Mark Apr 5 '10 at 17:16
feedback

while the vbox is powered down create a secondary network connection of type "host only"

power up your vbox and run "ifconfig" from the command line

the ip address your looking for is in the second paragraph (mine is 192.168.56.101 )

opt: add the following to your windows hosts file 192.168.56.101 ubuntu now yu can go straight to http://ubuntu/

link|improve this answer
feedback

Your Answer

 
or
required, but never shown

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