1

When you set a static IP in iOS and you don't specify a in IP address for DNS, which IP does iOS use to resolve hostnames?

1 Answer 1

3

It doesn't have nor does it assign one. However, it may have have host names/addresses cached so you may still be able to access sites you previously visited. However, once that cache clears, you will only be able to browse by using raw IPs.

5
  • My question is based on some behavior I've watched. If the iPhone is connected to a Wifi network (that doesn't have Internet) with a DNS assigned it won't stream Pandora (for example). Now, if I connect to that same wifi with a static IP without DNS I can stream Pandora while still being connected to the Wifi. How is this possible?
    – Rhyuk
    Mar 23, 2015 at 16:25
  • It sounds correct. That WiFi is giving you DNS values - probably the gateway. But with no DNS, your iPhone has no idea how to get to Pandora.
    – Allan
    Mar 23, 2015 at 16:42
  • 1
    (I tried to edit earlier, but I had to wait...unfortunately I got stuck on a call). anyway.... DHCP WiFi with no Internet has DNS, but it can't resolve anywhere so nothing works. Put in static IP with no DNS and the device will use, what sounds like, your LTE connection. The device will see which connection has the best connection to the Internet and use that one. In your case, no Internet would prevent everything from working. When you put in an IP manually, you leave out DNS so it can't resolve names. It will switch to the connection with DNS. Thus, Pandora works.
    – Allan
    Mar 23, 2015 at 19:26
  • That explains it... now that I understand how it works in Apple, I have to make it work in Android. I have a raspberry Pi that works as an AirPlay receiver. With an iPhone it works because of what you just explained. In the other hand it seems Android forces defaults values and I get stuck with no connection at all :(
    – Rhyuk
    Mar 23, 2015 at 19:38
  • 1
    It should work roughly the same way in Android, but there may be a DNS cache in play as well. A DNS cache stores host info for quicker name resolution. Instead of asking the DNS server "where is www.pandora.com" and waiting for a reply, it say "I know Pandora is at xxx.yyy.zzz. Just go there" But since there is no Internet it can't. Android thinks the Internet works on the WiFi but in reality it doesn't. If you can clear all the settings and cache in the Android, it should work like the Apple.
    – Allan
    Mar 23, 2015 at 19:44

You must log in to answer this question.

Not the answer you're looking for? Browse other questions tagged .