Hello guys,
I've been trying to setup openvpn in bridge mode for some time now without much success. Here's the setup in short:
1. VPN server with 2 NICs - 1 externally visible eth0 (A.B.C.D) and 1 connected to the LAN eth1 (198.168.77.5).
2. Handful of machines connected to the LAN network (198.168.77.0)
3. Handful of machines that need to be on the same LAN network.
Server config:
mode server
tls-server
port 1194
proto tcp #had to use TCP as UDP is filtered
dev tap0
ca /etc/openvpn/ca.crt
cert /etc/openvpn/server.crt
key /etc/openvpn/server.key
dh /etc/openvpn/dh.pem
tls-auth /etc/openvpn/zzz.key 0
script-security 2
up "/etc/openvpn/up.sh br0 tap0 1500" # used to add tap0 to br0, where br0 is created and bridged to eth1 upon system boot.
down "/etc/openvpn/down.sh br0 tap0"
server-bridge 192.168.77.5 255.255.255.0 192.168.77.100 192.168.77.200 #no machines exist in that IP pool.
ifconfig-pool-persist /etc/openvpn/ipp.txt
client-config-dir /etc/openvpn/ccd
client-to-client
keepalive 10 120
user nobody
group nogroup
persist-key
persist-tun
status /var/log/openvpn-status.log
log-append /var/log/openvpn.log
verb 4
mute 20
comp-lzo
Client config:
client
tls-client
dev tap0
proto tcp
remote A.B.C.D 1194
resolv-retry infinite
nobind
ca ca.crt
cert client1.crt
key client1.key
dh dh.pem
tls-auth zzz.key 1
comp-lzo
persist-tun
persist-key
verb 3
mute 20
I have IP forwarding enabled and IPtables configured to allow the traffic. The trouble I'm facing is related to the vpn clients seeing the machines within the LAN network behind the vpn server. I am able to the VPN and communicating with the VPN server's LAN IP address, but that's as far as I can go. I have no connectivity to the machines in the LAN. I read a number of articles from various sites and couldn't find a solution to my problem anywhere. I was able for some very bizarre reason to make that work somehow by adding "push "route 192.168.77.0 255.255.255.0" into the server config file, but after a reboot I'm still unable to access any of the machines in the LAN. This was supposed to be a fairly straight forward setup, but I'm really stuck with it. Could anyone please let me know what I may be doing wrong?
I have the openvpn server version 2.3.8 running on Ubuntu 14.04.3.