On Sat, Jan 01, 2011 at 07:11:41PM +0100, Petr Salinger wrote: > severity 608428 important > user email@example.com > usertag 608428 + kfreebsd > -- > >> So, this looks like a bug in the mount/umount utilities and/or the >> kfreebsd mount/nmount/umount system calls. >> >> Possible explanation: there's an 80 char buffer being used which causes >> the truncation. The syscall manual pages tell us that there's a 1023 >> character restriction with 255 chars per path component. We're nowhere >> near that documented limit, so there's a serious bug somewhere. > >> I've reassigned this to freebsd-utils, which is the most likely place >> for the bug to be. I've also put the severity to serious, since this >> is a fundamental and dangerous flaw in a key system component which >> can and is causing breakage. It would be good if this could be >> fixed for squeeze. > > There is a system limit in > > http://www.freebsd.org/cgi/cvsweb.cgi/src/sys/sys/mount.h > > #define MNAMELEN 88 /* size of on/from name bufs */ > > We cannot do much with this limit :-( Thanks for the information. That's unfortunate--I imagine simply changing it would break ABI quite badly? Is the use of statfs widespread beyond the core system components such as mount etc.? Looking at the Linux equivalents in <bits/statfs.h>, these versions simply don't include any fixed-length character arrays and so avoid the problem entirely. It's really rather odd that the userspace structures (assuming FreeBSD doesn't use the same header for the kernel too, which I'm not sure is right) have such inconsistent and restrictive lengths compared with what's technically permitted by the actual mount/umount system calls. From the schroot perspective, I can mitigate this a bit by using shorter session names without using UUIDs, but this is only masking the problem--it'll occasionally break when users want to mount things deeper inside the chroot environment. Regards, Roger -- .''`. Roger Leigh : :' : Debian GNU/Linux http://people.debian.org/~rleigh/ `. `' Printing on GNU/Linux? http://gutenprint.sourceforge.net/ `- GPG Public Key: 0x25BFB848 Please GPG sign your mail.
Description: Digital signature