Take the 2-minute tour ×
Server Fault is a question and answer site for professional system and network administrators. It's 100% free, no registration required.

I know both /proc, and /sys are virtual file-structures with pseudo files used to communicate with the kernel, but what is the difference between /proc/sys/kernel, and /sys/kernel - what is the division of power. And, is there a centralized man page for what the stuff in /sys/kernel means (like man 5 proc)?

For instance, /sys/kernel/uevent_seqnum ? I'm sure this is a highly esoteric option that no one should change? But, what does it do? Is there a man page that might have this stuff in easily accessible layman form? If the first step isn't greping the kernel source, where would you go to find out what uevent_seqnum does?

share|improve this question
add comment

1 Answer 1

up vote 6 down vote accepted

Essentially /proc and /sys are the same.

sysfs was added in kernel 2.5 or 2.6 due to clutter in procfs

The procfs was only meant to hold process information. eventually everything started getting mixed into proc and it created a twisty maze with device data stuck in different spots all over the place. Meanwhile, sysfs was implemented with the objective of segmenting device data from procfs.

Specifically, /sys maintains more detailed (position of nodes actually represents the device hierarchy by subsystem) device process information. For each object in the driver model, a directory is created. The device file structure being:

/sys/devices  - devices by physical layout
/sys/bus      - symbolic links to devices
/sys/block    - devices by block
/sys/class    - devices by class

On your local system you might find man page at man sysfs

If you want even more information about /sys, you might want to lookup 'sysctl' from BSD and view the whitepaper on kernel.org [pdf]

For even more verbose information (and if you dont mind looking at the source) you can lookup the ident variable name at kerlabs, specifically uevent_seqnum

share|improve this answer
    
I've upvoted, but the difference is really just a subjective, "more detail"? Just to clairify, there is still no documentation locally installed that will help explain uevent_seqnum? It seems to me like spreading clutter across to directories without reason or cause is a bad idea. I know what sysctl, does - Ironically I most often use it to change shmax, which is fine-detail and accessible through /proc/sys/kernel. –  Evan Carroll Sep 14 '09 at 18:39
    
finished answer. accidental hit post halfway through. all in all, you might as well just use procfs for anything not device related. –  Greg Buehler Sep 14 '09 at 19:05
add comment

Your Answer

 
discard

By posting your answer, you agree to the privacy policy and terms of service.

Not the answer you're looking for? Browse other questions tagged or ask your own question.