Skip to content

Google DNS, OpenDNS and CDN performance

Published on Feb 16 2012

This is the first in a series of three blog posts.

Google Public DNS and OpenDNS are free DNS resolvers that anybody can use on their computer to resolve a hostname ( to an IP address. Google and OpenDNS promise faster and safer DNS lookups and each serves billions of DNS queries every month.

It has been blogged about before that using these DNS resolvers can cause (big) problems when requesting content from CDNs, because some CDNs detect the user's location wrong and serve content from far-away servers.

We decided to investigate if this problem still exists, and if so how big the problem is. We will answer the following 3 questions:

  1. How many people use Google DNS and OpenDNS?
  2. Which CDNs support edns client subnet?
  3. Is real-world CDN performance different for Google DNS and OpenDNS users?

We answer the first question in this article and the others in separate blog posts, which we hope to publish tomorrow and the day after tomorrow. Please be patient. The good stuff on CDN performance is coming ...

How many people use Google DNS and OpenDNS?

Update (Oct 17, 2012): we computed all the numbers again, after discovering we did not mark AS30607 as OpenDNS. We apologize for this mistake.

At Turbobytes, we continuously monitor the performance of CDNs to fuel our multi-CDN platform. We built a custom RUM solution for this and many websites have added our JavaScript snippet to their pages. When thinking about testing usage of Google DNS and OpenDNS and the impact on CDN performance, Sajal came up with a way to leverage our RUM user base, with the big benefit of getting a lot of measurements. Let's look at the test results first and then you can read about our test methodology.


Between Oct 3 and Oct 15 2012 we ran over 3.5 million tests from around the world.
The key findings are:

  • 8.04% of users worldwide use either Google DNS or OpenDNS
  • Google DNS has 2.5 times more users than OpenDNS
  • Popularity of these DNS services varies greatly by country
  • Google DNS is very popular in Vietnam, Indonesia, Turkey and Egypt

The chart below shows the 'market share' of the two DNS services in 10 large countries. China is not shown because we had a relatively small number of measurements from China.

Google DNS and OpenDNS market share Oct 2012

Just by looking at these 10 countries you can see the big differences. Canada is the only country where OpenDNS is used by more people than Google DNS. United Kingdom and Australia are pretty similar, usage of bot public DNS services is relatively low in France, but high in Russia and Brazil. In India and especially Indonesia, both DNS services are used by a lot of people. View the table below to gain insight in Google Public DNS and OpenDNS usage/popularity for the 80 countries and states (US/CA) that we received most test results from.

Country/stateCountUsing OpenDNSUsing Google DNSUsing OpenDNS or Google
All data3,541,20881,2922.30%203,3195.74%284,6118.04%
United States920,30724,1452.62%30,5933.32%54,7385.95%
United States (California)262,2105,6882.17%9,5273.63%15,2155.80%
United Kingdom147,6263,1102.11%5,7893.92%8,8996.03%
Canada (Ontario)86,1693,3423.88%2,9373.41%6,2797.29%
United States (Texas)69,4941,6502.37%1,8952.73%3,5455.10%
United States (New York)61,4821,6472.68%1,8613.03%3,5085.71%

We will continue our DNS tests and likely publish an update to this blog post in the future.

Test methodology

Sajal used the following setup:

  • RUM.js. Added a few lines of code to this JS file, to send request to a random hostname for which our DNS server is the authoritative name server
  • HTTP server (Nginx). Returns a 204 response to all requests. Uploads logfiles to S3 every hour
  • Node.js based DNS server. Uses the excellent native-dns library. Gives same response with very low TTL to all queries. Echoes back the client-subnet (if any) with scope netmask of 32. Uploads logfiles to S3 every hour
  • Desktop. Offline analysis after downloading logfiles from S3. Using MongoDB for storage, Disco for parallel processing

The HTTP server and DNS server ran on an EC2 instance in US-East.

DNS test procedure

The first step is to get the user's IP and their resolver's IP

  1. Generate a uuid in JavaScript using random numbers and current timestamp
  2. User tries to access http://<uuid>
  3. User asks for the IP of <uuid> from the resolver configured in the user's machine
  4. The configured resolver asks our authoritative DNS server. We log the IP of resolver and the uuid here. Also log EDNS parameters if available
  5. User finally establishes HTTP connection to <uuid> We log the IP of the user and the uuid
  6. Match users IP to resolver IP where uuid matches

Each user's IP was considered only once a day !

Step two is to match ASNs, country, etc.
We detected the ASN of the DNS resolver's IP and user's IP and then detected geo location of the user, geo location of the dns server, whether edns was used or not, the edns paramaters that came with the query and user agent. If the ASN matched Google Public DNS or OpenDNS, we used information on these webpages (Google DNS server locations, OpenDNS network map) to figure out its location.