Thanks again, Josh!
This should work fine. Do you see the route being pushed in the server logs, and picked up by the client? Try using --verb 4 at both ends and look for the PUSH_REPLY. If the client has an error adding a route, it will list it in the log output as well.
If I exclude "redirect-gateway def1", I see in the server log:
SENT CONTROL [svenfried-mobile]: 'PUSH_REPLY,persist-tun,topology subnet,explicit-exit-notify 2,ping 30,ping-restart 90,route-gateway 10.1.101.1,route 10.1.0.0 255.255.0.0,route 10.2.0.0 255.255.0.0,route 10.3.0.0 255.255.0.0,ifconfig 10.1.101.15 255.255.255.0' (status=1)
The routes are shown in the phone's OpenVPN log file and are successfully set on the Android phone (I verified by typing "ip route" on the phone), but of course I miss the two "default gateway override" routes.
If I add "redirect-gateway def1", I see in the server log:
SENT CONTROL [svenfried-mobile]: 'PUSH_REPLY,persist-tun,topology subnet,explicit-exit-notify 2,ping 30,ping-restart 90,route-gateway 10.1.101.1,route 10.1.0.0 255.255.0.0,route 10.2.0.0 255.255.0.0,route 10.3.0.0 255.255.0.0,redirect-gateway def1,ifconfig 10.1.101.15 255.255.255.0' (status=1)
The Android phone still shows the routes in it's OpenVPN log file, but does not set them. As requested, it sets the two gateway overriding rules.
In short words: the routes are always shown in the server's and the client's logfile, but only applied if "redirect-gateway def1" is NOT pushed.
So I thought that this may be an Android related problem, but I get the same behaviour on my iPad with OpenVPN.
I have no routing errors in the client's logs. I double-checked it.
Do you have any further ideas on this?
Thanks a lot!
S.