added function that pings for ip addresses until they are available