SlackwareThis Forum is for the discussion of Slackware Linux.
Welcome to LinuxQuestions.org, a friendly and active Linux Community.
You are currently viewing LQ as a guest. By joining our community you will have the ability to post topics, receive our newsletter, use the advanced search, subscribe to threads and access many other special features. Registration is quick, simple and absolutely free. Join our community today!
Note that registered members see fewer ads, and ContentLink is completely disabled once you log in.
If you have any problems with the registration process or your account login, please contact us. If you need to reset your password, click here.
Having a problem logging in? Please visit this page to clear all LQ-related cookies.
Introduction to Linux - A Hands on Guide
This guide was created as an overview of the Linux Operating System, geared toward new users as an exploration tour and getting started guide, with exercises at the end of each chapter.
For more advanced trainees it can be a desktop reference, and a collection of the base knowledge needed to proceed with system and network administration. This book contains many real life examples derived from the author's experience as a Linux system and network administrator, trainer and consultant. They hope these examples will help you to get a better understanding of the Linux system and that you feel encouraged to try out things on your own.
Click Here to receive this Complete Guide absolutely free.
/proc/partitions shows you the partitions you have. You don't change /proc/partitions directly.
Tools such as fdisk, sfdisk, parted, and others modify the partitions you have.
Type "man fdisk" for more details of how to use fdisk. (or man sfdisk or man parted for those utilities)
Type "man proc" for details of the information provided under /proc.
Mostly this is for information gathering. There are SOME things that can be modified by writing into /proc but not much and not much you would want to try without very deep understanding of how to do that.
Accepting no responsibility for the outcome, one obvious thing is to change the permission on the file and then attempt to edit it. Since it is really a virtual file--existing only in memory--I think this would be a struggle for control with the kernel. My money says the kernel will win---I just don't know what the casualties will be.....
if anyone could manage to damage the system by mangling a /proc "file" it would be a reportable bug
Not sure I buy that - I've seen solutions for updating /proc/scsi by writing into it. If you can write presumably good information into it you would likely be able to crap out something by writing bad information into it. Not something I want to test at the moment though.
If using "rm -rf /" can damage your system without being a "bug" then it seems doing boneheaded writes into /proc wouldn't be a "bug" either.
Different situation - /proc is just an abstraction to allow kernel/driver code to expose data. Any directories/files needed have to be created and destroyed by that code.
Most are read only, but write is supported. But it's just a buffer for that bit of code. If it can't handle bad data/requests, it's a bug. Especially in kernel code.