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.

Bug 2214444

Summary: The sss lookup modules handles error return incorrectly in some cases
Product: Red Hat Enterprise Linux 8 Reporter: Ian Kent <ikent>
Component: autofsAssignee: Ian Kent <ikent>
Status: CLOSED ERRATA QA Contact: Kun Wang <kunwan>
Severity: medium Docs Contact:
Priority: unspecified    
Version: 8.8CC: pbrezina, xzhou
Target Milestone: rcKeywords: Triaged
Target Release: ---Flags: pm-rhel: mirror+
Hardware: All   
OS: Unspecified   
Whiteboard:
Fixed In Version: autofs-5.1.4-106.el8 Doc Type: If docs needed, set a value
Doc Text:
Story Points: ---
Clone Of:
: 2215661 (view as bug list) Environment:
Last Closed: 2023-11-14 15:48:36 UTC Type: Bug
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: 2215661    
Attachments:
Description Flags
Patch - fix some sss error return cases none

Description Ian Kent 2023-06-13 02:03:39 UTC
Description of problem:
The autofs sss lookup module handles error returns incorrectly in some cases.
This leads to automount not waiting for a host to become available (if it's down at the time the master map read is attempted) so that a map not found error is returned when it shouldn't be, for example the "automount -m" command.

Version-Release number of selected component (if applicable):
Current version of autofs.

Comment 1 Ian Kent 2023-06-13 02:16:16 UTC
It's not that easy to reproduce this problem because an ldap server
needs to be setup to provide autofs map information to a client setup
to use sss. What makes it even harder is that the ldap server needs
to be down and then be started up to test the functionality.

But if this is done then an "automount -m" command to read and
list the available maps should wait for a period of time before
giving up or succeeding as the case may be.


Fortunately, since Pavel would like to be able to verify this during
sss testing, we should be able to get help with testing.

Ian

Comment 2 Ian Kent 2023-06-13 02:19:09 UTC
Created attachment 1970553 [details]
Patch - fix some sss error return cases

This is currently against the upstream source and is completely untested.

Comment 4 Ian Kent 2023-06-19 01:49:26 UTC
Pavel,

autofs revision 106 is included in the most recent composes.
For example:
https://download.eng.bos.redhat.com/rhel-8/composes/RHEL-8/RHEL-8.9.0-20230618.d.21/compose/BaseOS/x86_64/os/Packages/autofs-5.1.4-106.el8.x86_64.rpm

You could get the debugsource and debuginfo packages from:
https://download.eng.bos.redhat.com/brewroot/packages/autofs/5.1.4/106.el8/x86_64/

if you needed them, in fact you could get all the packages for there.

Would you be able to check if this change helps with the error reporting
you were asking about please?

Comment 10 errata-xmlrpc 2023-11-14 15:48:36 UTC
Since the problem described in this bug report should be
resolved in a recent advisory, it has been closed with a
resolution of ERRATA.

For information on the advisory (autofs bug fix and enhancement update), and where to find the updated
files, follow the link below.

If the solution does not work for you, open a new bug report.

https://access.redhat.com/errata/RHBA-2023:7098

Comment 11 Pavel Březina 2024-01-22 11:24:10 UTC
Clearing need info.