Video
Đăng bởi Ban biên tập OpenER ·
Tác giả giữ toàn bộ bản quyền (All Rights Reserved) — không phải giấy phép mở. Bạn vẫn xem và học miễn phí trên OpenER; muốn tái sử dụng cần xin phép tác giả.
PROFESSOR
In this final video, let's talk about power usage effectiveness, thinking about optimizing for power. So one of the things — I'll take to tell you a story.
A long time ago, I had someone from Twitter visit our CS10 class. This was about five or 10 years ago. And he talked about — Raffi Krikorian was his name.
And one of the things he did in his lecture was he talked about the difference in workload variation between when Twitter's at the quietest or when it's at the most busy.
It's a very interesting idea. He said the difference was a massive scale, the difference between the lowest time where Twitter's not being used at all, people mostly asleep around the world.
By the way, the fascinating thing he said, like you watch these usages follow with when people are awake around the world.
And as Twitter had more and more folks in Asia using it, all of a sudden, they found that the load stopped going down.
It was mostly asleep, people in North America are asleep and then people in Europe and Asia were. So you get this world, this little cycle thing over them.
He said, when the World Cup is happening, unbelievable activity on Twitter.
When, at the time, Madonna or Justin Bieber were tweeting and following each other, he says, like, the worst thing for Twitter — it's a very funny story.
He said, the worst thing we would ever have is if Justin Bieber and Madonna were at the World Cup and Brazil is in it, by the way.
That would be very also bad because there's a ton of Brazilian users on Twitter. And Brazil is in it.
And Brazil hits the winning goal and then Madonna and Justin Bieber are each tagging each other and commenting on that winning goal and selfies with the winning goalie.
He said, like, we couldn't even imagine how our system would explode because it's all about who's following whom and it's just crazy.
What they've seen, as they did this study on workload variation — so their peaks and valleys were very different, much farther than a factor of 2.
But what they've noticed in some of the power usages of these warehouse scale computers is that there is enough distribution of just people are always hitting on Amazon, always hitting on these services like Piazza and other things, on Facebook.
They're always hitting these services.
So the amount of variation is only a factor of two, even though Twitter was saying for their particular service, it was much more [INAUDIBLE] 10 or 20 or more, 100 even, in the worst case.
They're saying only really a factor of 2 differences in workload variation.
So that's a big difference that once you have a lot of more — maybe a lot of large numbers — remember, Twitter's just one service.
But really, these services are lots of different services going on at once. So maybe that kind of is smoothing the numbers down to have that not at peak time.
So handling workload variation is an important thing. So what's the impact of all this following things, latency, bandwidth, failures, varying workloads on warehouse scale computer software?
Well, first of all, you've got to know where to place data in your array to get good performance. We talked about that before. You don't put it at the edges.
And if you have one company or one service using it, put it as close together, close together near a switch.
Don't put it — well, I'll put you on a server over there, through 19 different switches to get to one end.
Half the data's there and half — no, put it as close as you can, tight as you can, same machine if you can — all those things. You've certainly got to handle failures gracefully.
We talked about how MapReduce handles it. The machine goes down, we just send the job to somebody else. That's no problem. But you have to generally deal with [INAUDIBLE]..
You also know how to flag them. Whenever a machine goes down, as someone who is working at the IT desk and that need to know.
Drive is down, failure — you need to know when a drive fails but before the RAID array fails.
So that's something you've got to catch very quickly to either power that down so that — or maybe if you can get to it quickly enough, often things happen in bursts because you replace all the computers at the same time.
You put all the hard drives in the same time. And they often have failure modes all around the same time. So when one fails, you often say, you know what?
Let me replace all of them because I see that they're starting to fail.
So rather than just wait until they do fail, you can often preemptively replace them because you're saying they're at about a lifespan. They're all manufactured identically. Shouldn't they all fail about the same time?
So that's what starts to happen. One fails, two fails, all of a sudden, there's a ton of them. So they have a whole scale replacement.
And when they do that, then you have the problem now, they'll all need replaced again at the same time roughly. You certainly must scale up and down.
You want to power things down if you can or maybe just go idle and just see how bad it is.
You think about power and what you should do in terms of your own costs to deal with scaling up and down as usage increases or decreases.
There's just complexities of hierarchies of memory, failure tolerance, workload accommodations. All that makes that the software development for warehouse scale computing really challenging.
Much more challenging than a single computer where, as mentioned before, cores don't die. Maybe they do, but rarely, really, really rarely. I mean, your hard drives die.
But you'll have one drive die but you don't have a core die. You don't have a worker bee die. That happens all the time, though, where the network goes out or a computer dies.
Those will happen all the time. Eventually, machines die, although certainly with solid state drives, you certainly have failures less often than you used to of the early days.
So here's a graph, power versus server utilization. And this is a really interesting graph but also I wouldn't say scary, but it's a depressing graph.
This shows, as the computer load grows from idle to 100%, what's the power? So it turns out that these systems are not just constant power.
That would be terrible to have a computer at idle use exactly the same power as at maximum time. What they found is just look at this curve. Here's the factor that contributes to this.
CPU, DRAM, disk, interesting, and other. What contributes to the power usage of a system? Look at this, uses almost half power when idle.
Almost half power went idle and 2/3 power when 10% utilized. Look at this, here's 10% utilization. Look at this, 2/3 when 10% utilized.
90% or 50% — here's 50%. 90% power at 50% utilization.
By the way, you want to keep it in the sweet spot. You don't want to have most servers be pinned because then what happens, there's no room to breathe.
You want to be able to have most servers live in kind of the safe spot here. And by the way, the goal should be energy proportionality.
The peak load should be equal to the percentage of peak energy. So this should be a straight line. Okay. That's not a straight line but it should be close to that.
You're nowhere near that. So that's the goal here. People are trying to build systems more and more to get to that, but it's hard. It's very hard.
So power usage effectiveness — this is a really interesting model and it's a very nice metric.
The overall efficiency is the amount of computational work performed divided by the total energy used in the process. That's it.
So PUE is total building power divided by IT equipment power. So power efficiency for warehouse scale computers, not including the efficiency of servers and networking gear.
So a one means total building power divided by IT equipment power is one when you're doing exactly right. So here are our numbers. Here's the best possible value.
So essentially, there's overhead. If you think about this, the higher it is, it means you just have more waste. There's just not as much overhead.
If you're exactly perfectly lean and you're computing exactly, all the cost is for the IT stuff, not the overhead. So look at this. So this is very fascinating.
Lawrence Berkeley National laboratory did a survey of the PUE of 24 different data centers in 2007. And what they found was a remarkable variation. 24 data centers, who knows how many different designs.
Look at these are the different flavors. Well, these are kind of the same. Those are kind of the same. These are all the same design, maybe.
This may be the same design. Who knows? Who knows whether people do same design. The systems, one might be in a hot area versus a cold area.
Who knows where they are, whether they have any other differences. Are these 24 total different designs or basically the same design with different variations of it? And they found the average about 1.83.
The goal is to get to one. It's very hard to get to one but there are some that are doing really well. There's some at about 1.2, 1.3, 1.4.
That's pretty incredible. And there are some that are just crazy inefficient at 3 here. So really interesting to think about PUE in the wild. Where does it go?
Where does all that excess power go when you're not spending time on the actual compute?
Remember, the goal is to get it to be all the power is being used for the things for the IT system, things that are paying the bills, at the end of the day.
So here's the service of networking. We can see IT equipment, that's there. Now, where else is it going? Well, power distribution unit is a little bit of time.
There's transformers and switches, a little lost there. There's the UPS we talked about before.
This is probably the UPS that isn't local to every computer but that might be local to every computer, as well. Look at this, chiller cools warm water from the air conditioner.
And then there's a computer room air conditioner. Okay. So you've got a computer room air conditioner moving air in and out.
And then that hot air has to be cooled to then send cool air back in and there's a chiller doing that from the air conditioner.
If you've ever seen an conditioner, there's two parts of that. Look at this. Look at the size of it. It's like half of the chart is just cooling, incredible.
So what did Google learn? So Google did this and wrote a report. They said, this is what we've learned, how to be really smart about PUE. One, careful airflow.
By the way, whoever thought that if, Dan, you're going to be teaching computer architecture. Okay, great. You're talking about airflow. What?
Yeah. Sometimes, you need to talk about airflow and cooling and temperature.
If that's the reason that both you're paying a ton of money and those are the reasons that you can't run something at a certain — I mean, I mentioned before, the reason we can't have 6 gigahertz 28 core machines — the current Intel machine is a 28 core 2.5 gigahertz machine.
The reason I don't have 6 gigahertz is because I can't get that cool. There's just no way to get heat off of that chip. So it's a reality in terms of the constraints.
So Google talked about careful airflow handling. Don't mix the server hot air exhaust room — here's a server. And there's cool air coming in.
It takes the heat off of the server and then hot air is coming out. Don't mix it with cold air. Separate a warm aisle from a cool, which is really interesting.
It's almost like the stockade where you have a cow and the cow gets fed on this side and then the backside you just clean up on the waste end of it.
It's like this, you kind of lock in the server, two parts of it.
And there's no flow of air from the front air, cold air coming in, coming in, pulling the heat off of the system.
And then the hot air, I think of the exhaust as the garbage, goes out the back. And so keep those distinct.
Also, they learned very clearly that just having one big room — in the olden days, you might have been surprised if you saw the inside of a WSC, you see these freight containers.
You might have said, why did they do that? Why don't they just have a big room with all these servers? Yeah, because, A, it's really loud. That's not a big deal.
But also, this hot and cold air just mix and the whole thing gets really, really hot.
So they said if you localize it to this freight container, then you can have a lot more channeling of air rather than air just swirling around and eddies and flows.
It's a lot easier to control the airflow in a smaller container. So that's what they do. That's the reason why they put them in there.
You also can put them in and replace them and take a hold — here's a new one. There's the old computers. Okay, here's a whole new one.
We're replacing all the computers by just putting a new freight container in. New freight container, all new computers. That's kind of a nice thing.
So somebody is obviously switching them but you just swap it in very quickly and, all of a sudden, you swap it very fast. That's another advantage of that.
Short path to cooling so little energy spent moving cold or hot air long distances.
So that means it's expensive and hard and inefficient to take hot air and move it all the way over here to cool it to send it all the way back.
So have a short path to cooling as much as you can. Localize cooling. It's almost like data, right? You want to have the data near the compute center.
Don't put one data over here, one data over there, and here's the CPU. No, no, have the data close to it. Same idea here, have a short path to cooling.
And I mentioned before, that's the third ball that I kind of I skipped orders. But keeping the servers in tighter containers helps the airflow.
You get to control the airflow because the airflow isn't just random all around the room.
Also, they learned, which is a funny thing, I wouldn't have realized this, that you can elevate the cold aisle air temperature.
Remember, the cold aisle means, okay, there's a hot air, get that out of here. But then how cold is — normally, you walk into a server room, it's pretty warm.
They've learned that you can actually keep those server rooms warmer and not have machine failures. The worry is, if you have a higher elevated temperature around the machines, you're going to have failures.
You're going to have the computer, all the sudden things will overheat.
If you ever have folks who live in very, very hot areas in the Caribbean, their computers fail more often because it's just a hotter temperature. It's harder to cool those things.
So they've found that it's actually okay to keep the cold aisle temperatures in the 80s rather than the 60s. I used to walk into Soda Hall and Corey Hall into their server rooms.
There's a couple of server rooms that used to live on the fifth floor. And I'd walk in and it'd be freezing.
In fact, they actually moved a lab inside the inside there and I would be freezing working on a computer with the air conditioners in the other room.
But it was just so cold near that system because they thought, well, you've got to keep them cold. They learned you don't have to keep them that cold.
You can actually keep them a little bit warmer. The reliability is okay if the servers are run hotter. And, I mentioned this earlier, use free cooling. Cool warm water outs by evaporation cooling towers.
So we evaporate there. And also put it in a moderate climate. I've mentioned that before. And maybe even draw water in to help with the cooling system, if you can.
And I mentioned this before, a per server 12 volt UPS rather than a warehouse scale UPS in the basement pays a single battery per server board increases the efficiency from 90% to 99%.
So huge wins on that for having a little battery for everybody. And don't just go it alone. Measure an estimate PUE, publish it, improve operations. Share the best practices.
Here's Google, here's Facebook, here's Amazon, don't talk. No, talk to each other. And the best practices talk to each other.
Let's have conferences around WSC and let's figure out what the best ideas are to help all of us.
It's really nice to do rather than all go it alone and never share any value information.
I mean, certainly, there's some corporate secrets about these things but, like, it's kind of a nice idea, the open-minded spirit to share the best practices across different companies, nice model.
This is an interesting computer the news piece. Normally, computing in the news happens during the live sessions or doing, welcome to CS 61C, Computing in the News.
I wanted to put this at the end because now we're talking about power. In 2011, Google disclosed, somebody revealed how much power Google is actually using. Somebody says, tell me how much power?
And they went out and did some investigation to find out how much power Google was using in all of its servers, on all of its servers.
And it said, it continuously uses enough electricity to power 200,000 homes, which blew people's minds. Like, that's a small city. You're telling me all your servers could power 200,000 homes?
But here's what it says. It says, by doing so, it makes the planet greener. Why? Well, you might argue that's an interesting case.
Without Google, without the ability for Google to do — not the ad part, but Google to be able to give search, I might have to call people on the phone.
I might have to actually go there. I might have to go places. Are you open? If I can't find out, I have to go places.
So think about all the possible time that you're saving by using Google rather than driving to your library or driving to buy something, all those services Google provides.
They say, well, you know what? Search costs per day the same as running a 60 watt light bulb for three hours.
So turn your 60 watt light bulb on for three hours and turn it off and then that's the same as searching per day per person. It's a model.
They still got flak for that. So Google then said, this is just the Google side, and this is some news in 2018.
Over the course of 2017, across the globe for every kilowatt hour of electricity we consumed, we purchased, kind of like carbon trading, in a way, a kilowatt hour of renewable energy from a wind or solar farm that was built specifically for Google.
That makes us the first public cloud and company of our size to have achieved this feat. So kind of trading that, in that sense. So that's an interesting model.
This is a curve. This graph is part of the computing in the news that says cumulative corporate renewable energy purchase in the United States in Europe and Mexico, March 2018.
And you see that Google is far outpacing anybody else, in terms of the big people who run service. But Microsoft also runs warehouse scale computing, as well as Apple.
But it's kind of interesting. You can see who's running these WSC. Look, Walmart here, Dow Chemical, interesting, not just the big kind of three or four or five.
So Google certainly buying a lot more renewable energy. So that's a great job. Kind of offsets, right, to offset all the work that they're doing. We're done.
Oh my gosh. In summary, parallelism is one of the great ideas in computer architecture, number four, in fact.
It applies to many levels in the system from instructions, from a parallel and gate all the way up to a warehouse scale computing. Pretty incredible that you learn all about this in one class.
Remember, post PC era, local drive, local watch, computing device has the front end interface for it, really wonderful, voice interface, Amazon Alexa, all of that.
But the back end, the cloud, does all the work. That back end, the warehouse scale computer, has to do with failures, varying workload, varying hardware latency, certainly sensitive to cost, energy efficiency.
You put them in the right place in the country. You try to get cheap land. You try to deal with cooling.
Can you deal with even cooling without — I'm going to show you two videos. I'm linking to two videos as part of this, too, I want you to watch.
I believe it's a Google and Amazon — I believe it's a Google and a Facebook WSC.
I want you to watch these two videos, which are just little, like, news videos about what goes on inside these. I want you to make sure you watch that, as well.
And warehouse scale computers support many applications that we have come to depend on. So this is how it works. This is our little taste from 61C. Hope you enjoyed it.
I'll see you the next time.
Đăng nhập để đánh giá học liệu này.
Đăng nhập để bình luận — chưa ai bình luận về học liệu này.
Không có khóa học liên quan.