mirror of
https://github.com/ewwhite/zfs-ha.git
synced 2026-05-15 14:16:09 -06:00
[GH-ISSUE #38] Split Brain when logged in user CWDed into ZFS volume #37
Labels
No labels
pull-request
No milestone
No project
No assignees
1 participant
Notifications
Due date
No due date set.
Dependencies
No dependencies set.
Reference: github-starred/zfs-ha#37
Loading…
Add table
Add a link
Reference in a new issue
No description provided.
Delete branch "%!s()"
Deleting a branch is permanent. Although the deleted branch may continue to exist for a short time before it actually gets removed, it CANNOT be undone in most cases. Continue?
Originally created by @rbicelli on GitHub (Apr 17, 2021).
Original GitHub issue: https://github.com/ewwhite/zfs-ha/issues/38
Hi,
Consider this scenario:
I observed that a fence action is triggered.
The worst thing happened is that the fence action don't work as expected: the volume stays mounted on both nodes, causing ZFS errors (and file corruption). I assume SCSI reservations are somehow not honored.
I triple checked the configuration and looks like ok.
Since I'm planning to add sanoid/syncoid for snapshot/replica send, I would like to avoid a split brain in case of failover in the middle of a process on node using the filesystem.
I think this behaviour it reproducible with ease.
@rbicelli commented on GitHub (Apr 17, 2021):
Relevant portion of log is (sorrry for cut but i was into a split-screened shell):
looks like when something is using the filesystem locally the resource agent is unable to stop the fs, then crashes and triggers a fence event. Fencing that doesn't happen (I've configured idrac but doesn't power cycle the node if I trigger a fence). But this is another story.
Same behaviour occours with a zfs send in progress.
In order to mitigate this issue I wrote an helper script, that i put in /usr/lib/ocf/lib/heartbeat/helpers/zfs-helper:
@intentions commented on GitHub (Apr 17, 2021):
Wouldn't using the multihost protection prevent the second host from mounting the pool?
@rbicelli commented on GitHub (Apr 17, 2021):
Wasn't aware of this feature. I've enabled it and testing it.
@Nooby1 commented on GitHub (Nov 1, 2021):
I have put it in /usr/lib/ocf/lib/heartbeat/zfs-helper.sh, as there is no helper directory in RHEL8 and there are other scripts in this directory.
Does anything else have to be done for this on RHEL8?
@rbicelli commented on GitHub (Nov 10, 2021):
I don't remember since months are passed, but is possible that I needed to create the required directory.