automatically retrieve ip address