Bug 1264387
| Summary: | change to use lockd.conf instead of sysconfig to set module lockd parameters | ||
|---|---|---|---|
| Product: | Red Hat Enterprise Linux 7 | Reporter: | Yongcheng Yang <yoyang> |
| Component: | nfs-utils | Assignee: | Steve Dickson <steved> |
| Status: | CLOSED ERRATA | QA Contact: | Yongcheng Yang <yoyang> |
| Severity: | unspecified | Docs Contact: | |
| Priority: | unspecified | ||
| Version: | 7.2 | CC: | eguan, hannsj_uhl, hartsjc, skoduri, steved |
| Target Milestone: | rc | Keywords: | Documentation |
| Target Release: | --- | ||
| Hardware: | Unspecified | ||
| OS: | Unspecified | ||
| Whiteboard: | |||
| Fixed In Version: | nfs-utils-1.3.0-0.28.el7 | Doc Type: | Bug Fix |
| Doc Text: | Story Points: | --- | |
| Clone Of: | Environment: | ||
| Last Closed: | 2016-11-04 05:00:20 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: | 1355652 | ||
|
Description
Yongcheng Yang
2015-09-18 10:40:56 UTC
I think this because proc-fs-nfsd.mount actually loading the lockd module and that service does not look at the variables in /etc/sysconfig/nfs... Since there are other ways to set module parameters, let look into this in 7.3 With this commit the following sysconfig/nfs lockd interface # Optional arguments passed to in-kernel lockd LOCKDARG="nsm_use_hostnames=1" # TCP port rpc.lockd should listen on. #LOCKD_TCPPORT=32803 # UDP port rpc.lockd should listen on. #LOCKD_UDPPORT=32769 # No longer exists, since they never worked. This interface has been replaced by the /etc/modprobe.d/lock.conf interface # # Set the NFS lock manager grace period. n is measured in seconds. #options lockd nlm_grace_period=90 # # Set the TCP port that the NFS lock manager should use. # port must be a valid TCP port value (1-65535). #options lockd nlm_tcpport # # Set the UDP port that the NFS lock manager should use. # port must be a valid UDP port value (1-65535). #options lockd nlm_udpport # # Set the maximum number of outstanding connections #options lockd nlm_max_connections=1024 # # Set the default time value for the NFS lock manager # in seconds. Default is 10 secs #options lockd nlm_timeout=10 # # Choose whether to record the caller_name or IP address # this peer in the local rpc.statd's database. #options lockd nsm_use_hostnames=0 If the old lockd interface was document (which I could not find) then it has to change to reflex new interface. Move to VERIFIED according to comment 14 and continue to run the automatic case. Seems cannot set the parameter "nlm_timeout" bigger than 20 While testing the new lockd.conf, and i still not find any explanation in man page or usage. Hi Steve, does this action all right? And do we need to add some description about this limitation? [root@hp-dl385pg8-08 ~]# echo "options lockd nlm_timeout=21" >/etc/modprobe.d/lockd.conf [root@hp-dl385pg8-08 ~]# systemctl stop nfs.service [root@hp-dl385pg8-08 ~]# systemctl stop rpc-gssd.service [root@hp-dl385pg8-08 ~]# umount /proc/fs/nfsd [root@hp-dl385pg8-08 ~]# modprobe -r nfsd [root@hp-dl385pg8-08 ~]# modprobe -r lockd modprobe: FATAL: Module lockd is in use. [root@hp-dl385pg8-08 ~]# modprobe -r nfs modprobe: FATAL: Module nfs is in use. [root@hp-dl385pg8-08 ~]# modprobe -r nfsv4 [root@hp-dl385pg8-08 ~]# modprobe -r nfsv3 [root@hp-dl385pg8-08 ~]# modprobe -r nfs [root@hp-dl385pg8-08 ~]# modprobe -r lockd [root@hp-dl385pg8-08 ~]# lsmod | grep lockd [root@hp-dl385pg8-08 ~]# systemctl start nfs.service A dependency job for nfs-server.service failed. See 'journalctl -xe' for details. [root@hp-dl385pg8-08 ~]# systemctl status nfs.service -l ● nfs-server.service - NFS server and services Loaded: loaded (/usr/lib/systemd/system/nfs-server.service; disabled; vendor preset: disabled) Active: inactive (dead) since Thu 2016-06-02 02:42:45 EDT; 2min 42s ago Process: 21751 ExecStopPost=/usr/sbin/exportfs -f (code=exited, status=0/SUCCESS) Process: 21748 ExecStopPost=/usr/sbin/exportfs -au (code=exited, status=0/SUCCESS) Process: 21744 ExecStop=/usr/sbin/rpc.nfsd 0 (code=exited, status=0/SUCCESS) Process: 21494 ExecStart=/usr/sbin/rpc.nfsd $RPCNFSDARGS (code=exited, status=0/SUCCESS) Process: 21491 ExecStartPre=/usr/sbin/exportfs -r (code=exited, status=0/SUCCESS) Main PID: 21494 (code=exited, status=0/SUCCESS) Jun 01 22:16:30 hp-dl385pg8-08.rhts.eng.pek2.redhat.com systemd[1]: Starting NFS server and services... Jun 01 22:16:30 hp-dl385pg8-08.rhts.eng.pek2.redhat.com systemd[1]: Started NFS server and services. Jun 02 02:42:45 hp-dl385pg8-08.rhts.eng.pek2.redhat.com systemd[1]: Stopping NFS server and services... Jun 02 02:42:45 hp-dl385pg8-08.rhts.eng.pek2.redhat.com systemd[1]: Stopped NFS server and services. Jun 02 02:45:16 hp-dl385pg8-08.rhts.eng.pek2.redhat.com systemd[1]: Dependency failed for NFS server and services. Jun 02 02:45:16 hp-dl385pg8-08.rhts.eng.pek2.redhat.com systemd[1]: Job nfs-server.service/start failed with result 'dependency'. ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ Failed if nlm_timeout > 20 [root@hp-dl385pg8-08 ~]# cat /etc/modprobe.d/lockd.conf options lockd nlm_timeout=21 [root@hp-dl385pg8-08 ~]# echo "options lockd nlm_timeout=20" >/etc/modprobe.d/lockd.conf [root@hp-dl385pg8-08 ~]# cat /etc/modprobe.d/lockd.conf options lockd nlm_timeout=20 [root@hp-dl385pg8-08 ~]# systemctl start nfs.service [root@hp-dl385pg8-08 ~]# systemctl status nfs.service ● nfs-server.service - NFS server and services Loaded: loaded (/usr/lib/systemd/system/nfs-server.service; disabled; vendor preset: disabled) Active: active (exited) since Thu 2016-06-02 02:47:14 EDT; 5s ago Process: 21751 ExecStopPost=/usr/sbin/exportfs -f (code=exited, status=0/SUCCESS) Process: 21748 ExecStopPost=/usr/sbin/exportfs -au (code=exited, status=0/SUCCESS) Process: 21744 ExecStop=/usr/sbin/rpc.nfsd 0 (code=exited, status=0/SUCCESS) Process: 21827 ExecStart=/usr/sbin/rpc.nfsd $RPCNFSDARGS (code=exited, status=0/SUCCESS) Process: 21825 ExecStartPre=/usr/sbin/exportfs -r (code=exited, status=0/SUCCESS) Main PID: 21827 (code=exited, status=0/SUCCESS) CGroup: /system.slice/nfs-server.service Jun 02 02:47:14 hp-dl385pg8-08.rhts.eng.pek2.redhat.com systemd[1]: Starting NFS server and services... Jun 02 02:47:14 hp-dl385pg8-08.rhts.eng.pek2.redhat.com systemd[1]: Started NFS server and services. ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ Success if nlm_timeout <= 20 [root@hp-dl385pg8-08 ~]# cat /sys/module/lockd/parameters/nlm_timeout 20 [root@hp-dl385pg8-08 ~]# (In reply to Yongcheng Yang from comment #16) > Seems cannot set the parameter "nlm_timeout" bigger than 20 While testing > the new lockd.conf, and i still not find any explanation in man page or > usage. > > Hi Steve, does this action all right? And do we need to add some description > about this limitation? > Yes this does make sense... with the sysctl kernel interface there are min and max constants that need to be provided. For nlm_timeout the min and max constants are 3 and 20. So that is why you can't set the timeout over 30. (In reply to Steve Dickson from comment #17) > (In reply to Yongcheng Yang from comment #16) > > Seems cannot set the parameter "nlm_timeout" bigger than 20 While testing > > the new lockd.conf, and i still not find any explanation in man page or > > usage. > > > > Hi Steve, does this action all right? And do we need to add some description > > about this limitation? > > > Yes this does make sense... with the sysctl kernel interface there > are min and max constants that need to be provided. > > For nlm_timeout the min and max constants are 3 and 20. > So that is why you can't set the timeout over 30. Thanks for the clarification. It's better to add some explanation in the file /etc/modprobe.d/lockd.conf, like what "nlm_tcpport" does. # Set the TCP port that the NFS lock manager should use. # port must be a valid TCP port value (1-65535). <<<<<<<<<< #options lockd nlm_tcpport ... # Set the default time value for the NFS lock manager # in seconds. Default is 10 secs #options lockd nlm_timeout=10 (In reply to Yongcheng Yang from comment #18) > > Thanks for the clarification. It's better to add some explanation in the > file /etc/modprobe.d/lockd.conf, like what "nlm_tcpport" does. > > # Set the TCP port that the NFS lock manager should use. > # port must be a valid TCP port value (1-65535). <<<<<<<<<< > #options lockd nlm_tcpport > ... > # Set the default time value for the NFS lock manager > # in seconds. Default is 10 secs > #options lockd nlm_timeout=10 Yeah... that's probably not a bad idea... I'll move this bz back to ON_QA when I make the change. *** Bug 1247089 has been marked as a duplicate of this bug. *** Checked the update mentioned in comment 19 with nfs-utils-1.3.0-0.28.el7 [root@ibm-x3250m4-07 ~]# rpm -q nfs-utils nfs-utils-1.3.0-0.28.el7.x86_64 [root@ibm-x3250m4-07 ~]# cat /etc/modprobe.d/lockd.conf [snip ...] # Set the default time value for the NFS lock manager # in seconds. Default is 10 secs (min 3 max 20) #options lockd nlm_timeout=10 [snip ...] [root@ibm-x3250m4-07 ~]# Move to VERIFIED (again) as comment 14 and continue to run the automatic case. 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-2016-2383.html |