On Tue, Feb 08, 2000 at 10:13:50PM +0000, Ronan Mullally wrote:
It looks like Linux may be the culprit. I've been able to create pipes using NFS v2 and v3 on my HP-UX boxes, and you and others have had no problems with FreeBSD and Solaris. I'll follow it up with the Linux folks...
Linux is indeed the culprit. I did a little investigating and this behavior is coded into the Linux kernel itself. Here are some details...
It looks like when defining the filesystem type in the Linux kernel, filesystems which allow mounting with the "dev" ("mount -o dev ...") option needs to be specified with the "FS_REQUIRES_DEV" flag.
I checked both the latest stable (2.2.14) and development (2.3.42) kernels and found this in fs/nfs/inode.c:
/* * File system information */ static struct file_system_type nfs_fs_type = { "nfs", 0 /* FS_NO_DCACHE - this doesn't work right now*/, nfs_read_super, NULL };
Compare this to a filesystem which allows the "dev" option to mount (in fs/ext2/super.c):
static struct file_system_type ext2_fs_type = { "ext2", FS_REQUIRES_DEV /* | FS_IBASKET */, /* ibaskets have unresolved bugs */ ext2_read_super, NULL };
So basically, whatever you do with "mount" from the user command regarding "dev" or "nodev" with an NFS filesystem will have no effect in the Linux kernel; it will always be "nodev".
I don't know why it is done this way. I'm guesssing that it could be deemed a security hazzard to allow interpretting special devices over NFS, so making an NFS mount permanently "nodev" is one possible solution.
You *might* be able to put "FS_REQUIRES_DEV" for nfs_fs_type, but I have no idea if this will work or what other problems it could cause. Someone will have to check with the Linux kernel folks on this one.
regards, --andy