Getting all records for a hostname in /etc/hosts

Probably a bit of an edge case here, but is there an easy way, from the command line, to get all the records for a hostname resolved via /etc/hosts? For example, getent hosts <host> returns the first record, but there may be more than one record for that name in /etc/hosts. The linux getent(1) command has a special database type of 'ahosts' to get all the records, but I don't see an equivalent in FreeBSD.

Background: I'm using /etc/hosts to configure jail IPs using the ip_hostname option in jail.conf. A way to test name resolution for this case would be very handy.
 
Back
Top