I'm looking for a way to access multiple servers sharing a single static ip by using different subdomains. As a forewarning, I've never gotten into network configuration before, so my knowledge of appropriate terminology is limited.
Right now I have 3 servers running ubuntu 11.10 sitting behind a switch. I would like to access them as server1.example.com, server2.example.com, and server3.example.com. When all 3 were configured with the same static IP, only one machine held an internet connection. So I spent a lot of time experimenting in /etc/network/interfaces, which was probably a big mistake, before I tried to configure iptables following this guide.
I can't figure out where to start or even what to Google. Maybe I need a different hardware configuration, currently each machine has a single nic, though I can find network cards if necessary. In addition to the switch, I also have an old wrt54g router.
I would predominantly like HTTP access to them, but SSH is important as well.