adding error checking when no host file or hosts definition is provided