whatis sysfs
/sys (sysfs)
Also known as: sysfs
A virtual filesystem that exposes the kernel's view of devices, drivers, and buses as a structured directory tree.
What Is /sys (sysfs) in Linux?
Where /proc grew organically around processes, /sys is organized around the device model. You can read a battery's charge, a disk's scheduler, or a network card's driver by browsing directories under /sys/class and /sys/block.
Some files are writable and change hardware behavior immediately, such as screen brightness or CPU frequency governors. udev watches sysfs events to create device nodes and run rules.
Example
cat /sys/class/power_supply/BAT0/capacity Learn more about /sys (sysfs)
- sysfs Explained: What /sys Is and How to Read It procfs is about processes. sysfs is about devices, drivers and the kernel object model, and almost every tuning knob people paste into a terminal is a file in here. How it is organised and how to change things so they survive a reboot.
- CPU Frequency Scaling and Governors: schedutil, the Intel Driver and EPP Your CPU does not run at its rated speed most of the time. Which driver you have decides which governors exist, why Intel systems only offer two, what energy performance preference actually controls, and when any of this is worth changing.
- udev Rules Explained: Making Devices Behave the Way You Want Device names are not stable, permissions default to root, and nothing happens automatically when you plug something in unless you tell it to. udev rules fix all three.