oracle / bpftune

bpftune uses BPF to auto-tune Linux systems
Other
685 stars 59 forks source link

bpftune: support rollback mode (-R) for bpftune #60

Closed alan-maguire closed 1 year ago

alan-maguire commented 1 year ago

Support rollback mode where if bpftune is run with -R option, we roll back sysctl settings on exit. Log will show us a summary of changes along with the values were rolled back; for example:

Aug 23 19:15:04 bpf bpftune[360835]: sysctl 'net.ipv4.tcp_wmem' changed from (4096 16384 16384 ) -> (4096 16384 2220415 ) Aug 23 19:15:04 bpf bpftune[360835]: Scenario 'need to increase TCP buffer size(s)' occurred for tunable 'net.ipv4.tcp_wmem' in global ns. Need to increase buffer size(s) to maximize throughput Aug 23 19:15:04 bpf bpftune[360835]: Rolling back sysctl values for 'net.ipv4.tcp_wmem' from (4096 16384 2220415 ) to original values (4096 16384 16384 )...