O'Reilly logo

Hands-On System Programming with Linux by Kaiwan N Billimoria

Stay ahead with the world's most comprehensive technology and business learning platform.

With Safari, you learn the way you learn best. Get unlimited access to videos, live online training, learning paths, books, tutorials, and more.

Start Free Trial

No credit card required

Viewing process capabilities via procfs

To understand more details, we need a quick way to "look into" the kernel and retrieve information; the Linux kernel's proc filesystem (often abbreviated to procfs) provides just this feature (along with more).

Procfs is a pseudo-filesystem typically mounted on /proc. Exploring procfs to learn more about Linux is a great idea; do check out some links in the Further reading section on the GitHub repository.

Here, we shall just focus on the task at hand: to get to the details, procfs exposes a directory called /proc/self (which refers to the current process's context, somewhat analogous to the this pointer in OOP); under it, a pseudo file named status reveals interesting details about the process (or ...

With Safari, you learn the way you learn best. Get unlimited access to videos, live online training, learning paths, books, interactive tutorials, and more.

Start Free Trial

No credit card required