One place that is often overlooked when calculating carbon use is energy spend by compute infrastructure.
Last year, we wrote about how we went carbon neutral and re-affirmed our commitment to offset emissions. We calculated our footprint across many parts of Mapbox, from travel to powering our offices and all the way down to the nitty-gritty of lunch catering. We used various tools to add up our energy usage and carbon emissions (CO2e) and make savings where possible. In places where it wasn’t yet possible to make that change, we purchased equivalent carbon offsets and renewable energy credits.
This year we did all that, and also dug deeper into the energy use of our cloud computing infrastructure, most of which runs on AWS.
In collaboration with Chris Adams from the Green Web Foundation, we developed the Green Cost Explorer to better understand these emissions.
Sustainability on AWS Compute
AWS announced that it exceeded 50% renewable energy use in 2018 — powered by more than 100 renewable energy projects around the world. However, it is not yet 100% carbon-neutral. Amazon has committed to be 100% renewable-powered by 2030. (In contrast, Google Cloud runs on 100% renewable energy and Microsoft Azure has been carbon-neutral since 2012.)
AWS publishes the list of which data centers are 100% carbon-neutral by default. This is great — it means that any workload you run on those data centers will be carbon-offset. Mapbox compute runs currently in nine different AWS regions — some of which are fully carbon-neutral, some of which are not. Here you can see which regions are carbon-neutral:
Exploring green cost
Let’s dig into the numbers. AWS supplies us with a flat number of total carbon use across the whole account. However, we wanted more granular visibility into the spending to see which services were not running on sustainable data centers, and where we could save carbon.
Green Cost Explorer uses the AWS Cost Explorer API and data from AWS’s sustainability pages to get cost of each AWS product you use per region. You can then export the data in different formats to dig deeper in your setup.
Of course, cost is not a totally accurate indicator of carbon spend. However, in many cases, cost on AWS is calculated around compute unit utilization. So while the mapping may not be 1-to-1, it is a decent indicator of where your carbon-heavy hitters may lie.
What can you do?
Use green-cost-explorer to track “green cost” of your AWS workloads. You’ll gain more insight into where your grey cost is, and which services are driving it. You may be able to transfer some of your workloads into a different region to maximize your use of AWS’s sustainable regions! (But keep in mind that data transfer and network usage also cost energy and money, so make smart decisions based on locality of your users.) Check out green-cost-explorer on Github to explore your breakdown of sustainable vs not-sustainable spend.
Maximize your compute utilization by using containerised infrastructure. We run on Docker on AWS ECS to power our computing workloads. Read about how we switched to AWS ECS on Spot and saved money and energy in the process.
Learn more about sustainable tech. There are other ways you can green your tech stack. Check out Chris Adam’s talk on the topic to learn more.