+++ This bug was initially created as a clone of Bug #1599783 +++ The `_is_prefix` function in glusterd-utils.c is used to check if one of 2 given paths contains the other. When one of the passed paths is a 0-length string, `_is_prefix` returns true. This is incorrect, as a 0-length string is not a path, and isn't a prefix of the other. The current behaviour sometimes causes problems when creating new volumes, as it causes new brick paths to appear to contain/be contained by old bricks. Because of issues with volume deletion and volume sync, there are cases when stale volumes with stale and incomplete brickinfo could be present.
REVIEW: https://review.gluster.org/20492 (glusterd: _is_prefix should handle 0-length paths) posted (#1) for review on release-3.12 by Kaushal M
REVIEW: https://review.gluster.org/20492 (glusterd: _is_prefix should handle 0-length paths) posted (#2) for review on release-3.12 by Kaushal M
COMMIT: https://review.gluster.org/20492 committed in release-3.12 by "jiffin tony Thottan" <jthottan> with a commit message- glusterd: _is_prefix should handle 0-length paths If one of the paths given to _is_prefix is 0-length, then it is not a prefix of the other. Hence, _is_prefix should return false. Change-Id: I54aa577a64a58940ec91872d0d74dc19cff9106d BUG: 1599788 Signed-off-by: Kaushal M <kaushal>
This bug is getting closed because a release has been made available that should address the reported issue. In case the problem is still not fixed with glusterfs-3.12.3, please open a new bug report. glusterfs-3.12.3 has been announced on the Gluster mailinglists [1], packages for several distributions should become available in the near future. Keep an eye on the Gluster Users mailinglist [2] and the update infrastructure for your distribution. [1] https://lists.gluster.org/pipermail/announce/2018-August/000107.html [2] https://www.gluster.org/pipermail/gluster-users/