Live data from Hacker News

Bpftune uses BPF to auto-tune Linux systems

github.com

1–10 of 78 posts

Re: Bpftune uses BPF to auto-tune Linux systems

#4
post #3

Interesting. But if tuning parameters to their best values were easy, shouldn't the kernel just do that in the first place?

It depends on workload. This tool generates recommended config for that specific machine workload. App Nodes can have completely different recommendations vs Database Nodes. It will be completely different for Workstation.

Re: Bpftune uses BPF to auto-tune Linux systems

#5
post #3

Interesting. But if tuning parameters to their best values were easy, shouldn't the kernel just do that in the first place?

It depends on workload. This tool generates recommended config for that specific machine workload. App Nodes can have completely different recommendations vs Database Nodes. It will be completely different for Workstation.

Sure, but the kernel could just do the same. Of course the kernel is already too big. Is BPF the right level to make it more modular? Just thinking, I don't think I have the answer.

Re: Bpftune uses BPF to auto-tune Linux systems

#7
post #3

Interesting. But if tuning parameters to their best values were easy, shouldn't the kernel just do that in the first place?

This doesn't necessarily find the best parameters, and it doesn't necessarily do it easily. From my reading, it will converge on a local optimum, and it may take some time to do that.

In theory, I don't see why the kernel couldn't have a parameter-auto-tune similar to this. In practice, I think the kernel has to work in so many different domains, it'd be impossible to land on a "globally good enough" set of tuning heuristics.

I'm far from a kernel developer, so I'm ready to be corrected here.

IMO if we ever see something like this deployed widely, it will be because a popular distribution decided to install it by default.

Re: Bpftune uses BPF to auto-tune Linux systems

#8
post #3

Interesting. But if tuning parameters to their best values were easy, shouldn't the kernel just do that in the first place?

I would reverse the question: if it can be done by a BPF module, why should it be in the kernel?

Distributions turning it on by default is another story. Maybe it deserves to be shiped on all the time but that's not the same thing as being part of the kernel.

Re: Bpftune uses BPF to auto-tune Linux systems

#9

Is tuning the TCP buffer size for instance worth it?

It depends. At home - probably not. On a fleet of 2000 machines where you want to keep network utilisation close to 100% with maximal throughput, and the non-optional settings translate to a not-trivial value in $ - yes.
Post reply on HN