access a virtualbox guest through the network
By JS on Jan 19, 2009
[A quick update - in V2.2.x, we can use "Bridge" option in the network setting to access the VM from outside world, which is familiar to VMWare users. May 31]
On virtualbox, the default network setting of the VM is NAT. It's certainly the easiest way to get the network up and work - you don't need to touch anything, just use the default setting. But you need to do some extra configuration when you want to access services running on the guest(VM), which is not that straightforward and convenient. You may refer to the manual about how to set up "port forwarding". It's basically to ask the host to listen on a user defined port and forward incoming requests to the default service port on the guest.
You may find "host interface networking" setting is more convenient. In this case, the guest will be assigned an IP address in the same subnet of the host. You can access the gust's services just like visit an ordinary host on the network. You may even redirect the guest's display to other machines if you like. Besides, you also get superior network performance comparing to NAT.