Slide 1

Slide 1 text

©2020 VMware, Inc. Sustainability in Software Engineering How to make a difference Martin Lippert Spring Tools Lead, MAPBU, VMware October 2020

Slide 2

Slide 2 text

4 Confidential │ ©2020 VMware, Inc. This is a huge challenge, and we can make a huge difference. Software is eating the world and can have a huge impact. Let’s not wait for others to solve the problem. Everybody is involved – we all share the same responsibility. 3 ©2020 VMware, Inc. This is a huge challenge, and we can make a huge difference. Software is eating the world and can have a huge impact. Let’s not wait for others to solve the problem. Everybody is involved – we all share the same responsibility.

Slide 3

Slide 3 text

©2020 VMware, Inc. 4 Contributions to climate change Greenhouse gases: • CO2: 74.36% (carbon) • CH4: 17.32% • N20: 6.19% • F-Gas: 2.13%

Slide 4

Slide 4 text

5 ©2020 VMware, Inc. We need to de-carbonize the entire world of software engineering

Slide 5

Slide 5 text

©2020 VMware, Inc. 6 Employee Commute Energy Production Business Travel Food in the office Hardware Hardware Production Heating / Cooling Data Center Operation Network Traffic CPU Cycles Memory Consumption SWAG production Shipping / Transport Energy consumption Where should we start? There is a wide range of topics

Slide 6

Slide 6 text

©2020 VMware, Inc. 7 89% 7% 4% Energy - 89% Land-use - 7% Industrial processes - 4% What causes carbon emissions?

Slide 7

Slide 7 text

8 ©2020 VMware, Inc. Energy Production

Slide 8

Slide 8 text

©2020 VMware, Inc. 9 We need 100% renewable energy This will take a very long time -> we don‘t have the time to wait for that The energy question

Slide 9

Slide 9 text

©2020 VMware, Inc. 10 We need to tackle this from both sides Increase renewable energy production Decrease energy consumption

Slide 10

Slide 10 text

12 ©2020 VMware, Inc. Energy Consumption

Slide 11

Slide 11 text

©2020 VMware, Inc. 13 Employee Commute Energy Production Business Travel Food in the office Hardware Hardware Production Heating / Cooling Data Center Operation Network Traffic CPU Cycles Memory Consumption SWAG production Shipping / Transport Energy consumption Where should we start? Energy Consumption

Slide 12

Slide 12 text

14 ©2020 VMware, Inc. Easy to remember rule: Try to run your software with less hardware

Slide 13

Slide 13 text

15 ©2020 VMware, Inc. Step 1: Do not run your software

Slide 14

Slide 14 text

©2020 VMware, Inc. 16 • run the software only when necessary • Scale down (to zero) Scale to zero

Slide 15

Slide 15 text

©2020 VMware, Inc. 17 • Almost all datacenters have zombies sitting around • They consume energy, space, and hardware – for nothing Eliminate zombies

Slide 16

Slide 16 text

©2020 VMware, Inc. 18 VMware Singapore datacenter consolidation in 2019 • 66% of host machines were zombie & decommissioned Yes, it is Is this real?

Slide 17

Slide 17 text

©2020 VMware, Inc. 19 Stanford/Anthesis study on zombies (2017) (Jon Koomey) • 16,000 non-virtualized and virtialized physical servers, 10 data centers (multiple companies) • 25% zombie physical servers • 30% zombie VMs More evidence

Slide 18

Slide 18 text

20 ©2020 VMware, Inc. Step 2: run your software with less energy

Slide 19

Slide 19 text

21 ©2020 VMware, Inc. Reduce memory consumption

Slide 20

Slide 20 text

©2020 VMware, Inc. 22 Memory constantly consumes energy • 1GB RAM consumes about 2W (varying)* Memory efficiency pays off • Let's assume: – Your process runs with 8GB RAM (reserved) – You have 4 instances running – You can reduce that to 6GB RAM • Result: – 2GB RAM saved per instance, total of 8GB saved -> 16W – ~ 140kWh per year Memory (* average rough number, varies depending on type of RAM, power vs. idle mode, and other factors)

Slide 21

Slide 21 text

23 ©2020 VMware, Inc. Reduce CPU cycles

Slide 22

Slide 22 text

©2020 VMware, Inc. 24 CPUs consume a lot of energy • Lets assume an average of 50W* • Lets take a look at a random: – Your process runs on 4 instances (each instance eats 20% of a CPU) – ~350kWh per year CPU cycles

Slide 23

Slide 23 text

28 ©2020 VMware, Inc. Where to run the software?

Slide 24

Slide 24 text

©2020 VMware, Inc. 29 Data centers have different characteristics • AWS: depends on the region whether you run on renewable energy or not • Google: 100% renewable energy • Microsoft: 100% renewable energy • In-house: How do you power your data center? Choose wisely Large scale: Data Centers

Slide 25

Slide 25 text

©2020 VMware, Inc. 30 What exactly does „run on 100% renewable energy“ mean? • Contract with renewable energy provider? • Generates its own renewable energy? – How much? – All the time? – Or depending on weather conditions? Companies start to choose the location of data centers depending on the availability of renewable energy • But beware a situation where your data center consumes all the available renewable energy (e.g. hydro power), but doesn‘t increase the amount of renewable energy on the grid „My data center runs on renewable energy“ Does this solve the problem?

Slide 26

Slide 26 text

©2020 VMware, Inc. 31 Small scale: Kubernetes

Slide 27

Slide 27 text

©2020 VMware, Inc. 32 Scheduling depends on a lot of factors (latency, availability, etc.) Take sustainability into account • Choose data center in cold regions (less cooling needed) • Choose data center with the most available renewable energy (depending on solar/wind conditions) • Dynamically reschedule when conditions change Schedule your workloads wisely

Slide 28

Slide 28 text

40 ©2020 VMware, Inc. Offsetting emissions A topic of its own

Slide 29

Slide 29 text

©2020 VMware, Inc. 41 Offsetting is generally a good idea • Offsetting projects generally do good things • Choose the project wisely, not every offsetting project really pays off BUT: • Offsetting is sometimes used/viewed as clean-washing • Offsetting is just a last resort, it doesn‘t really solve the problem • We need to avoid carbon emissions AND support those projects For example: • Planting trees is a great idea • But the calculation is sometimes off reality – e.g. it takes 20 years for a tree Offsetting emissions

Slide 30

Slide 30 text

42 ©2020 VMware, Inc. Principles for sustainable software engineering https://principles.green

Slide 31

Slide 31 text

43 ©2020 VMware, Inc. “Sustainability is the next frontier in innovation” Nicola Acutt, VMware Sustainability Lead

Slide 32

Slide 32 text

©2020 VMware, Inc. Thank You Martin Lippert @martinlippert lippertm@vmware.com