Earlier quoted context omitted.
If they can be reversed individually you can simply deduce by rolling back changes one by one, no?
Suppose you run a fleet of a thousand machines. They all autotune. They are, lets say, serving cached video, or something. You notice that your aggregate error rate been drifting upwards since using bpftune. It turns out, in reality, there is some complex interaction between the tuning and your routers, or your TOR switches, or whatever - there is feedback that causes oscillations in a tuned value, swinging between t…
Bpftune uses BPF to auto-tune Linux systems
41–50 of 78 posts
Re: Bpftune uses BPF to auto-tune Linux systems
#42Earlier quoted context omitted.
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.
Indeed! The kernel might already be too monolithic. This kernel parameters optimisation reminds me of PGO compilation in programs. Yet, perhaps the kernel could come with multiple defaults config files, each being a good base for different workloads: server, embedded, laptop, mobile, database, router, etc.
Though in my opinion, there's already kind of too much segmentation between the different use cases. A server is just a role for a computer, and embedded could literally mean anything. Quite a few WiFi access points come with a USB port on them so you can plug in a USB drive and start a SMB server.
Re: Bpftune uses BPF to auto-tune Linux systems
#43Is tuning the TCP buffer size for instance worth it?
Re: Bpftune uses BPF to auto-tune Linux systems
#44Earlier quoted context omitted.
If they can be reversed individually you can simply deduce by rolling back changes one by one, no?
Suppose you run a fleet of a thousand machines. They all autotune. They are, lets say, serving cached video, or something. You notice that your aggregate error rate been drifting upwards since using bpftune. It turns out, in reality, there is some complex interaction between the tuning and your routers, or your TOR switches, or whatever - there is feedback that causes oscillations in a tuned value, swinging between t…
Alternatively: if you have a fleet of thousands of machines you can very easily do a binary search with them to a)establish the problem with the auto-tuner and then b)which of the changes it settled on are causing your problems.
I get the impression you've never actually managed a "fleet" of systems, because these techniques would have immediately occurred to you.
Re: Bpftune uses BPF to auto-tune Linux systems
#45Earlier quoted context omitted.
Suppose you run a fleet of a thousand machines. They all autotune. They are, lets say, serving cached video, or something. You notice that your aggregate error rate been drifting upwards since using bpftune. It turns out, in reality, there is some complex interaction between the tuning and your routers, or your TOR switches, or whatever - there is feedback that causes oscillations in a tuned value, swinging between t…
Presumably one would use autotune to find optimized parameters, and then roll those out via change control, either one parameter at a time, or a mix of parameters across the systems. Alternatively: if you have a fleet of thousands of machines you can very easily do a binary search with them to a)establish the problem with the auto-tuner and then b)which of the changes it settled on are causing your problems. I get th…
Re: Bpftune uses BPF to auto-tune Linux systems
#46Earlier quoted context omitted.
Fair point, though I didn’t see any such option with this tool.
It's developed in the open; we can create Github issue. Actually https://github.com/oracle/bpftune/issues/99
usage, main() https://github.com/oracle/bpftune/blob/6a50f5ff619caeea6f04d...
- [ ] CLI opts: --pretend-allow or --log-only-allow or [...]
Probably relevant function headers in libbpftune.c:
bpftune_sysctl_write(
bpftuner_tunable_sysctl_write(
bpftune_module_load(
static void bpftuner_scenario_log(struct bpftuner *tuner, unsigned int tunable, ; https://github.com/oracle/bpftune/blob/6a50f5ff619caeea6f04d... https://github.com/oracle/bpftune/blob/6a50f5ff619caeea6f04d...
Re: Bpftune uses BPF to auto-tune Linux systems
#47Interesting. But if tuning parameters to their best values were easy, shouldn't the kernel just do that in the first place?
Re: Bpftune uses BPF to auto-tune Linux systems
#48> bpftune is designed to be zero configuration; there are no options On behalf of every junior administrator, overworked IT admin, and security-concerned "cattle" wrangler, thank you. Having to learn a thousand+ knobs & dials means most will never be touched. I for one welcome automated assistance in this area, even if the results are imperfect.
I think it’s still important to know what those dials and knobs do, otherwise (as the currently top-voted comment says) when things break, you’ll be lost.
Re: Bpftune uses BPF to auto-tune Linux systems
#49Is tuning the TCP buffer size for instance worth it?
Re: Bpftune uses BPF to auto-tune Linux systems
#50Earlier quoted context omitted.
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.
TCP parameters are a classic example of where an autotuner might bite you in the ass... Imagine your tuner keeps making the congestion control more aggressive, filling network links up to 99.99% to get more data through... But then any other users of the network see super high latency and packet loss and fail because the tuner isn't aware of anything it isn't specifically measuring - and it's just been told to make t…