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 1497846 - autofs option parsing for maps with fstype=autofs no longer works
Summary: autofs option parsing for maps with fstype=autofs no longer works
Keywords:
Status: CLOSED ERRATA
Alias: None
Product: Red Hat Enterprise Linux 7
Classification: Red Hat
Component: autofs
Version: 7.4
Hardware: Unspecified
OS: Unspecified
urgent
unspecified
Target Milestone: rc
: ---
Assignee: Ian Kent
QA Contact: xiaoli feng
URL:
Whiteboard:
: 1498443 (view as bug list)
Depends On:
Blocks: 1420851 1469559 1503945
TreeView+ depends on / blocked
 
Reported: 2017-10-02 20:50 UTC by Frank Sorenson
Modified: 2021-03-11 15:54 UTC (History)
7 users (show)

Fixed In Version: autofs-5.0.7-71.el7
Doc Type: If docs needed, set a value
Doc Text:
Clone Of:
: 1503945 (view as bug list)
Environment:
Last Closed: 2018-04-10 18:17:12 UTC
Target Upstream Version:
Embargoed:


Attachments (Terms of Use)
Patch - revert fix argc off by one in mount_autofs.c (1.41 KB, patch)
2017-10-03 02:34 UTC, Ian Kent
no flags Details | Diff


Links
System ID Private Priority Status Summary Last Updated
Red Hat Product Errata RHBA-2018:0977 0 None None None 2018-04-10 18:18:00 UTC

Description Frank Sorenson 2017-10-02 20:50:49 UTC
Description of problem:

Macro definitions which are specified as options to the mount entry are not being set, and are therefore not available for use in substitutions.


Version-Release number of selected component (if applicable):
  autofs-5.0.7-69.el7.x86_64


How reproducible:
  see below

Steps to Reproduce:

samba server with share
  //server/share


auto.master:
/smb    /etc/auto.cifs.top --negative-timeout=1 --timeout=20

auto.cifs.top:
*       -fstype=autofs,-Dhname=& file:/etc/auto.cifs.sub


auto.cifs.sub:
*       -fstype=cifs,credentials=/root/cifs_mount_creds,noserverino,nounix  ://$hname/&


# ls /smb/server/share


Actual results:

ls: cannot access /smb/server/share: No such file or directory


the 'hname' macro is not defined in the table, so the '$hname' is replaced by an empty string when used in 'auto.cifs.sub'


Expected results:

'hname' macro gets defined, and is available 


Additional info:

this has worked in previous autofs versions

Comment 2 Ian Kent 2017-10-03 02:33:52 UTC
(In reply to Frank Sorenson from comment #0)
> Description of problem:
> 
> Macro definitions which are specified as options to the mount entry are not
> being set, and are therefore not available for use in substitutions.

Indeed they aren't.

It seems a "fix" I added actually introduced a regression.
 
Ian

Comment 3 Ian Kent 2017-10-03 02:34:58 UTC
Created attachment 1333480 [details]
Patch - revert fix argc off by one in mount_autofs.c

Comment 5 Ian Kent 2017-10-04 11:39:33 UTC
*** Bug 1498443 has been marked as a duplicate of this bug. ***

Comment 7 smazul 2017-10-09 17:56:48 UTC
Hello,

I understand that has been a commit that has seemingly resolved the issue. Customer in case 01940146 is interested in any potential test package that has result from this commit. Understanding that this seems to be in package 5.0.7-71 I do not observe this to be GA. Apologies if I am misunderstanding the current state.

Thanks

Comment 8 Ian Kent 2017-10-09 23:15:39 UTC
(In reply to smazul from comment #7)
> Hello,
> 
> I understand that has been a commit that has seemingly resolved the issue.
> Customer in case 01940146 is interested in any potential test package that
> has result from this commit. Understanding that this seems to be in package
> 5.0.7-71 I do not observe this to be GA. Apologies if I am misunderstanding
> the current state.

Right, the process is that changes are committed and built into
a package during the release development phase, following development
the release enters testing phase where QA verifies changed packages
and finally it gets to a GA release.

All of this can take quite a while.

We can give the customer revision 71 (or the current latest revision)
but that package can have other changes that have seen limited testing
and isn't (strictly speaking) supported. Also the package may have
further changes from the development phase or the testing phase so
it may not (and likely won't) be the package that is released at
GA.

Locate the support documentation on providing an accelerated fix
for the options and requirements for delivering an appropriate
package to the customer.

Ian

Comment 16 Dave Wysochanski 2017-10-18 19:39:17 UTC
Now that I look at this patch it looks to me like this will affect option parsing which goes far beyond macro definitions.  If I'm understanding correctly, effectively the bug is that the last 'option' in the chain gets ignored, so it could be any option in the list.  I'm going to do a few more tests.  If this is true, then an effective workaround may just be to add a garbage option at the end, which will be ignored.

Comment 18 Dave Wysochanski 2017-10-18 20:14:36 UTC
BTW, I verified a simple 'ro' got ignored so it definitely is a more generic problem as the patch reads.  For some reason adding a garbage option at the end does not work around the problem so there's something I'm missing there.

Comment 29 errata-xmlrpc 2018-04-10 18:17:12 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, 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-2018:0977


Note You need to log in before you can comment on or make changes to this bug.