I have a host system running Fedora 15 and I have a guest system running CentOS 5.5 in VirtualBox.
I did set up a virtualmin install and added port forwarding to the virtual machine. When I forward port 80 on the guest to port 8080 on the host I can access localhost:8080 and it serves me the page. However if I forward port 80 on the guest to port 80 on the host I can not access it.
Since I want to access the sites on the VM from the web and do not want to add a port number when accessing those (by a domain or subdomain that points to my ip) I assume I need to use port 80 here.
I read that people do forward port 80 to the host, so I assume this should be possible.
Output from nmap for host (Fedora):
Nmap scan report for localhost (127.0.0.1) Host is up (0.000078s latency). Not shown: 992 closed ports PORT STATE SERVICE 22/tcp open ssh 25/tcp open smtp 111/tcp open rpcbind 631/tcp open ipp 2121/tcp open ccproxy-ftp 2222/tcp open EtherNet/IP-1 11111/tcp open vce Device type: general purpose Running: Linux 2.6.X OS details: Linux 2.6.19 - 2.6.36
So port 80 is not taken by the host, which might be a good sign, local processes don't intervene or is it a bad sign, should the port be open in order to function to server data from the guest?
I am using the P-2601HN-F1 router which works correctly (managed to show the output from the web with a local apache server)
In the network Tab of the VM it says: Attached to: NAT. And for the port forwarding I have defined forwards of which:
HOST PORT / GUEST PORT 80 / 80 tcp 2121 / 21 tcp 2222 / 22 tcp 11111 / 10000 tcp
Not that when I change 80 / 80 tcp to 8080 / 80 tcp then I can access it from http://localhost:8080/.
What am I doing wrong / how can achieve this (access on port 80)?