You are not logged in.
Hi, I have been following the wiki and enabled CPU boost on my ryzen cpu with this command: "sudo echo 1 > /sys/devices/system/cpu/cpufreq/boost" not sure if this is relevent, but even with sudo, it returns permission denied, but switching to the root account and running: "echo 1 > /sys/devices/system/cpu/cpufreq/boost" works. That aside, echoing the file returns 1, as expected, but this isn't persistent on reboot. Am I doing something wrong? Or is this intended behavior? Thanks.
Last edited by Nan123 (2022-02-17 09:15:54)
Offline
this is intended and expected behaviour. /sys is a virtual file system that exposes kernel interfaces and gets recreated on every boot with the normal kernel/hardware defaults.
There are multiple ways of setting this on boot, you can either create a small systemd service or use udev rules or systemd tmpfiles, se: https://wiki.archlinux.org/title/CPU_fr … _permanent for some options specifically targeted towards changing cpu params.
PS You get permission denied with sudo because you elevate the echo 1 and not the > shell redirection which happens as your normal user, to do it without changing to a root shell you can e.g. elevate a tee or so
echo 1 | sudo tee /sys/devices/system/cpu/cpufreq/boost
sudo bash -c "echo 1 > /sys/devices/system/cpu/cpufreq/boost"Last edited by V1del (2022-02-17 08:47:03)
Offline
Not SysAdmin. Moving to NC.
Are you familiar with our Forum Rules, and How To Ask Questions The Smart Way?
BlueHackers // fscanary // resticctl
Offline
this is intended and expected behaviour. /sys is a virtual file system that exposes kernel interfaces and gets recreated on every boot with the normal kernel/hardware defaults.
There are multiple ways of setting this on boot, you can either create a small systemd service or use udev rules or systemd tmpfiles, se: https://wiki.archlinux.org/title/CPU_fr … _permanent for some options specifically targeted towards changing cpu params.
PS You get permission denied with sudo because you elevate the echo 1 and not the > shell redirection which happens as your normal user, to do it without changing to a root shell you can e.g. elevate a tee or so "echo 1 | sudo tee /sys/devices/system/cpu/cpufreq/boost"
you live and you learn, thanks!
Offline
this is intended and expected behaviour. /sys is a virtual file system that exposes kernel interfaces and gets recreated on every boot with the normal kernel/hardware defaults.
There are multiple ways of setting this on boot, you can either create a small systemd service or use udev rules or systemd tmpfiles, se: https://wiki.archlinux.org/title/CPU_fr … _permanent for some options specifically targeted towards changing cpu params.
PS You get permission denied with sudo because you elevate the echo 1 and not the > shell redirection which happens as your normal user, to do it without changing to a root shell you can e.g. elevate a tee or so
echo 1 | sudo tee /sys/devices/system/cpu/cpufreq/boost sudo bash -c "echo 1 > /sys/devices/system/cpu/cpufreq/boost"
How would you exactly set this with a udev rule? I have cpupower enabled for scaling but AFAIK you can't have that enable boost.
EDIT: Got it, Thanks.
Last edited by Nan123 (2022-02-17 09:15:25)
Offline