I am running OpenVPN Access Server and I'd like to push a route to every client on connection that is the equivalent of:
sudo ip route add 172.17.0.0/24 via 172.27.232.1
Where should I go to set this up (preferably in the OpenVPN AS Web UI)?
Unix & Linux Stack Exchange is a question and answer site for users of Linux, FreeBSD and other Un*x-like operating systems. It only takes a minute to sign up.
Sign up to join this communityI believe you need to add the following to your server's openvpn.conf
file:
push "route 172.17.0.0 255.255.255.0 172.27.232.1"
the restart things.
The default config file has a similar line commented out with a ;
as an example.
From the command line, you would simply add the following to your /etc/openvpn/server.conf:
push "route 172.17.0.0 255.255.255.0 172.27.232.1 1"
The configuration is described in more detail here.
But, to answer question about making the change through the OpenVPN AS WebUI, I think you will have use the "Yes, using routing (advanced)" option shown in this document and then make further configuration. As the document notes, the machines you have on the 172.17.0.0/24
subnet will have to have a route back to the VPN clients, otherwise they will send that traffic back to their default gateway.