Read / Write access to `/sys/kernel/` files not permitted?
First time poster, newbie linux enthusiast here. I'll cut right to the chase:
On a fresh install of Ubuntu 18.04.04: why don't I (as the root user) have read /
write access to the files in
/sys/kernel/? Any pointers in the right directions
would be greatly appreciated.
I didn't see any guidelines for posting etiquette so I'll do my best to follow Eric S. Raymond and Rick Moen's "How to ask smart questions essay".
I was curious about the devices that were mounted on my computer so I ran the following:
$ mount > filesystems.txt
and came across
..other file systems.. securityfs on /sys/kernel/security type securityfs (rw,nosuid,nodev,noexec,relatime) ..other file systems..
I wanted to see the contents of this directory so I ran the following:
$ sudo less /sys/kernel/security/integrity/ima/policy
and got this message:
/sys/kernel/security/integrity/ima/policy: Permission denied
I tried openning another file in the
/sys/kernel/ directory and got the same
Permission denied message. I didn't find any results on the web so, as a
final attempt, booted a fresh install of Ubuntu from a flash drive, tried
openning another file in
/sys/kernel/, and got the same error.
Any ideas on why Ubuntu limits access to this directory? Thanks again for being
a part of this community - any pointers in the right direction would be