added remote_ip lookup and addition to /etc/hosts