Can OpenVPN handle the situation where both ends of the connection are dynamic?
Yes. A prerequiste of this method is that you subscribe to a service such as dyndns.org that lets you conveniently point an internet domain name to a dynamic address (or you can do it yourself if you have control over a DNS server that exists on a machine having a static IP address). The crux of this method is in the ‘timeouts’ section of the config file below, or more specifically the ‘ping’ and ‘ping-restart’ options. Basically, if for whatever reason, OpenVPN doesn’t receive a ping from its peer during a 300 second period (as would happen if its peer changed addresses), it will restart. When it restarts, it will re-resolve myremote.mydomain.com to get the new IP address. This method assumes that you are using a dynamic DNS service that lets you immediately update your domain name with your current dynamic address. Using this technique, OpenVPN will essentially “follow” a dynamic DNS address as it changes.