0

We just started using New Relic mobile for our iOS app and have been seeing intermittent spikes in network errors. The list of errors contains some self explanatory ones (not connected to internet, time out, connection lost). Right now I am chalking this up to network carriers' mobile internet performance (or lack there of). The one in the list that is harder to explain is cannot find host. Could a device encounter this error if the internet service is unreliable? During these spikes our desktop website (on the same servers) does not exhibit any of the same errors. In general I am wondering how reliable network error data from mobile devices is given that they are on a less reliable connection.

Shawn
  • 1

1 Answers1

1

It is plausible that an unreliable network connection could result in an application reporting cannot find host.

A typical network communication starts with the application performing a DNS lookup. If the device think the network connection is established, but no packets are actually getting through, the application is not going to get any response to the first DNS lookup.

A proper reaction from the application would be to try a few times and then time out with an error message. At this point there is a few possible error conditions that could end up producing the same error message for all the conditions. These conditions are:

  • All packets lost, no reply received
  • An error reply is returned indicating the DNS server cannot be reached
  • The DNS is reached but refuse to handle the request for some reason
  • The DNS server handle the request, but the domain does not exist
  • The DNS server handle the request, but the domain does not have a record of the specified type.

If you had to pick a single error message covering all of the above, it is hard to come up with something more descriptive than cannot find host.

It is important to keep in mind, that if the device has previously performed the DNS lookup, the result may be cached, in which case you would likely see a different error.

If you have access to a device identical to the one producing the error message, you can test each of the above conditions on a network under your own control in order to see which error message is produced.

kasperd
  • 30,455
  • 17
  • 76
  • 124