Server-side routing
This recipe will demonstrate how to set up server-side routing in client or server mode. With this setup, the OpenVPN client will be able to reach all the machines behind the OpenVPN server.
Compared to the previous recipe, this recipe contains extra settings that are often used in production environments, as well as OpenVPN 2.1-specific features to make use of linear
addresses (topology subnet
).
The configuration files used in this recipe are useful building blocks for other recipes throughout this book, hence, they are named as basic-udp-server.conf
, basic-udp-client.conf
, and so on.
Getting ready
We use the following network layout here:
This recipe uses the PKI files created in the first recipe of this chapter. Install OpenVPN 2.1 on two computers. For this recipe, the server computer was running CentOS 5 Linux and OpenVPN 2.1.1 and the client was running Fedora 13 Linux and OpenVPN 2.1.1.
How to do it...
Create the server configuration file:
proto udp port 1194 dev tun server...