Permalink
Browse files

rgmanager: Fix for umount of full filesystems

When the filesystem /etc lives on is completely full, some versions of
umount will exit with status 16 if the umount syscall succeeded but
it was unable to write a new mtab file because the disk is full. umount
won't exit with status 16 under any other circumstances.

Signed-off-by: Ryan McCabe <rmccabe@redhat.com>
  • Loading branch information...
1 parent 2e33454 commit ae4ee3c5885867a029ed5607d132606b9015ffb8 @ryan-mccabe ryan-mccabe committed Jul 27, 2012
Showing with 3 additions and 1 deletion.
  1. +3 −1 rgmanager/src/resources/utils/fs-lib.sh
@@ -821,7 +821,9 @@ stop: Could not match $OCF_RESKEY_device with a real device"
ocf_log info "unmounting $mp"
umount "$mp"
ret_val=$?
- if [ $ret_val -eq 0 ]; then
+ # some versions of umount will exit with status 16 iff
+ # the umount(2) succeeded but /etc/mtab could not be written.
+ if [ $ret_val -eq 0 -o $ret_val -eq 16 ]; then
umount_failed=
break
fi

0 comments on commit ae4ee3c

Please sign in to comment.