Bug 1164064
| Summary: | RHEL-7.1 regression fail: service nfs-idmapd start fail | ||
|---|---|---|---|
| Product: | Red Hat Enterprise Linux 7 | Reporter: | JianHong Yin <jiyin> |
| Component: | nfs-utils | Assignee: | Steve Dickson <steved> |
| Status: | CLOSED ERRATA | QA Contact: | Yongcheng Yang <yoyang> |
| Severity: | urgent | Docs Contact: | |
| Priority: | urgent | ||
| Version: | 7.1 | CC: | eguan, lzap, myamazak, steved, tak-nishimura, tlavigne, urkedal |
| Target Milestone: | rc | Keywords: | Regression, Reopened, TestBlocker |
| Target Release: | --- | ||
| Hardware: | All | ||
| OS: | Linux | ||
| Whiteboard: | |||
| Fixed In Version: | nfs-utils-1.3.0-0.12.el7 | Doc Type: | Bug Fix |
| Doc Text: | Story Points: | --- | |
| Clone Of: | Environment: | ||
| Last Closed: | 2015-11-19 04:28:24 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: | 1149911, 1225315 | ||
|
Description
JianHong Yin
2014-11-14 03:07:54 UTC
This works for me
rhel7# systemctl restart nfs-idmapd
rhel7# systemctl status nfs-idmapd
nfs-idmapd.service - NFSv4 ID-name mapping service
Loaded: loaded (/usr/lib/systemd/system/nfs-idmapd.service; static)
Active: active (running) since Thu 2014-12-04 12:14:46 EST; 4s ago
Process: 3241 ExecStart=/usr/sbin/rpc.idmapd $RPCIDMAPDARGS (code=exited, status=0/SUCCESS)
Main PID: 3242 (rpc.idmapd)
CGroup: /system.slice/nfs-idmapd.service
`-3242 /usr/sbin/rpc.idmapd
Dec 04 12:14:46 rhel7.boston.devel.redhat.com systemd[1]: Started NFSv4 ID-na...
Hint: Some lines were ellipsized, use -l to show in full.
Also there is no longer a need to start the nfs-idmapd service explicitly. The daemon is automatically started by the nfs-server service. Always fail in our test cases; ** But works fine in RHEL-7.0 released [16:48:52 root@ ~~]# grep "^[^#]" /etc/idmapd.conf [General] Verbosity = 2 Domain = [Mapping] [Translation] [Static] [UMICH_SCHEMA] LDAP_server = ldap-server.local.domain.edu LDAP_base = dc=local,dc=domain,dc=edu :: [ PASS ] :: Running 'grep "^[^#]" /etc/idmapd.conf' (Expected 0, got 0) -------------------------------------------------------------------------------- [16:48:52 root@ ~~]# service_rpcidmapd restart Redirecting to /bin/systemctl restart nfs-idmapd.service Job for nfs-idmapd.service failed. See 'systemctl status nfs-idmapd.service' and 'journalctl -xn' for details. -- Logs begin at Wed 2015-01-07 16:44:18 CST, end at Wed 2015-01-07 16:48:52 CST. -- Jan 07 16:48:52 ibm-x3250m4-06.rhts.eng.nay.redhat.com rpc.idmapd[13099]: rpc.idmapd: libnfsidmap: Realms list: '' Jan 07 16:48:52 ibm-x3250m4-06.rhts.eng.nay.redhat.com rpc.idmapd[13099]: libnfsidmap: loaded plugin /lib64/libnfsidmap/nsswitch.so for method nsswitch Jan 07 16:48:52 ibm-x3250m4-06.rhts.eng.nay.redhat.com rpc.idmapd[13099]: rpc.idmapd: libnfsidmap: loaded plugin /lib64/libnfsidmap/nsswitch.so for method nsswitch Jan 07 16:48:52 ibm-x3250m4-06.rhts.eng.nay.redhat.com rpc.idmapd[13100]: Expiration time is 600 seconds. Jan 07 16:48:52 ibm-x3250m4-06.rhts.eng.nay.redhat.com rpc.idmapd[13100]: Opened /proc/net/rpc/nfs4.nametoid/channel Jan 07 16:48:52 ibm-x3250m4-06.rhts.eng.nay.redhat.com rpc.idmapd[13100]: Opened /proc/net/rpc/nfs4.idtoname/channel Jan 07 16:48:52 ibm-x3250m4-06.rhts.eng.nay.redhat.com rpc.idmapd[13100]: main: open(/var/lib/nfs/rpc_pipefs//nfs): No such file or directory Jan 07 16:48:52 ibm-x3250m4-06.rhts.eng.nay.redhat.com systemd[1]: nfs-idmapd.service: control process exited, code=exited status=1 Jan 07 16:48:52 ibm-x3250m4-06.rhts.eng.nay.redhat.com systemd[1]: Failed to start NFSv4 ID-name mapping service. -- Subject: Unit nfs-idmapd.service has failed -- Defined-By: systemd -- Support: http://lists.freedesktop.org/mailman/listinfo/systemd-devel -- -- Unit nfs-idmapd.service has failed. -- -- The result is failed. Jan 07 16:48:52 ibm-x3250m4-06.rhts.eng.nay.redhat.com systemd[1]: Unit nfs-idmapd.service entered failed state. :: [ FAIL ] :: Running 'service_rpcidmapd restart' (Expected 0, got 1) Test in RHEL-7.0 works fine: [16:52:21 root@ ~~]# grep "^[^#]" /etc/idmapd.conf [General] Verbosity = 2 Domain = [Mapping] [Translation] [Static] [UMICH_SCHEMA] LDAP_server = ldap-server.local.domain.edu LDAP_base = dc=local,dc=domain,dc=edu :: [ PASS ] :: Running 'grep "^[^#]" /etc/idmapd.conf' (Expected 0, got 0) -------------------------------------------------------------------------------- [16:52:22 root@ ~~]# service_rpcidmapd restart Redirecting to /bin/systemctl restart rpcidmapd.service :: [ PASS ] :: Running 'service_rpcidmapd restart' (Expected 0, got 0) (In reply to Yin.JianHong from comment #11) > Test in RHEL-7.0 works fine: > In RHEL7.1 rpc.idmapd is nolonger explicitly started. It is started by the nfs-service service. So this test is no longer valid IMHO... Test PASS in latest nfs-utils-1.3.0-0.8.el7: https://beaker.engineering.redhat.com/recipes/1781553#task27613346 [23:10:44 root@ ~~]# service_rpcidmapd restart Redirecting to /bin/systemctl restart nfs-idmapd.service :: [ PASS ] :: Running 'service_rpcidmapd restart' (Expected 0, got 0) -------------------------------------------------------------------------------- So change the WONTFIX to CURRENTRELEASE. We still see rpc.idmapd failing to start on 7.1 on some boot ups when the timing is right. It fails with the same error: Jun 02 13:59:15 lvmtest rpc.idmapd[17193]: main: open(/var/lib/nfs/rpc_pipefs//nfs): No such file or directory This is because the systemd service file for rpc.idmapd doesn't depend on the /var/lib/nfs/rpc_pipefs mount. In 7.1 the service file looks like this: cat /usr/lib/systemd/system/nfs-idmapd.service [Unit] Description=NFSv4 ID-name mapping service BindsTo=nfs-server.service Wants=nfs-config.service After=nfs-config.service [Service] EnvironmentFile=-/run/sysconfig/nfs-utils Type=forking ExecStart=/usr/sbin/rpc.idmapd $RPCIDMAPDARGS It should look like this so that it waits for the rpc_pipefs mount: [Unit] Description=NFSv4 ID-name mapping service BindsTo=nfs-server.service Wants=nfs-config.service Requires=var-lib-nfs-rpc_pipefs.mount After=nfs-config.service var-lib-nfs-rpc_pipefs.mount [Service] EnvironmentFile=-/run/sysconfig/nfs-utils Type=forking ExecStart=/usr/sbin/rpc.idmapd $RPCIDMAPDARGS Note the addition of 'Requires' and 'After' on var-lib-nfs-rpc_pipefs.mount. This is needed to ensure the race condition goes away on start-up. The proper way to reproduce the problem is as follows: systemctl stop nfs-idmapd systemctl stop var-lib-nfs-rpc_pipefs.mount systemctl start nfs-idmapd Job for nfs-idmapd.service failed. See 'systemctl status nfs-idmapd.service' and 'journalctl -xn' for details. With the correction to the service file for nfs-idmapd I proposed the above test works. Please reopen this bug and correct the service file for nfs-idmapd. Thanks Kurt Miller. According Comment 14 , reopen this bug. Hi steved, how do you think about comment 14. (In reply to Yin.JianHong from comment #15) > Thanks Kurt Miller. > > According Comment 14 , reopen this bug. > Hi steved, how do you think about comment 14. We fix the bug with this commit: commit 6efdb0440daf3ed304a3c1115f01e76e89d792a7 Author: Chris Mayo <aklhfex> Date: Fri Jan 23 10:35:32 2015 -0500 systemd: Ensure RPC pipefs is mounted before rpc.idmapd starts rpc.idmapd aborts on start-up if RPC pipefs is not present. Needed if GSS services are not used. Signed-off-by: Chris Mayo <aklhfex> Signed-off-by: Steve Dickson <steved> Thanks for fixing this. *** Bug 1225315 has been marked as a duplicate of this bug. *** Verified with nfs-utils-1.3.0-0.13.el7.x86_64
[root@hp-dl385pg8-03 ~]# systemctl stop nfs-idmapd
[root@hp-dl385pg8-03 ~]# systemctl stop var-lib-nfs-rpc_pipefs.mount
[root@hp-dl385pg8-03 ~]# systemctl start nfs-idmapd
[root@hp-dl385pg8-03 ~]# echo $?
0
[root@hp-dl385pg8-03 ~]# systemctl status nfs-idmapd
● nfs-idmapd.service - NFSv4 ID-name mapping service
Loaded: loaded (/usr/lib/systemd/system/nfs-idmapd.service; static; vendor preset: disabled)
Active: active (running) since Fri 2015-07-31 17:11:33 CST; 12s ago
Process: 679 ExecStart=/usr/sbin/rpc.idmapd $RPCIDMAPDARGS (code=exited, status=0/SUCCESS)
Main PID: 680 (rpc.idmapd)
CGroup: /system.slice/nfs-idmapd.service
└─680 /usr/sbin/rpc.idmapd
Jul 31 17:11:33 hp-dl385pg8-03.rhts.eng.nay.redhat.com systemd[1]: Starting NFSv4 ID-name mapping service...
Jul 31 17:11:33 hp-dl385pg8-03.rhts.eng.nay.redhat.com systemd[1]: Started NFSv4 ID-name mapping service.
[root@hp-dl385pg8-03 ~]# rpm -q nfs-utils
nfs-utils-1.3.0-0.13.el7.x86_64
[root@hp-dl385pg8-03 ~]#
Move to VERIFIED
Is there an official document showing NFS changes between 7.0 and 7.1 releases? It looks there are many 7.0 "tutorials" out there but most of them have incorrect service names for 7.1. Thanks! 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://rhn.redhat.com/errata/RHBA-2015-2196.html |