Hello everybody, I'm going to talk about PowerLetrics, which is a scalable infrastructure
to measure your energy because we've seen, we've heard lots of talks aren't important
is to measure the energy, right?
So, here we are, and we are green coding solutions and we basically build software to measure
and obviously optimize our ICT footprint.
So, the problem, and we've heard it before, we all know the world is burning, we somehow
some people care, we know that ICT produces loads of CO2, not like water obviously and
all other resources, some people know that, but a lot of people know that like everybody
talks about flying, but ICT is using far more, just like producing far more CO2 than flying.
If we were to tell people you could save up to like 50% we saw the slide, that utilization
levels are 12%, like we can save it, we can do this, right?
There's a huge saving potential, but people aren't talking about this.
And then when you talk about, okay, where are these say potential, nobody really knows,
like when you talk to industry, when you talk to people, how much does your laptop really
use, how much does Spotify use, nobody really knows.
So, really enough Linux is in a position where we've been overtaken by Apple and Windows.
So if you look at Windows, have the estimation engine, that's really good, that's a really
good estimation.
It will tell you, really jewel-wise, what processes are taking, they've done a lot of work
on their flow of benchmarking, even macOS has power metrics, power metrics, which gives
you fairly good estimations on energy footprint or energy values.
Linux, pretty much has some ideas, but really doesn't have anything standard, there's some
solutions, despite it being 70% of the server market, on the mobile phone market, we can
get Apple readings, but that's also Windows and Mac, so it has also energy metrics on
the CPU level, but nobody can really expose them because of security concerns, right?
You can't really, it's very difficult.
So we have models that work on CPU utilization, but CPU utilization, there's a bog article
here that we wrote is a really bad value, like modern CPUs scale dynamically, they have
two-able boosts, I don't know whatever, CPU utilization, you can't really get really
good metrics out of CPU utilization.
So that's something we were thinking about and we were like, okay, how are we going to do?
And lucky enough the catalyst fund from the green screen coalition paid me to write code,
which was awesome, and they're still paying me, they gave you more money, which is quite
cool.
So what do we set out to do?
We want to put Linux on top, we want to be better than Windows and Mac, we want it all
to be open, we want to be shared, we want it to be saved on servers, like most hardware
runs in containers or somehow virtualized, and there's no real way to expose this into
the containers, it was really important to expose these energy values into the containers
and get them on servers, and we've talked to like multiple big server vendors and they're
all interested in this, and obviously open source, it has to be accessible, it has to be flexible,
we have to talk about this, we have to, all the other solutions are closed source, Windows
and Mac is not documented, I think it's really vital that it's open source and we can
talk about this.
So we have three attack vectors, we have the L3E engine, which is like a non-linear statistical
model that can calculate energy usage values, we have power metrics with like a benchmarking
tool, it's a clone of power metrics for Mac, so it has the same API, it has the same output
formats, so you can port programs that work under Mac, you can port them to Linux very easily,
and we've got the kernel extension that exposes all the power and energy values into the
Prox file system.
We wrote a paper about there, so it's been peer reviewed and it will be published on
the green's workshop in July, I think.
So there's one, when we started this, we talked to loads of people, and everybody seems
to want energy, right, and everybody's like, are giving really jewels, giving really
jewels, what nobody tells you what they want to do with this value, everybody's like
mini jewels, but getting energy values is really, really hard to get them precise, so we
also have the green metrics tool where you can do this, we run like a specialized hardware
cluster, has a specialized Linux on it to get precise energy values, so I think we can't
give you energy values, but I think that's all stops the discussion, I think we should
talk about an abstract value that gives you indication, so we've got the energy footprint
Apple, game along and did this energy impact, which is also, it doesn't it correlates
to Jewel, but it's not equal to Jewel.
So there's two programs, there's PowerLetrics, which uses EDPF in the kernel to get the
values, to get the values it needs, puts that in the L3, and then exposes it through the
PowerLetrics user space, and then you can benchmark in start PowerLetrics, start your
programs, and you'll see all the processes, everything sort of interacting with each other,
and that's really great, if you're benchmarking, that's really great, if you're looking
at your code, if you want like a quick idea, what's happening on your machine, but
then we thought, okay, nobody's going to run a EVBF script on their servers all the time
and write something around it, so then we also have the green kernel, which is the kernel
module, that does basically the same what PowerLetrics does through the engine, but exposes
it to the PROC file system, and like techies will know the PROC file system, every process
basically has a folder structure in there, and then you can, and that's a file, and you
can just open the file and get your energy metrics for that process, and then you can just
use log-stash cart, whatever you want, grab whatever tool you want, to access it.
So this is PowerLetrics, you can see we've got all the different values, but the important
thing is, this is a classical system, this is me when I'm developing, the first 50 processes
I'm node, and they're using huge amounts of energy, basically it's VS code, doing I don't
know what it has to do, so, exactly, so I talked about this, so it has EVPF, it imports
Ruffle, and it separates an appropriate process, level your energy usage, and it has an overhead
of 0.2%.
So these are overhead, but it's not statistically relevant, I want to say.
You can try it, it's a Python package, you can do pip install, PowerLetrics, it does all
the compilation, that's another thing for you, should be fairly simple, please give me
feedback, try it, and this is the power kernel, I wanted to have this release, that falls
to the input and that edge, so this is going to be released in the next week, so this
is a kernel module, obviously you need root to run it, you need the assist admin to install
it, but the sweet thing is, it gives you all the stuff in the prox faster, and because
it's in prox, it will also give it to you in containers, right, so if you have, if you're
like a classical cloud vendor, you install this kernel level, and all the containers, all
the virtual machines, you can just funnel it through, so each container will know how much
energy it's using on the host system, and there are no security concerns, if you use
wrap all something, you can do side channel attacks and everything, but through this because
the update interval, we recommend to set it to five seconds, there's no way you can
expose any secrets or something, but like this, you can just add it to your log start or
whatever, every Docker container knows how much energy it's using on the host machine.
Exactly, everything is on GitHub, please contribute, look at it, the E3 engine, the
L3 engine is easily replaceable, you can tune it, because obviously every hardware is different,
so we're looking at, for example, you need different weightings, you need different parameters,
what's an all major destroys, and we're trying to make it easy to use, so a lot of
problem we're seeing with all these like really specialized tools, also with our grim matrix
tool, is it has a very steep learning curve, and people don't want that, people want
to just see a value, right?
Exactly, thank you again to the catalyst fund for funding this, it's been awesome to
just get money and work on this for a month or two, here are all the links, and if you've
got questions, drop me in, you know, thank you.
So I was thinking, I quite have quite short of processes, can you aggregate how are you
to do your own time by control groups, yes, you could, yeah, I haven't done it, but technically
there's nothing against it.
Yes, if you measure the whole variety to those by measurement tool, because I guess
that it gets the use of energy to collect all the data, it can be variable according to the
quantity of processes that they're missed, so if you, so, yes, we, we, we have benchmarks
of you that, and the 0.2 is max sort of a benchmark with a thousand process, I think,
so, but obviously it scales with processes, because we have to look at the data of all
the processes, but luckily the way the kernel works in the VPF, the data structures are
quite optimized, so we don't have to do, so the initial load of the process is, let's
say, expensive, right, because we have to do all the resolution and everything, but then
luckily the kernel gives us a very good data structure that we can query quite in effect
of, but yeah, obviously, if you've got a massive server with 10,000 processes on it,
you're going to have a higher overhead than the small embedded device, yep, thank you.