I have a OpenVPN server/client setup where the server resides in country S and the client resides in country C. I have set it up so that the client (ovpn C) is the def gateway for its subnet and all traffic are tunneled to Server (ovpn S) before going out - effectively routing all country C machines' traffic to country S router. I followed the HOWTO guide in openVPN with "push redirect-gateway" etc...Everything works.
Now I would like the reverse to happen also: I'll set ovpn S as its subnet's def gateway and have all traffic routed to C. I am assuming of course, there is no duplicated subnets in the two countr neytworks. I am puzzled about how to do that. Can anybody give me some idea?
Topology is as follow (required fixed size font)
(Subnets 1-10)==(router S)==(ovpn S)==(internet )==(ovpn C)==(router C)==(Subnets 21-30)
| (opvn tunnel) |
(subnet 11) (subnet 12)
Essentially I want to be able to set all machines in subnet 11 to opvn S (just one defgw route, no specific routes) and traffic destined for subnets 21-30 will automatically go through the tunnel, while traffic for subnets 1-10 will go no where... and same for machines in subnet 12: they automatically go to subnets 1-10 through the tunnel but fail to go to subnets 21-30 with defgw set to ovpn C
Can anybody give me some idea how to achieve that?
Thanks!