I use the GL.iNet GL-MT300N-V2 with firmware 3.212-0407 in router mode.
Currently, I reside in a hotel with LAN and Wifi connection, and for the better or worse, the MT300N is connected to both, thus having two gateways.
I have configured an OpenVPN client that connects to my OpenVPN server at home. Then, I connect to the MT300N via Wifi from my laptop. This works except for one thing: I cannot connect to all the other services on my home server, e.g. the Web server. In other words, the public IP address of my home server is not routed properly. A traceroute yields:
traceroute to XXXXXX.org (XXX.XXX.XXX.XXX), 30 hops max, 60 byte packets
1 console.gl-inet.com (192.168.8.1) 1.259 ms 1.634 ms 2.117 ms
2 console.gl-inet.com (192.168.8.1) 2.083 ms 2.594 ms 2.741 ms
I’m no expert at traceroute but this seems to be a loop.
Note that when I use the laptop to connect to my home VPN, I’ve never experienced such problems.
What I already tried in the OVPN file uploaded to the mini router:
- Setting “
route <public IP> 100.115.0.1
”, where the latter is the router’s gateway. - Setting “
redirect-gateway
” (naked and with thedef1
option). - Setting “
nobind
”
My OVPN file looks like this:
client
dev tun
remote XXXXXX.org 443 tcp
(Then, the key and certificate follow in-file.)
And the server configuration is:
server 192.168.255.0 255.255.255.0
verb 3
key /etc/openvpn/pki/private/vpn.bronger.org.key
ca /etc/openvpn/pki/ca.crt
cert /etc/openvpn/pki/issued/vpn.bronger.org.crt
dh /etc/openvpn/pki/dh.pem
key-direction 0
keepalive 10 60
persist-key
persist-tun
duplicate-cn
mssfix 1200
proto tcp
# Rely on Docker to do port mapping, internally always 1194
port 1194
dev tun0
status /tmp/openvpn-status.log
user nobody
group nogroup
comp-lzo no
### Route Configurations Below
route 192.168.254.0 255.255.255.0
### Push Configurations Below
#push "block-outside-dns" # Not supported by my client yet
#push "route 192.168.178.0 255.255.255.0 vpn_gateway"
push "dhcp-option DNS 192.168.178.30"
push "comp-lzo no"
(Sorry that some things are irrelevant; I wanted to be sure to not miss anything.)