Weird routing problem

Need help configuring your VPN? Just post here and you'll get that help.

Moderators: TinCanTech, TinCanTech, TinCanTech, TinCanTech, TinCanTech, TinCanTech

Forum rules
Please use the [oconf] BB tag for openvpn Configurations. See viewtopic.php?f=30&t=21589 for an example.
Post Reply
maroder
OpenVpn Newbie
Posts: 2
Joined: Mon Jan 09, 2012 8:29 am

Weird routing problem

Post by maroder » Mon Jan 09, 2012 8:53 am

Hello,

Maybe someone can help me solve my problem. I just set up a semi-working OpenVPN-server for my small home network. I can connect but seem to have a problem with the routing.

My setup
  • - OpenVPN-server (192.168.0.6)
    - Router/gateway (192.168.0.1)
    - NAS (192.168.0.5)
The OpenVPN-server and the NAS have 192.168.0.1 configured as gateway.
On the router/gateway (TP-Link Router) I configured a static route from 10.5.5.0/24 to 192.168.0.6

The Problem is, that after conneting successfully I can ping the VPN-server (192.168.0.6/10.5.5.1) and the router/gateway (192.168.0.1), but not the NAS. Weirdly enough, the NAS can ping my connected VPN-client (10.5.5.6) and the VPN-server (10.5.5.1).

As that the static route seems to work the problem must be the routing on the OpenVPN-server.
Can someone give me a hint how to solve this problem?

The VPN-servers configuration

Code: Select all

mode server
proto udp
dev tun
management 127.0.0.1 44000
ca ./keys/ca.crt
cert ./keys/server.crt
key ./keys/server.key
crl-verify crl.pem
dh ./keys/dh1024.pem
server 10.5.5.0 255.255.255.0
ifconfig-pool-persist ipp.txt
keepalive 10 120
comp-lzo
user openvpn
group openvpn
persist-key
persist-tun
status openvpn-status.log
verb 3
push "route 192.168.0.0 255.255.255.0"
push "dhcp-option DNS 192.168.0.6"
The routing table on the OpenVPN-server

Code: Select all

Kernel IP routing table
Destination     Gateway         Genmask         Flags   MSS Window  irtt Iface
10.5.5.2        0.0.0.0         255.255.255.255 UH        0 0          0 tun0
192.168.0.0     0.0.0.0         255.255.255.0   U         0 0          0 eth0
10.5.5.0        10.5.5.2        255.255.255.0   UG        0 0          0 tun0
10.5.5.0        192.168.0.1     255.255.255.0   UG        0 0          0 eth0
0.0.0.0         192.168.0.1     0.0.0.0         UG        0 0          0 eth0
Any help would be greatly appreciated!

Thank you and best regards,
Maroder

User avatar
maikcat
Forum Team
Posts: 4200
Joined: Wed Jan 12, 2011 9:23 am
Location: Athens,Greece
Contact:

Re: Weird routing problem

Post by maikcat » Mon Jan 09, 2012 12:12 pm

did you check if the nas has any type of firewall enabled?

Michael.
Amiga 500 , Zx +2 owner
Long live Dino Dini (Kick off 2 Creator)

Inflammable means flammable? (Dr Nick Riviera,Simsons Season13)

"objects in mirror are losing"

maroder
OpenVpn Newbie
Posts: 2
Joined: Mon Jan 09, 2012 8:29 am

Re: Weird routing problem

Post by maroder » Mon Jan 09, 2012 1:02 pm

Thank you for your quick reply.

I'll check when I get home. But I doubt that an firewall is enabled on this machine, as this is a really simple NAS-Storage (QNAP 209Pro).

One thing I noticed in my routing table of the OpenVPN server.

Code: Select all

10.5.5.0        10.5.5.2        255.255.255.0   UG        0 0          0 tun0
Maybe I'm missing something, but why is 10.5.5.2 in my routing table. Shouldn't that be 10.5.5.1?

Post Reply