Note: This bug is displayed in read-only format because
the product is no longer active in Red Hat Bugzilla.
RHEL Engineering is moving the tracking of its product development work on RHEL 6 through RHEL 9 to Red Hat Jira (issues.redhat.com). If you're a Red Hat customer, please continue to file support cases via the Red Hat customer portal. If you're not, please head to the "RHEL project" in Red Hat Jira and file new tickets here. Individual Bugzilla bugs in the statuses "NEW", "ASSIGNED", and "POST" are being migrated throughout September 2023. Bugs of Red Hat partners with an assigned Engineering Partner Manager (EPM) are migrated in late September as per pre-agreed dates. Bugs against components "kernel", "kernel-rt", and "kpatch" are only migrated if still in "NEW" or "ASSIGNED". If you cannot log in to RH Jira, please consult article #7032570. That failing, please send an e-mail to the RH Jira admins at rh-issues@redhat.com to troubleshoot your issue as a user management inquiry. The email creates a ServiceNow ticket with Red Hat. Individual Bugzilla bugs that are migrated will be moved to status "CLOSED", resolution "MIGRATED", and set with "MigratedToJIRA" in "Keywords". The link to the successor Jira issue will be found under "Links", have a little "two-footprint" icon next to it, and direct you to the "RHEL project" in Red Hat Jira (issue links are of type "https://issues.redhat.com/browse/RHEL-XXXX", where "X" is a digit). This same link will be available in a blue banner at the top of the page informing you that that bug has been migrated.
Created attachment 577350[details]
patch for utils/mountd/cache.c
Description of problem:
On our file server cluster we have many exports with individual netgroups. On some clients it is not possible to mount some shares. What we get is the following error message on the server:
Apr 12 12:04:22 srv rpc.mountd[12143]: qword_printhex: fwrite failed: errno 22 (Invalid argument)
Apr 12 12:04:22 srv rpc.mountd[12143]: qword_eol: fflush failed: errno 22 (Invalid argument)
Apr 12 12:04:22 srv rpc.mountd[12143]: Cannot export /export/..., possibly unsupported filesystem or fsid= required
We have tracked down the problem to this commit which is missing in the
nfs-utils in RHEL 6.2:
http://git.linux-nfs.org/?p=steved/nfs-utils.git;a=commitdiff;h=5604b35a61e22930873ffc4e9971002f578e7978
This patch alone does not solve the problem though. The two functions
cache_export() and cache_export_ent() in utils/mountd/cache.c must also
be modified to get a larger buffer via setvbuf(). A patch is attached to
this report.
Version-Release number of selected component (if applicable):
nfs-utils-1.2.3-15.el6.x86_64
The additional patch is not present in upstream and should probably be added there too.
Additional info:
The reason why this is triggered at our site is similar to the one of the following bug I reported against RHEL4 long ago here:
https://lkml.org/lkml/2007/7/30/116
Basically rpc.mountd builds a long string with netgroups and the first
1024 bytes of the incomplete string are flushed by stdio:
12295 open("/proc/net/rpc/auth.unix.ip/channel", O_WRONLY|O_CREAT|O_TRUNC, 0666) = 12
12295 fstat(12, {st_mode=S_IFREG|0600, st_size=0, ...}) = 0
12295 mmap(NULL, 4096, PROT_READ|PROT_WRITE, MAP_PRIVATE|MAP_ANONYMOUS, -1, 0) = 0x7ffabf567000
12295 write(12, "nfsd x.x.x.x 1334318187 *,@aadiya,@akourtis,@akreutz,@aligma,@alonso,@amamin,@amarfurt,@amoga,@antoinek,@asinghan,@azachary,@azala,@baslergi,@baumanan,@baumanmo,@bcagri,@blukas,@brams,@briangol,@"..., 1024) = -1 EINVAL (Invalid argument)
12295 sendto(11, "<28>Apr 13 13:26:27 rpc.mountd[12295]: qword_print: fwrite failed: errno 22 (Invalid argument)", 94, MSG_NOSIGNAL, NULL, 0) = 94
12295 write(12, "\n", 1) = -1 EINVAL (Invalid argument)
12295 sendto(11, "<28>Apr 13 13:26:27 rpc.mountd[12295]: qword_eol: fflush failed: errno 22 (Invalid argument)", 92, MSG_NOSIGNAL, NULL, 0) = 92
12295 close(12) = 0
unfortunately we cannot acces the other bug or the KB article.
Would you mind to either add Stefan Walter and me to bug 736741, or give us a quick info if this is fixed, or what workaround exists?