DPattee
I thought everything was working, but there was n issue that didn't cause any problems for 3 months and now all of a sudden it is causing trouble multiple times a day. Not sure exactly what perturbed things, but I guess there is a base problem with my setup the entire time that needs to be addressed...
- I'm using ASUS routers with their default/official firmware (not a self-flashed dd-wrt/tomato/etc).
-- Since I'm using the ASUS router firmware, my config is done through a GUI. I'm not sure how to get the raw text config from it.
- I have two locations that I'm trying to link
-- Location A will be the primary site with the router set as an OpenVPN server, Location B will be the secondary site with its router set as an auto-connecting OpenVPN client
- There are devices that are always going to be at location A, devices that will always be at location B, and devices that travel between the two (laptops, iPads, etc)
-- The two locations are far, when a device leaves one location it will be several hours minimum before it gets to the other location
-- Devices that stay put have static dhcp assignments
- Both locations have dynamic public IP addresses, but they change rarely, and I have a DynDNS setup that keeps up no problem
- I use TAP because I need various Mac OS X features to work (time machine backups, automatic drive mounting, and other bonjour-related things don't work over PPTP or OpenVPN TUN)
- I don't need or want all internet traffic to be routed through the primary site. I only want relevant lan traffic to go over the vpn
- The VPN is connected most of the time (the secondary router will automatically re-connect if the link ever fails) but I don't want the secondary site to be fully dependent on the primary one (if there is a power failure at the primary site for example)
The current configuration is:
- Primary router is 10.0.3.1 and has DHCP serving 10.0.3.100-199
- Secondary router is 10.0.3.2 and has DHCP serving 10.0.3.2-99
-Primary's OpenVPN server settings are all Asus's defaults, except for having switched it from TUN to TAP
--TAP, UDP, 1194, TLS, 'direct client to redirect internet traffic = no', 'respond to DNS = no', ...
All the things I want to work, work. The routers' vpn connection gets established automatically. GeoIP & speed tests at each location show traffic coming from their correct area and at their full speeds. All the 'LAN-related stuff' works in apps (all the Mac magic performs, two remote TiVos can stream to each other, etc)
Things only break down when a device gets served an address from the DHCP server at the remote location. This only seems to happen with devices physically at the primary location being served an address from the secondary router's DHCP server - but that could just be a coincidence because there are many more devices at the primary location, so statistics...
The DHCP address would be fine (same subnet, using the same public DNS servers, etc) if it weren't for the Default Gateway getting set. Occasionally those devices in the primary location get their gateway set to 10.0.3.2, at which point they can't connect to anything until I go to the device and release/renew its DHCP lease and get lucky for it to be answered by the local DHCP server (which is a pain for me and terrible if a client has to do it), or I set the device to not use DHCP at all and just static everything (which is obviously not good).