Re: size of files in /proc

Ton Hospel (
19 May 1998 23:38:58 GMT

In article <6jt14r$n32$>, (H. Peter Anvin) writes:
> Followup to: <6jsu4j$1g4$>
> By author: (Ton Hospel)
> In newsgroup:
>> But even then I'd like /proc to report the unknown sizes as 1, not 0.
>> Because I like to be able to export /proc over NFS, and NFS doesn't even
>> bother to read the file if the size is 0.
> Forget it. I hear this idea every now and then, and it is almost
> always the Wrong Thing[TM] to do. Especially given the wacko
> characteristics of NFS -- you're basically horked if it isn't
> something that is truly like a file.
> -hpa

So what ? Caveat emptor. It will work for the things it will work for
(which is quite a few in fact).

The point is that behaving as if a file is empty if the length is
zero is perfectly valid behaviour independent of NFS.
That NFS might later screw up in other ways is NFS's problem, but not
good enough to not do something about the proc lengths.
(think about exporting /proc over other remote file systems if that makes
it more convincing for you)

To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to