Page 1 of 1
Routing request from VPN client to an internal server.
Posted: Tue Feb 22, 2011 9:42 am
by briansito
Hi All,
I am trying to set up the scenario below and would truly appreciate some help.
I have OpenVPN server with 'tun' mode running. Anyone connects to this vpn server is assigned a 10.8… IP
Behind my router there is a server which has a 192.168.. IP.
How would I be able to route requests from a client connected with 10.8.. IP to the internal server?
Thanks,
Re: Routing request from VPN client to an internal server.
Posted: Tue Feb 22, 2011 10:26 am
by maikcat
hi there,
please post your server config and we tell you what to add
cheers,
michael.
Re: Routing request from VPN client to an internal server.
Posted: Fri Feb 25, 2011 4:51 am
by briansito
Hi Michael..
This is my server config:
-------------------------------------
server 10.8.0.0 255.255.255.0
proto udp
port 10201
dev tun22
comp-lzo adaptive
keepalive 15 60
verb 3
push "route 192.168.0.0 255.255.255.0"
push "redirect-gateway def1"
ca ca.crt
dh dh.pem
cert server.crt
key server.key
status-version 2
status status
-----------------------------------------
As you can see I enabled pushing LAN to clients, and I'm directing clients internet traffic through my server.
Thanks,
Re: Routing request from VPN client to an internal server.
Posted: Fri Feb 25, 2011 5:04 am
by briansito
Also one more thing to note:
The requests from the client come on a specific port -say 15050- which the internal server is listening on.
Re: Routing request from VPN client to an internal server.
Posted: Fri Feb 25, 2011 8:01 am
by maikcat
hi briansito,
first
push "redirect-gateway def1"
is not nessesary to use,
has your openvpn server ip forward enabled?
which OS you use?
if you type netstat -nr on your client do you see tha route that server sends?
if you ping openvpn server lan ip ,is it responds?
is your server runs any type of software firewall?
cheers,
michael.