Bug 2143459

Summary: Integrate the latest sanlock to RHEL
Product: Red Hat Enterprise Linux 9 Reporter: rainzhang2 <rain.zhang>
Component: sanlockAssignee: David Teigland <teigland>
Status: NEW --- QA Contact: cluster-qe <cluster-qe>
Severity: high Docs Contact:
Priority: low    
Version: 9.3CC: agk, cluster-maint
Target Milestone: rcKeywords: Triaged
Target Release: ---   
Hardware: x86_64   
OS: Linux   
Whiteboard:
Fixed In Version: Doc Type: If docs needed, set a value
Doc Text:
Story Points: ---
Clone Of: Environment:
Last Closed: Type: Bug
Regression: --- Mount Type: ---
Documentation: --- CRM:
Verified Versions: Category: ---
oVirt Team: --- RHEL 7.3 requirements from Atomic Host:
Cloudforms Team: --- Target Upstream Version:
Embargoed:

Description rainzhang2 2022-11-17 01:51:19 UTC
Description of problem:
sanlock has an important enhancement to make the watchdog timeout configurable, please integrate into RHEL.
https://pagure.io/sanlock/c/748e8325fd0b2e09469c76f584b8e08c1ef03ca6?branch=master

Background: https://pagure.io/sanlock/issue/7

Version-Release number of selected component (if applicable):
Current version: sanlock-lib-3.8.4-3

How reproducible:
Please refer to https://pagure.io/sanlock/issue/7

Actual results:
watchdog_fire_timeout is hardcoded to 60 seconds.

Expected results:
watchdog_fire_timeout is configurable.

Additional info:

Comment 1 David Teigland 2022-11-17 16:37:25 UTC
Can you please describe the use case you have for sanlock?  What other software would use sanlock with this configuration?  sanlock features are often tested and supported as a component of a larger product.

Comment 2 rainzhang2 2022-11-18 02:59:16 UTC
Hi,

We use sanlock+lvmlockd for shared VG.

We have a 2 nodes Active/Standby HA system with shared storage, only one node can access the shared storage at the same time.
So, we use shared VG with sanlock+lvmlockd, then only one node can activate VG at the same time.

In case active node is failed, the standby node should activate VG and take over active role. As current sanlock timer, standby node can not activate VG until the following time passed:
8 * io_timeout_seconds + watchdog_fire_timeout(hardcode 60 seconds)

To decrease the wait time, we need watchdog_fire_timeout to be confiruable.

Comment 3 David Teigland 2022-11-18 15:45:09 UTC
Thanks for the information, we will need to test lvmlockd with the new sanlock timeout settings.  Most new features like this would be added only to RHEL9; very few changes are now added to RHEL8.

You will notice in the commit above that a lower watchdog_fire_timeout should be combined with a shorter io_timeout, e.g. watchdog_fire_timeout=30 and io_timeout=5.  You should also verify that the smaller io_timeout works well with your storage system.  Smaller io_timeouts can trigger unnecessary failures when the i/o response from the storage is slow.