Tools: Let sql query DNS as well for aliases
Currently, sql greps /etc/hosts to determine whether a database has
been replicated to Labs. However, the host aliases there will move to
DNS in the near future (cf. T63897).
This change uses "getent hosts" that queries /etc/hosts and DNS.
Bug: T91733
Change-Id: Id5ff0df3f36057b324e624ca77069372044f7831