Bug 463578

Summary: confusing 'mount request from unknown host' messages
Product: Red Hat Enterprise Linux 5 Reporter: Jeff Bastian <jbastian>
Component: nfs-utilsAssignee: Jeff Layton <jlayton>
Status: CLOSED ERRATA QA Contact: Martin Jenner <mjenner>
Severity: medium Docs Contact:
Priority: medium    
Version: 5.2CC: jiyin, jscotka, staubach, steved, tao
Target Milestone: rc   
Target Release: ---   
Hardware: All   
OS: Linux   
Whiteboard:
Fixed In Version: Doc Type: Bug Fix
Doc Text:
Story Points: ---
Clone Of: Environment:
Last Closed: 2009-09-02 10:03:04 UTC Type: ---
Regression: --- Mount Type: ---
Documentation: --- CRM:
Verified Versions: Category: ---
oVirt Team: --- RHEL 7.3 requirements from Atomic Host:
Cloudforms Team: --- Target Upstream Version:
Embargoed:
Bug Depends On:    
Bug Blocks: 612790    
Attachments:
Description Flags
patch -- change message to read "unmatched host" none

Description Jeff Bastian 2008-09-23 21:43:23 UTC
+++ This bug was initially created as a clone of Bug #430141 +++

rpc.mountd leaves confusing messages in the logs when a client not listed in to /etc/exports makes a mount request:
  mount request from unknown host foo.example.com for /export (/export)

To a system administrator, "unknown host" means a name lookup failure from DNS/NIS/LDAP/local-files, which is not the case.

Please change the message to something like
  mount request from unlisted host %s for %s (%s): not in /etc/exports

Alternatively, please provide a more detailed explanation of what the message means in the rpc.mountd(8) man page.




--- Additional comment from jlayton on 2008-01-25 07:31:28 EDT ---

> Maybe "unknown" does NOT mean a DNS lookup failure, but rather, it means the
> host was not listed in /etc/exports, therefore it's unknown.

Correct. mountd has a list of hosts that it knows that it builds from
/etc/exports. If the mount request doesn't match any of those hosts, then you'll
get the "unknown host" message. If the host is "known", but tries to mount an
export to which it doesn't have access, or if the directory just isn't exported,
you'll get the no_entry or not_exported error messages.

Granted, mountd's error messages are a bit cryptic. They probably could do with
some cleanup. I'll have to think about what makes the most sense. We want to
convey *why* the mount request failed in this error message, without confusing
the user. I'm not sure that "unauthorized host" really conveys the fact that the
ip addr doesn't match any host entries in the exports file.

I'll need to ponder this a bit...


--- Additional comment from jlayton on 2008-05-28 08:59:59 EDT ---

...maybe:

mount request from unlisted host %s for %s (%s)

Comment 1 Jeff Layton 2008-09-29 11:32:26 UTC
...or maybe "unmatched" host (since the host needn't be explicitly listed).

Comment 2 Jeff Layton 2008-09-29 12:15:22 UTC
Created attachment 317964 [details]
patch -- change message to read "unmatched host" 

Here's the patch I pushed upstream. Awaiting feedback.

Comment 3 Jeff Layton 2008-09-29 19:21:19 UTC
Patch taken upstream. Going ahead and acking this for 5.4.

Comment 5 Jeff Layton 2009-02-12 19:34:34 UTC
Committed in nfs-utils-1.0.9-41.el5

Comment 9 errata-xmlrpc 2009-09-02 10:03:04 UTC
An advisory has been issued which should help the problem
described in this bug report. This report is therefore being
closed with a resolution of ERRATA. For more information
on therefore solution and/or where to find the updated files,
please follow the link below. You may reopen this bug report
if the solution does not work for you.

http://rhn.redhat.com/errata/RHSA-2009-1321.html