Add allowed hosts to /etc/hosts and define these firewall rules to block any outgoing DNS queries on standard UDP port 53:
~# iptables -I OUTPUT -p udp --dport 53 -j REJECT
* May also use less rude DROP target in place of REJECT
To be on safe side also block TCP port:
~# iptables -I OUTPUT -p tcp --dport 53 -j REJECT
iptables is part of stock Android ...