Server Fault is a question and answer site for system and network administrators. 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 have an OpenL2TP VPN instance running to a company providing me with connections to cellphone modems in the private IP range. This server is on the same private network as three other web servers that need to be able to send traffic to the same range via the VPN connection on this one machine.

I created the route:

sudo route add -net netmask gw [private vpn server local address] dev eth0

But that doesn't route the traffic once it gets to the vpn server, or at least it doesn't route it back.

How do I route this traffic two-way from the three servers to the VPN server?


share|improve this question
up vote 2 down vote accepted

The devices on the network may only know how to return traffic to the host with the VPN address, you need to NAT traffic from the web servers to the VPN interface address such that the devices return the traffic to the VPN end point which will then send it to your web servers.

With the present setup the devices could be responding to the traffic via their default gateways which then gets dropped.

share|improve this answer

A bit fuzzy on the network layout (need another coffee), but you likely need to add a static route in the Web server's default gateway to route traffic to your VPN gateway, or add static routes to each Web server to accomplish the same thing.

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.