Date: Sun, 5 Jul 1998 04:56:49 -0300 (EST) From: Joao Carlos Mendes Luis <jonny@jonny.eng.br> To: seggers@semyam.dinoco.de (Stefan Eggers) Cc: jonny@jonny.eng.br, seggers@semyam.dinoco.de, hackers@FreeBSD.ORG Subject: Re: accton on a append-only file ? Message-ID: <199807050756.EAA03879@roma.coe.ufrj.br> In-Reply-To: <199807041545.RAA13938@semyam.dinoco.de> from Stefan Eggers at "Jul 4, 98 05:45:36 pm"
next in thread | previous in thread | raw e-mail | index | archive | help
#define quoting(Stefan Eggers) // > I've created the /var/account/acct file with sappend,sunlink flags, // > but accton return EPERM. If I run accton before setting those flags, // // > This seems to be a bug, but I still have much to learn from VFS // // To me, too. It is because kern_acct.c in 2.2-stable opens the file // for writing, not for appending. There is the problem: // // /* // * If accounting is to be started to a file, open that file for // * writing and make sure it's a 'normal'. // */ // if (uap->path != NULL) { // NDINIT(&nd, LOOKUP, NOFOLLOW, UIO_USERSPACE, uap->path, p); // error = vn_open(&nd, FWRITE, 0); // if (error) // return (error); // // // Unless there is already a PR for this (check the PR database on the // FreeBSD web pages) I'd suggest sending in a new one. I've just sent it. It's kern/7169. // > before searching for the culprit myself. Does it deserve a send-pr, // > even without patches ? // // I think it's as easy as adding FAPPEND to the mode. The only problem // is making sure that it has no unexpected side effects. If you like // quote this email in the PR to point at a possible way to fix it. This worked for me at home. But since file writing at kernel level is somewhat tricky, I'd be a lot more happy if some FS expert verified it before commiting. If it's safe, please don't forget -stable, folks. :) Jonny -- Joao Carlos Mendes Luis M.Sc. Student jonny@jonny.eng.br Universidade Federal do Rio de Janeiro "There are two major products that come out of Berkeley: LSD and Unix. We don't believe this to be a coincidence." -- Jeremy S. Anderson To Unsubscribe: send mail to majordomo@FreeBSD.org with "unsubscribe freebsd-hackers" in the body of the message
Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?199807050756.EAA03879>