Unix & Linux Stack Exchange is a question and answer site for users of Linux, FreeBSD and other Un*x-like operating systems. Join them; it only takes a minute:

Sign up
Here's how it works:
  1. Anybody can ask a question
  2. Anybody can answer
  3. The best answers are voted up and rise to the top

I've got only one WAN IP address bound to KVM host system and multiple VM's with internal IP's, say, On the other hand I have multiple domain names bound to host system WAN IP.

The problem is that I need to somehow route each request to specific VM based on domain name.

Is it possible to solve this issue without buying lots of WAN IP's?

share|improve this question

You could install nginx or Squid on a VM and pass all external traffic to that VM. They are both capable of forwarding traffic by domain name.

share|improve this answer

You can use apache web server to do that.It is called reverse proxying.

Simply setup name based virtual hosts and inside setup ProxyPass and ProxyPassReverse to forward traffic to appropriate VM behing.

Nice article about it here

More info can be found here or here or here

share|improve this answer

Your Answer


By posting your answer, you agree to the privacy policy and terms of service.

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