LinuxQuestions.org

LinuxQuestions.org (/questions/)
-   Linux - Networking (https://www.linuxquestions.org/questions/linux-networking-3/)
-   -   open vpn not forwarding to lan (https://www.linuxquestions.org/questions/linux-networking-3/open-vpn-not-forwarding-to-lan-4175450033/)

Gil@LQ 02-13-2013 02:42 PM

open vpn not forwarding to lan
 
hi ,

i installed openvpn, on centos 6.3. Working fine, i can also can connect from home, thing is my local ip is 192.168.80.1 which is eth0, eth1 is public ip, i configured 10.0.0.0 255.255.255.0 in /etc/openvpn/server.conf for remote clients. when i connect to vpn server, my laptop been assigned some ip like 10.0.0.6, it's also pinging to 10.0.0.1 which is tun0 , but if i try to ping 192.168.20.12 not pinging, my laptop is not comunicating with other interface of vpn server other than tun0 (10.0.0.1), if it's not possible vpn server is of no use since can't access my network 192.168.80.0

i enabled ip forwarding in /etc/sysctl and configure MASQURADE as

Quote:

iptables -t nat -A POSTROUTING -j MASQUERADE
But thing i noticed was, i configured vpn ip(192.168.80.1) as gateway for one of the pc in network(192.168.80.9)and tried to ping 10.0.0.1 (tun0) after MASQUERADE, it's pinging and also pinging my laptop 10.0.0.6 which is connected in vpn from home. but my laptop 10.0.0.6 can't ping 192.168.80.9.

Quote:

i suspect vpn client is unable to communicate other clients via vpn's local ip 192.168.80.1
please tell me how to configure my vpn server so that vpn clients take it's local ip as gateway
pleae help me

thank you very much.

smallpond 02-14-2013 08:56 AM

Sounds like the vpn and server are ok. How are you setting the route table on your PC so it knows to go through the VPN to get to 192.168.80.x? Are you pushing the route from openvpn?

scheidel21 02-14-2013 09:18 AM

Is the Client-client option enabled in the OpenVPN configuration, I've had this cause issues in communication between nodes other than the server.

Gil@LQ 02-19-2013 08:08 AM

hi

i thank you all for your time, i don't know where did my conf, wrong finally but i did below steps from the post.

Quote:

push "route 192.168.80.254 255.255.255.0"
push "redirect-gateway def1 bypass-dhcp"
http://geekinlinux.blogspot.in/2013/...g-openvpn.html

thank you.


All times are GMT -5. The time now is 05:52 PM.