Thoughts for the use of DNS in dvc.
Suggestion:
(1) Pick a DNS name that will be the root name used by users & the dvc client for resolving seed nodes (long standing core dvc nodes that can help bootstrap new dvc nodes).
(2) Use a DNS provides that's dev friendly, supports round-robin (RR) DNS entries and ideally already has (or plans to implement geoDNS) and under dvc "admin" control. You don't want to use DDNS (Dynamic DNS) for security reasons and getting into the whole IPSEC DNS is a can of worms.
Why:
Simpler bootstrapping for new & existing users.
Simpler management - host IP addresses will change over time (hosts go down, get moved, etc) - currently this requires a code change.
(2) allows for the load to be distributed & using geoDNS allows for locally served updates - providing a quicker catchup & bootstrap time.
How:
RR DNS entries are DNS A records that map from a hostname to an IP address.
The existing dvc config file can be used with the DNS entries - using addnode one or more times using the dns name from (1)
The dvc client code can be updated to take advantage of the new scheme in a more intelligent way.
In this case - the code does a DNS lookup for all records using (1) - resulting in a number of DNS A records. Each of these is then used the same way addnode currently works. You can see an example of this using nslookup & using "dvc.public.txn.co.in" where you'll see 2 records returned.
In addition - as it goes through each returned DNS A record:
(a) it checks you have an IP from the lookup (making sure you have an A record & node something else like a cname)
(b) the IP is valid & the host is responding - it records the lookup & the time the lookup happened
(c) every n minutes (driven by the config file or the cli - ala devcoind dns-refresh) it repeats the cycle. This allows long standing nodes to refresh & reload these addresses without restarting the daemon.