wannabenerd78 I tried to setup openvpn to run a client (connecting to some vpn Provider via a TAP interface) and a server (providing connectivity over a TUN) interface on the same machine. Each configuration on it's own works fine. But as soon as I start the client config (connecting to the external Vpn Provider) I do not have any chance to connect to the device via VPN Please find the configuration files below: client -config : To connect to my external VPN Provider client dev tap proto udp local 192.168.2.X ; Cert ca /etc/openvpn/keys/ca.crt ns-cert-type server cipher BF-CBC #Blowfish ;Vpn server remote-random remote host.vpnprovider.com 1194 remote host.vpnprovider.com 1195 ;Auth auth-user-pass /etc/openvpn/credentials.sec persist-key persist-tun ; Logging comp-lzo verb 1 server- config : Allows me to connect to my box while I am on the road dev tun0 proto tcp-server ifconfig 10.9.8.1 10.9.8.2 local 192.168.2.38 port 1193 secret /etc/openvpn/static.key comp-lzo keepalive 10 60 ping-timer-rem persist-tun persist-key push "route 192.168.2.0 255.255.255.0" user nobody group nobody I guess it is kind of a routing problem. Without any connection my routing tables looks very unspectacular Kernel-IP-Routentabelle Ziel Router Genmask Flags Metric Ref Use Iface 192.168.2.0 0.0.0.0 255.255.255.0 U 0 0 0 eth0 0.0.0.0 192.168.2.1 0.0.0.0 UG 100 0 0 eth0 Connecting to the VPN Provider the routing tables changes to Kernel-IP-Routentabelle Ziel Router Genmask Flags Metric Ref Use Iface 178.73.212.234 192.168.2.1 255.255.255.255 UGH 0 0 0 eth0 192.168.2.0 0.0.0.0 255.255.255.0 U 0 0 0 eth0 178.73.218.0 0.0.0.0 255.255.255.0 U 0 0 0 tap0 0.0.0.0 178.73.218.1 128.0.0.0 UG 0 0 0 tap0 128.0.0.0 178.73.218.1 128.0.0.0 UG 0 0 0 tap0 0.0.0.0 192.168.2.1 0.0.0.0 UG 100 0 0 eth0 Only starting my openvpn server config the routing table looks like this Kernel-IP-Routentabelle Ziel Router Genmask Flags Metric Ref Use Iface 10.9.8.2 0.0.0.0 255.255.255.255 UH 0 0 0 tun0 192.168.2.0 0.0.0.0 255.255.255.0 U 0 0 0 eth0 0.0.0.0 192.168.2.1 0.0.0.0 UG 100 0 0 eth0 Running both, client and server the routing tables looks like this Kernel-IP-Routentabelle Ziel Router Genmask Flags Metric Ref Use Iface 178.73.212.233 192.168.2.1 255.255.255.255 UGH 0 0 0 eth0 10.9.8.2 0.0.0.0 255.255.255.255 UH 0 0 0 tun0 192.168.2.0 0.0.0.0 255.255.255.0 U 0 0 0 eth0 178.73.217.0 0.0.0.0 255.255.255.0 U 0 0 0 tap0 169.254.0.0 0.0.0.0 255.255.0.0 U 1000 0 0 eth0 0.0.0.0 178.73.217.1 128.0.0.0 UG 0 0 0 tap0 128.0.0.0 178.73.217.1 128.0.0.0 UG 0 0 0 tap0 0.0.0.0 192.168.2.1 0.0.0.0 UG 100 0 0 eth0 0.0.0.0 192.168.2.1 0.0.0.0 UG 100 0 0 eth0 If I delete a route with: route del -net 0.0.0.0 netmask 128.0.0.0 dev tap0 I can connect to my server, but my outgoing connection to my VPN- Provider is broken (of course). Can anyone helpt me with this? Is it possbile to have such a setup at all? Do I need to setup my server with a TAN interface instead? Any help would be really apreciated.
janjust this is definitely a routing issue, but you may need an openvpn statement to fix it; your routing tables look a bit funny, please post the output of 'ip route show' for all 3 cases in a block.
Mimiko Read this topic for some clue https://forums.openvpn.net/topic7175.html. The second post may help you.