I can’t change the
sudo sysctl -w kernel.sysrq=0
when I edit
sudo sysctl -p
# echo kernel.sysrq=0 > /etc/sysctl.d/99-sysctl.conf
when I do:
sudo echo "0" > /proc/sys/kernel/sysrq
and then check if it worked:
output is still: 1
sudo nano /etc/sysctl.d/99-sysctl.conf
kernel.sysrq = 0
I already did that, so it already says:
It works for me and it says so here…
But why do you want to completely disable it anyway?
Do you use
sysrq_always_enabled=1 as kernel parameter?
If so remove that…
Would help to provide the current value of
/proc/sys/kernel/sysrq as reference…
unfortunately I could not find this variable in sysctl.conf, I wish and it seems that this is enabled somewhere…
current value of
/proc/sys/kernel/sysrq = 1
When I try:
$ sudo echo “0” >/proc/sys/kernel/sysrq
bash: /proc/sys/kernel/sysrq: Permission denied
echo “0” > /proc/sys/kernel/sysrq
Notice the space between > and /proc
What is the output of
cat /etc/default/grub You can find the kernel parameter there if you have it.
It is not a variable, it is a kernel parameter used while providing the kernel to load in your bootloader config.
ex. in your
/etc/default/grub and the like…
Sorry guys, the fault was in grub.
sysrq_always_enabled=1 was in grub to load at boot. this was the culprit, I’m sorry.
I forgot about it when I put it there when I followed this tutorial:
The reason was; I am trying to harden my setup with lynis and it gave me a warning that the kernel option kernel.sysrq needed to be 0.
This topic was automatically closed 15 days after the last reply. New replies are no longer allowed.