Quantcast
Channel: Debian User Forums
Viewing all articles
Browse latest Browse all 3423

How do you properly set kernel configuration parameter (MGLRU)

$
0
0
I would like to set(enable) kernel configuration parameter MGLRU:

https://dev.to/archerallstars/enable-th ... -today-ji6
https://docs.kernel.org/admin-guide/mm/ ... n_lru.html
https://github.com/hakavlad/mg-lru-help ... /README.md

It seems to be included in Kernel but not enabled (and its "stats"):
grep -Ria CONFIG_LRU_GEN /boot
Off Topic
/boot/config-6.1.0-27-amd64:CONFIG_LRU_GEN=y
/boot/config-6.1.0-27-amd64:# CONFIG_LRU_GEN_ENABLED is not set
/boot/config-6.1.0-27-amd64:# CONFIG_LRU_GEN_STATS is not set
/boot/config-6.1.0-26-amd64:CONFIG_LRU_GEN=y
/boot/config-6.1.0-26-amd64:# CONFIG_LRU_GEN_ENABLED is not set
/boot/config-6.1.0-26-amd64:# CONFIG_LRU_GEN_STATS is not set
I have read that to enable it, best way is not to edit /boot/default/grub, but create new file in a /etc/grub.d/

So I did it (possibly wrong) like this:

echo 'GRUB_CMDLINE_LINUX_DEFAULT="${GRUB_CMDLINE_LINUX_DEFAULT} mglru.enabled=1"'|sudo tee /etc/default/grub.d/mglru.cfg && sudo update-grub
Off Topic
Generating grub configuration file ...
Found linux image: /boot/vmlinuz-6.1.0-27-amd64
Found initrd image: /boot/initrd.img-6.1.0-27-amd64
Found linux image: /boot/vmlinuz-6.1.0-26-amd64
Found initrd image: /boot/initrd.img-6.1.0-26-amd64
Found linux image: /boot/vmlinuz-6.1.0-27-amd64
Found initrd image: /boot/initrd.img-6.1.0-27-amd64
Found linux image: /boot/vmlinuz-6.1.0-26-amd64
Found initrd image: /boot/initrd.img-6.1.0-26-amd64
Adding boot menu entry for UEFI Firmware Settings ...
done
Yet it is enabled only in one older kernel: grep vmlinu /boot/grub/grub.cfg
Off Topic
linux /vmlinuz-6.1.0-27-amd64 root=/dev/mapper/hn--vg-root ro quiet
linux /vmlinuz-6.1.0-27-amd64 root=/dev/mapper/hn--vg-root ro single
linux /vmlinuz-6.1.0-26-amd64 root=/dev/mapper/hn--vg-root ro quiet mglru.enabled=1
linux /vmlinuz-6.1.0-26-amd64 root=/dev/mapper/hn--vg-root ro single
linux /vmlinuz-5.10.0-20-amd64 root=/dev/mapper/hn--vg-root ro quiet
I have tried to add varieties:
Off Topic
${GRUB_CMDLINE_LINUX_DEFAULT} mglru.enabled=1
$GRUB_CMDLINE_LINUX_DEFAULT mglru.enabled=1
mglru.enabled=1
so what to try to enable it at boot? It is possible that mglru.enabled does not exist since it is supplied by AI and I am doing it wrong.

This seems to enable it at least for the session during runtime:
echo y|sudo tee /sys/kernel/mm/lru_gen/enabled
y
cat /sys/kernel/mm/lru_gen/enabled
0x0007

Statistics: Posted by postcd — 2024-11-12 16:27 — Replies 5 — Views 118



Viewing all articles
Browse latest Browse all 3423

Trending Articles