I installed Ubuntu Server 10.04 via VirtualBox, yes, the I use virtual machine, cuz I am learning ubuntu. I installed apache webserver by this command:

sude apt-get install apache2

Everything looks okay, no error. Now, how do I test if the apache server is working? Normally in windows OS, after install apache, I go to web browser, point to 127.0.0.1, and the webpage will display "it works". How do I test my ubuntu server web apache?

3 Answers
3

If you want to test your Apache setup from the host machine, you will need to configure your networking in VirtualBox. There is a great tutorial on that here. Then you would point the browser in your host machine to whatever IP address is assigned to the guest.

Hi, your second solution: "connect from the outside world to your VirtualBox", how to achieve that?
–
ubuntukaAug 3 '11 at 18:45

that depends on your network connection... but for quick test you can install miredo on your server and on your client ( it will give both of them ipv6 adress, so you dont have to setup port forwarding ), then run ifconfig | grep "Scope:Global" on your server to see ipv6 adress... and just copy it to your clients webbrowser. In chromium it will look like http://[2001:15c0:****:***::2]
–
DenwerkoAug 3 '11 at 18:53

@ubuntuka The solution described in DLH's answer should get you a nretwork connection between host and guest. Just use guest's IP address.
–
Florian DieschAug 3 '11 at 19:14

Bridged networking - Allow your Guest OS to connect to the network just like another device in the network. (What I normally use)

Internal networking - Not clear.

Host-only networking - Allow connection between host and guests only.

Generic networking - Not clear.

So if you want to test your Ubuntu Server 10.04 in your VirtualBox, you can choose either Bridged Networking or Host-only Networking.

If you are using the Bridged Networking which I have tested, you will have to find out your Guest OS IP address. In desktop mode, it is as simple as clicking (or right-click) the Network Manager -> Connection Information.