Description of problem: Heketi pod went into "CrashLoopBackOff" state after executing some test cases related to add/remove of devices while performing some IO operations. Version-Release number of selected component (if applicable): [root@ocs-3x-cvp-ci-integration-master-0 ~]# oc version oc v3.11.165 kubernetes v1.11.0+d4cacc0 features: Basic-Auth GSSAPI Kerberos SPNEGO Server https://ocs-3x-cvp-ci-integration-master-0:8443 openshift v3.11.165 kubernetes v1.11.0+d4cacc0 [root@ocs-3x-cvp-ci-integration-master-0 ~]# rpm -qa | grep glusterfs glusterfs-6.0-21.el7.x86_64 glusterfs-client-xlators-6.0-21.el7.x86_64 glusterfs-fuse-6.0-21.el7.x86_64 glusterfs-libs-6.0-21.el7.x86_64 How reproducible: Always Steps to Reproduce: 1. Deploy gluster server with latest openshift ansible & OCS 3.11.5 builds. 2. Execute test cases related to add/remove test cases related heketi node while performing IO operations. 3. After around 10 mins, check heketi-storage pod status Actual results: heketi-storage is going into "CrashLoopBackOff" state [root@ocs-3x-cvp-ci-integration-master-0 ~]# oc get pods NAME READY STATUS RESTARTS AGE glusterblock-storage-provisioner-dc-1-l4x58 1/1 Running 1 2h glusterfs-storage-57hqj 1/1 Running 0 3h glusterfs-storage-8mknv 1/1 Running 1 3h glusterfs-storage-fnsrf 1/1 Running 0 3h glusterfs-storage-jk2p6 1/1 Running 1 3h glusterfs-storage-nrmhj 1/1 Running 1 3h heketi-storage-1-k4xl6 0/1 CrashLoopBackOff 9 37m Expected results: heketi-storage pod status should be "Running" and should be able to create all type of volumes.
Heketi crashes when a brick is being removed and the pod is not running on the node where the brick is mounted. This issue is caused by this block: »»»»»»»»»»»»if s.DebugUmountFailures() { »»»»»»»»»»»»»»»»// in case unmounting failed, grab the output of 'lsof /path/to/brick' »»»»»»»»»»»»»»»»commands = []string{ »»»»»»»»»»»»»»»»»»»»fmt.Sprintf("lsof %s", brick.Path), »»»»»»»»»»»»»»»»} »»»»»»»»»»»»»»»»res, _ = s.RemoteExecutor.ExecCommands(host, rex.ToCmds(commands), 5) »»»»»»»»»»»»»»»»logger.Warning("brick path [%s] kept open by:\n%s", brick.Path, res[0].Output) »»»»»»»»»»»»} »»»»»»»»} The res value is empty and the error was set but this code ignores the error and assumes that the command ran and put a value in res. To fix this the warning line should only be run if the error is not set.
doc text has been modified
Modified doc text to remove the dot and first sentence
"""Previously, Heketi could crash if an attempt was made to delete a brick from a node that was not running and the option to `debug unmount` failures was enabled. With this update, this option is enabled by default. Hence, Heketi no longer crashes when this condition occurs.""" Is not quite correct. The option was always enabled by default. I put, "By default this option is enabled." into my suggested doc text to clarify that the behavior is optional but is on by default. Either remove the "With this update" from "With this update, this option is enabled by default" or drop that sentence entirely if you don't think the extra context is needed. Otherwise this doc text is incorrect.
Have removed the entire sentence to avoid confusion.
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://access.redhat.com/errata/RHBA-2020:0621