## Monday, January 12, 2009

### Google searches, energy cost, carbon footprint, and cups of tea

A friend asked me to confirm or deny the assertion (Harvard/BBC) that two Google searches on a desktop computer produces 14g of CO2, which is the roughly the equivalent of boiling an electric kettle.
• ``US physicist Alex Wissner-Gross claims that a typical Google search on a desktop computer produces about 7g CO2.
• ``However, these figures were disputed by Google, who say a typical search produced only 0.2g of carbon dioxide.''

My own rough back of envelope guess came out in between Wissner-Gross's assertion and Google's...

Here's how I worked it out:
2. let's guesstimate the power to run a server and all its plumbing: 250 W.
and 1200 million per day in 2007...
4. Hmm, this growth rate is big enough that it is going to be hard to get a trustworthy answer!
5. Well, let's multiply 700,000 servers * 0.250 kW * 24 hours per day / 1200 M searches per day -
that is 0.0035 kWh per search; 0.007 kWh for a pair of searches; and 3.5g of CO2 for a pair of searches. (Assuming that electricity has a footprint of 500 g per kWh.) [In fact I think I heard that google has lots of servers in Iceland, where the electricity footprint is much smaller.] Meanwhile, boiling a 250 ml cup of water uses about 0.028 kWh. So my estimate is that the energy cost of two google searches (measured at the googleplex alone) is about one quarter of the energy cost of boiling a cup.

This calculation has not included the energy cost of running your own desktop computer, wireless, and modem for the duration of the search too; nor the cost of running the internet twixt you and google. If it takes you one minute of computer time to do the search, and if your computer and peripherals use 120 W, then the cost of your computer's power in that duration is 0.120 kW * (1/60) hour, which is an extra 0.002 kWh.
Here's the bottom line from my rough guesses: the total energy cost of the pair of searches seems to be about 0.01 kWh. That's exactly the same as the energy used by leaving a phone charger plugged in for one day. Which is also the same as the energy used by driving an average car for one second.

commentor said...

I would guess that Google's CO2 usage will not vary linearly with number of queries.
So, 'not doing a google search' also costs 3.5g of CO2. And 'doing 2 google searches' costs about 3.5g.

Similar to 'not sitting on a bus', 'sitting on a bus', and 'sitting on a bus with your friend' all resulting in very similar amounts of CO2 being emitted by the bus.

Unless the entire bus gets cancelled.

RobHu said...

I think a significant issue here is that we don't know how many servers Google have. It's a closely guarded secret. It could easily be a tenth of the number you quote.

Arnaud said...

As long as you're in commenting the news, Dr MacKay, I'm curious to hear your views about the new emissions trading scheme adopted by Europe at the end of last year. Is that beneficial, do you think?

A.

Scellus said...

I don't believe a typical Google server uses anything near 250W. Their servers are not desktop PC's or even rack servers, but specialized cards with CPU, memory, a network card and little else. Probably they avoid the hottest-running CPU's, for they know that electricity is already or is soon likely to be their highest running cost.

I would guess a server takes around 50W. And given that they use those 7e5 servers for many other things nowadays, besides the search engine, their own estimate starts to look quite realistic.

They have big projects with solar energy - I think they take CO2 seriously.

On the other hand, we don't really know if the number 7e5 is correct.

RobHu said...

Scellus, I think you're probably right. Google work very hard on using as little energy in their servers as possible. Most of their data is stored in RAM (rather than in energy inefficient spinning physical disks), and they even do things like they don't have separate power supplies for each server (with all the AC -> DC conversion loss), but rather single power supplies for blocks of servers.

Perry E. Metzger said...

One does not need to guess about how google saves energy. They've published extensive papers on it. If they claim that it consumes a certain mass of fossil fuel, then I believe them -- they've certainly documented everything with ridiculous thoroughness.

Apparently, among other measures, they run their machine rooms hot to minimize air conditioning, use recycled wastewater for evaporative cooling to further reduce air conditioning energy use, they use unusually high efficiency power supplies, they carefully select chip sets for energy usage, etc.

Perry E. Metzger said...

Oh, and of course, they locate as much of their machine room capacity near low-cost hydroelectric as they can.

David MacKay said...

"One does not need to guess about how google saves energy. ... I believe them"
Sure, I trust google with my life too, so I am happy to trust their analysis!
The motivation for my article was not to doubt google, but rather to do a simple back of envelope sanity-check. I think that is what my friend was asking for, when he asked me what I thought about this news article. My aim in writing this blog is to understand things. If your attitude is "I just believe what google say", you don't advance your own understanding very much, do you!

Charlie M said...

One thing that has been forgotten by your calculations is the number of servers estimate is for the number of servers google owns not the nunber used for their search engine.

The Google search egnine is a very complicated distributed system. To start with Google has a cluster of servers which go out and download the content of every page they index estimated to be about 20 billion every month. For key sites like news sites its much more frequent. This is then stored and feed in to a series of Map Reduce clusters which work on all this data to build the search index.

When you actually make a search query it actually involves quering an index cluster of a few machines. This produces a list of results, then these results are feed to another cluster which holds a copy of all the indexed pages in RAM. This allows the relevant snipets of each page to be retrieved so the search results page is more useful to the end user.

These various clusters are built form relatively inexpensive servers. Usually mid range servers with dual socket Xeons according to various reports.

The problem is these clusters may well be used for other tasks as well as search indexing. Google has many many other products and its known to build as many as possible around the Map Reduce system to enable it to share clusters when it can. The map reduce clusters range from a few hundred servers to up to about 10 000 servers according to reports.

All of this information is either from data in the various Google published papers like the Map Reduce one or Google Tech Talk videos.

It is really hard thing to estimate the energy consumption of a single search query as so much of it is the processing of this preparatory work which would need to be done if there was one query a day or one billion a day. I can see how there are so many different estimations.

Logically the more people use it the more efficient it gets, perhaps we should shutting down the minor competitors for wasting energy!! But with 1% of the search market share adding an estimated 1 billon dollars to a companies value its not surprising there are so many competitors.

Charlie O said...

As someone who's spent 2 1/2 years working in a full-time job in search engine marketing and online research, often hammering Google and Yahoo! data centres with automated queries to extract vast quantities of data to reconstruct networks of information, I can't help but feel I should offest all my Googling somehow.

Perhaps one of you would trade some ignorance credits or let me help you bury some nuggets of information in deep holes to compensate?

Worth checking out Google.org - the philanthropic arm - recently unveiled an interesting energy-use monitoring pilot programme here - http://www.google.org/powermeter/

David Pollard said...

Unusually, your estimate appears to be out by more than an order of magnitude. From the comments above and your data, checking on Alexa.com for Google's reach (30% at .com, 2% at co.uk ...) and with the worldwide number of net users now at 1.6 billion:

The daily number of queries is likely to be at least 2x the 2007 figure.

The power consumption per server is likely to be lower by a factor of 4x or 5x.

And they provide a number of other services, including Google Trends, Blogger, videos, maps and mail for which an additional factor of 2x to 4x or more might be appropriate.

This gives an answer much closer to their figure than yours, so it's not unreasonable, as Scellus suggested, to think that theirs may be correct.

Looking at the question the other way round though, their kit is probably used at a largish fraction of capacity. Searches on Google may well be utilising their system to between 20% and 50% capacity overall, assuming that they balance peak loads with background tasks (which I'm sure they do).

It's difficult to know how what proportion of computer capacity an 'average user' makes. But every two-sipsworth of queries with mine seems to lead to at least a cuppa's use at a very small fraction of its full-bore capacity.