Take the 2-minute tour ×
Super User is a question and answer site for computer enthusiasts and power users. It's 100% free, no registration required.

I have setup a router as server with openwrt. I have added the Dynamic DNS configuration.(I created an account with noip)

When I try to connect through openvpn (in a free wifi) , I am using my domain as gateway,it shows connected to my vpn but I have no internet access.

From the DNS configuration (noip) I am using

Host type: DNS(A)

Is there something else I must do/check?

I also have already done on router:

config  'rule'
    option 'target' 'ACCEPT'
    option 'dest_port' '1194'
    option 'src' 'wan'
    option 'proto' 'tcpudp'
    option 'family' 'ipv4'

The route -n after connected:

Destination     Gateway         Genmask         Flags Metric Ref    Use Iface
0.0.0.0         192.168.1.254   0.0.0.0         UG    0      0        0 wlan0
79...........   192.168.1.254   255.255.255.255 UGH   0      0        0 wlan0
192.168.1.0     0.0.0.0         255.255.255.0   U     0      0        0 tap0
192.168.1.0     0.0.0.0         255.255.255.0   U     9      0        0 wlan0
192.168.1.2     127.0.0.1       255.255.255.255 UGH   303    0        0 lo
192.168.1.134   127.0.0.1       255.255.255.255 UGH   303    0        0 lo

The 79... is correct(my external ip). I don't know what 192.168.1.254 is though.

My route -n before connecting to vpn:

Kernel IP routing table
Destination     Gateway         Genmask         Flags Metric Ref    Use Iface
0.0.0.0         192.168.1.1     0.0.0.0         UG    0      0        0 wlan0
192.168.1.0     0.0.0.0         255.255.255.0   U     9      0        0 wlan0
192.168.1.2     127.0.0.1       255.255.255.255 UGH   303    0        0 lo
192.168.1.134   127.0.0.1       255.255.255.255 UGH   303    0        0 lo

192.168.1.1 is routers ip.

I also tried to put in gateway port (at optional settings at network manager)'1194' but this doesn't work either.

UPDATE:

Also , I noticed that resolv.conf before connecting to vpn is:

domain lan
nameserver 192.168.1.1

and when connected:

nameserver 192.168.1.254

Is that right? I tried to put

nameserver myhostname ,but still the same.

share|improve this question
    
after connecting, what is the output of "route -n" on the vpn client ? –  aseaudi Jan 10 at 22:30
    
@aseaudi:Hello,I updated my post.I think I must find a way to inport the port 1194 to network manager.. –  George Jan 11 at 10:16
    
1. after you connect to your router, can you ping the lan hosts behind your router? –  aseaudi Jan 11 at 13:28
    
2. your default route is pointing to your vpn server router, remove it and add another default route to the wifi gateway instead, also try to use another subnet for your vpn i.e. 192.168.10.0/24. –  aseaudi Jan 11 at 13:29
    
@aseaudi:For your first question I can't test it because I have 1 desktop and it can't access signal.The laptop ok.For the second question can you please give write me the instructions?Because I am not sure..You mean "route del 192.168.1.254" and "route add 192.168.1.1." ,while I am connected to vpn? –  George Jan 11 at 13:55

1 Answer 1

up vote 1 down vote accepted

Try to assign a different subnet for the vpn.

For example set the ip address of the vpn server to 10.10.10.1 and vpn client to 10.10.10.2.

On the router, there is a file /etc/config/openvpn:

option 'server_bridge' '10.10.10.1 255.255.255.0 10.10.10.2 10.10.10.10'
share|improve this answer

Your Answer

 
discard

By posting your answer, you agree to the privacy policy and terms of service.

Not the answer you're looking for? Browse other questions tagged or ask your own question.