2.2.0 : NFS quotas
David Lee
T.D.Lee at durham.ac.uk
Thu Apr 26 17:46:21 GMT 2001
Sorry that the following is so vague. I hope to hope able to dig deeper
in the next week or so, but cannot promise, so I thought I ought to flag
up the issue.
Under 2.2.0, on our Solaris 2.x systems, I've been seeing smbd sometimes
disappearing. I have a sneaky suspicion that the new "quotas over NFS"
functionality might be involved.
File: "smbd/quotas.c"
For instance, at line 341:
if ((clnt = clnt_create(host, RQUOTAPROG, RQUOTAVERS, "udp")) != NULL) {
suppose this fails? Then "clnt" will be NULL.
I suspect the code ought to arrange to "return(False)" fairly swiftly, but
it doesn't.
Perhaps the intention is to pick this up at line 364:
if (quotastat == 0 || quotastat == 3) {
But if so, the "return(False)" inside the expected "if {...}" would seem
to be missing. (And anyway, is it safe to rely on this condition for the
previous condition?)
It seems that following such a failure, there is a reasonable chance that
the code could still reach lines 378ff, which assumes that everything has
been OK, when it hasn't. Indeed by line 398:
auth_destroy(clnt->cl_auth);
it might try to follow off the NULL clnt and segfault...
[ Also, line 389:
if (D.dqb_curblocks == D.dqb_curblocks == 1)
looks peculiar. ]
My apologies again that this is so vague (and further apologies if the
code is fine and I am unjustly maligning it).
--
: David Lee I.T. Service :
: Systems Programmer Computer Centre :
: University of Durham :
: http://www.dur.ac.uk/t.d.lee/ South Road :
: Durham :
: Phone: +44 191 374 2882 U.K. :
More information about the samba-technical
mailing list