Hi, On Monday 21 of March 2011 12:07:06 you wrote: > The ".nilfs" file is used for two purposes: > > 1) As the file on which the nilfs library issues ioctls. > > 2) For advisory locks (i.e. fcntl(F_GETLK/F_SETLK/FSETLKW)). This > works as a mutex between the cleaner and other nilfs-tools. > > Note that the nilfs2 kernel code never uses the .nilfs file; it's just > a regular file for nilfs2. > > As for the item (1), we can use the root directory of each filesystem > instead. And for (2), a Posix semaphore or other lock primitives may > be available. I tried but failed; it seems Linux doesn't allow opening directory O_RDWR or O_WRONLY. And a modyfying ioctl() on directory opened O_RDONLY also returned some error, I think it was EBADF. I did not dig any further, so I dunno if that's done by kernel's general code or NILFS' ioctl() handler. I believe nilfs_cleanerd could, on principle, use file descriptor of any file on the filesystem in case the user runs into a full fylesystem. Kernel code handles that OK, only nilfs_cleanerd would need an extra argument to open a different file. What's your oppinion on that? Regards, -- dexen deVries [[[â][â]]] ``In other news, STFU and hack.'' mahmud, in response to Erann Gat's ``How I lost my faith in Lisp'' http://news.ycombinator.com/item?id=2308816 -- To unsubscribe from this list: send the line "unsubscribe linux-nilfs" in the body of a message to majordomo@xxxxxxxxxxxxxxx More majordomo info at http://vger.kernel.org/majordomo-info.html