Bug 678494
Summary: | netfs.sh patch, when network is lost it takes too long to unmount the NFS filesystems | ||||||
---|---|---|---|---|---|---|---|
Product: | Red Hat Enterprise Linux 5 | Reporter: | Raul Mahiques <rmahique> | ||||
Component: | rgmanager | Assignee: | Lon Hohberger <lhh> | ||||
Status: | CLOSED ERRATA | QA Contact: | Cluster QE <mspqa-list> | ||||
Severity: | urgent | Docs Contact: | |||||
Priority: | urgent | ||||||
Version: | 5.6 | CC: | amoralej, cluster-maint, cww, djansa, edamato, mjuricek | ||||
Target Milestone: | rc | ||||||
Target Release: | 5.7 | ||||||
Hardware: | All | ||||||
OS: | Linux | ||||||
Whiteboard: | |||||||
Fixed In Version: | rgmanager-2.0.52-16.el5 | Doc Type: | Bug Fix | ||||
Doc Text: | Story Points: | --- | |||||
Clone Of: | |||||||
: | 678497 (view as bug list) | Environment: | |||||
Last Closed: | 2011-07-21 10:43:42 UTC | Type: | --- | ||||
Regression: | --- | Mount Type: | --- | ||||
Documentation: | --- | CRM: | |||||
Verified Versions: | Category: | --- | |||||
oVirt Team: | --- | RHEL 7.3 requirements from Atomic Host: | |||||
Cloudforms Team: | --- | Target Upstream Version: | |||||
Embargoed: | |||||||
Attachments: |
|
557,559c557,558 < if [ ! "$force_umount" ]; then < sync; sync; sync < fi --- > > sync; sync; sync 572,608c571,575 < ocf_log debug "Force unmount $mp" < umount -f $mp < isMounted $fullpath $mp < case $? in < $YES) # already mounted < ocf_log debug "$fullpath still mounted on $mp" < ocf_log debug "Trying fuser $mp" < if [ $try -eq 1 ]; then < fuser -TERM -kvm "$mp" < else < fuser -kvm "$mp" < fi < ocf_log debug "Force unmount $mp" < umount -f $mp < ;; < $NO) # not mounted, continue < unset umount_failed < return $SUCCESS < ;; < $FAIL) < return $FAIL < ;; < esac < isMounted $fullpath $mp < case $? in < $YES) # already mounted < ocf_log debug "$fullpath still mounted on $mp" < return $FAIL < ;; < $NO) # not mounted, continue < unset umount_failed < done=$YES < ;; < $FAIL) < return $FAIL < ;; < esac --- > if [ $try -eq 1 ]; then > fuser -TERM -kvm "$mp" > else > fuser -kvm "$mp" > fi 609a577 > Created attachment 486710 [details]
Smaller patch for RHEL5 branch
Smaller patch for RHEL5 branch
(Note: Patch does not apply to later versions of RHEL) Neither of these patches help much if the client is issuing I/O to the NFS share, unfortunately. :( An advisory has been issued which should help the problem described in this bug report. This report is therefore being closed with a resolution of ERRATA. For more information on therefore solution and/or where to find the updated files, please follow the link below. You may reopen this bug report if the solution does not work for you. http://rhn.redhat.com/errata/RHSA-2011-1000.html |
Description of problem: With the current netfs.sh script when the network connection to an NFS server is lost the script takes too long to umount it. Version-Release number of selected component (if applicable): 2.0.52-9.el5 How reproducible: - Setup 2 NFS netfs resources in the cluster. - Cut connectivity to the NFS share. Steps to Reproduce: 1.Setup 2 or more NFS netfs resources in the cluster. Example: <resources> <netfs name="fs_shared_1" mountpoint="/mnt/fs_shared_1" host="x.x.x.x" export="fs_shared_1" fstype="nfs" force_unmount="1" options="rw,proto=tcp,rsize=32768,wsize=32768,soft" __enforce_timeouts="1"/> <netfs name="fs_shared_2" mountpoint="/mnt/fs_shared_2" host="x.x.x.x" export="fs_shared_2" fstype="nfs" force_unmount="1" options="rw,proto=tcp,rsize=32768,wsize=32768,soft" __enforce_timeouts="1"/> <netfs name="fs_shared_3" mountpoint="/mnt/fs_shared_3" host="x.x.x.x" export="fs_shared_3" fstype="nfs" options="rw,retry=1,proto=tcp,rsize=32768,wsize=32768,soft,timeo=5,retrans=2" force_unmount="1" __enforce_timeouts="1"/> </resources> 2.Cut connectivity to the NFS share. Example: ifconfig ethX down Actual results: It takes too long time to umount the NFS filesystems. Expected results: It unmounts the NFS filesystem in a reasonable amount of time. Additional info: Patch: #diff new_netfs.sh original_netfs.sh 571,605c571,575 < ocf_log debug "Force unmount $mp" < umount -f $mp < isMounted $fullpath $mp < case $? in < $YES) # already mounted < ocf_log debug "$fullpath still mounted on $mp" < ocf_log debug "Trying fuser $mp" < if [ $try -eq 1 ]; then < fuser -TERM -kvm "$mp" < else < fuser -kvm "$mp" < fi < ocf_log debug "Force unmount $mp" < umount -f $mp < ;; < $NO) # not mounted, continue < return $SUCCESS < ;; < $FAIL) < return $FAIL < ;; < esac < isMounted $fullpath $mp < case $? in < $YES) # already mounted < ocf_log debug "$fullpath still mounted on $mp" < return $FAIL < ;; < $NO) # not mounted, continue < done=$YES < ;; < $FAIL) < return $FAIL < ;; < esac --- > if [ $try -eq 1 ]; then > fuser -TERM -kvm "$mp" > else > fuser -kvm "$mp" > fi 606a577 >