#9397 automountlocation-tofiles is not working after removing indirect automount map.
Closed: fixed 11 months ago by frenaud. Opened a year ago by rjeffman.

Issue

When removing an automountmap that was created with autmountmap-add-indirect with the default parent map (auto.master) the indirect key created is not removed, making automountlocation-tofiles to fail for the location.

Steps to Reproduce

[root@rhel88 ~]# ipa automountlocation-add reproducer
-------------------------------------
Added automount location "reproducer"
-------------------------------------
  Location: reproducer
[root@rhel88 ~]# ipa automountmap-add-indirect reproducer rep_map --mount indirect 
-----------------------------
Added automount map "rep_map"
-----------------------------
  Map: rep_map
[root@rhel88 ~]# ipa automountlocation-tofiles reproducer
/etc/auto.master:
/-  /etc/auto.direct
indirect    /etc/rep_map
---------------------------
/etc/auto.direct:
---------------------------
/etc/rep_map:

maps not connected to /etc/auto.master:
[root@rhel88 ~]# ipa automountmap-del reproducer rep_map
-------------------------------
Deleted automount map "rep_map"
-------------------------------
[root@rhel88 ~]# ipa automountlocation-tofiles reproducer
ipa: ERROR: rep_map: automount map not found

Version/Release/Distribution

[root@rhel88 ~]# rpm -q ipa-server ipa-client 389-ds-base krb5-server
ipa-server-4.9.11-5.module+el8.8.0+18146+a1d8660b.x86_64
ipa-client-4.9.11-5.module+el8.8.0+18146+a1d8660b.x86_64
389-ds-base-1.4.3.32-3.module+el8.8.0+17706+8ab0c717.x86_64
krb5-server-1.18.2-22.el8_7.x86_64

Additional info:

The key created for the indirect map is still available, and to fix the environment it must be explicitly removed.

[root@rhel88 ~]# ipa automountkey-find reproducer auto.master
------------------------
2 automount keys matched
------------------------
  Key: /-
  Mount information: auto.direct

  Key: indirect
  Mount information: rep_map

If not using auto.master as the parent map, if the parent map is not connected to auto.master, the location still works, but a key is also not removde.


Metadata Update from @rcritten:
- Issue assigned to rcritten

a year ago

master:

  • d98d5e4 Remove all references to deleted indirect map from parent map

ipa-4-10:

  • 9762c87 Remove all references to deleted indirect map from parent map

ipa-4-9:

  • 2c402c4 Remove all references to deleted indirect map from parent map

Metadata Update from @frenaud:
- Issue close_status updated to: fixed
- Issue status updated to: Closed (was: Open)

11 months ago

Log in to comment on this ticket.

Metadata