Comment 3 for bug 1741277

Revision history for this message
Scott Moser (smoser) wrote :

fwiw, its sudo that is causing the roundtrip.
you can certainly come up with reasons to pay a round trip. the infrastructure then can make changes and each system magically picks them up. its the reason we don't ship /etc/hosts files around anymore.

all that said, this issue can definitely be handled better than it is. A couple options:

a.) cloud-init could use manage_etc_hosts=localhost on platforms it knows will not provide dns lookup (this though coudl change, and probably should change on lxd, and then cloud-init has to be updated to accomodate... it gets tricky to service that logic if it ever changes as customers will use different versions of lxd).

b.) libnss-myhostname might be able to help. that is mentioned by xnox in a related bug bug 1730744.

More conversation took place in IRC at https://irclogs.ubuntu.com/2018/01/04/%23ubuntu-server.html#t14:57