Repository navigation
Conversation
Codecov Report❌ Patch coverage is Additional details and impacted files@@ Coverage Diff @@
## main #14450 +/- ##
============================================
+ Coverage 20.76% 20.79% +0.02%
- Complexity 21903 21953 +50
============================================
Files 6496 6497 +1
Lines 591612 591794 +182
Branches 72585 72613 +28
============================================
+ Hits 122851 123053 +202
+ Misses 455424 455387 -37
- Partials 13337 13354 +17
Flags with carried forward coverage won't be shown. Click here to find out more. ☔ View full report in Codecov by Harness. 🚀 New features to boost your workflow:
|
🔴 Test Coverage Grade:
|
| Metric | Value |
|---|---|
| Line coverage | 25.90% |
| Branch coverage | 20.23% |
Grade Scale
| Grade | Line Coverage | Meaning |
|---|---|---|
| 🟢 A | ≥ 80% | Excellent - this code sleeps well at night 😴 |
| 🟡 B | 60-79% | Good - almost there, don't stop now 😉 |
| 🟠 C | 40-59% | Acceptable - your code is wearing a seatbelt, but no airbags 😬 |
| 🔴 D | 20-39% | Marginal - boldly shipping where no test has gone before 🖖 |
| ⛔ F | < 20% | Failing - tests? what tests? 🔥 |
Branch coverage is shown as a secondary signal. Grade is determined by line coverage.
View full Actions run
|
@blueorangutan package |
|
@Pearl1594 a [SL] Jenkins job has been kicked to build packages. It will be bundled with no SystemVM templates. I'll keep you posted as I make progress. |
|
Packaging result [SF]: ✔️ el8 ✔️ el9 ✔️ el10 ✔️ debian ✔️ suse15. SL-JID 19651 |
|
@blueorangutan test |
|
@Pearl1594 a [SL] Trillian-Jenkins test job (ol8 mgmt + kvm-ol8) has been kicked to run smoke tests |
|
[SF] Trillian Build Failed (tid-17194) |
|
@blueorangutan test |
|
@Pearl1594 a [SL] Trillian-Jenkins test job (ol8 mgmt + kvm-ol8) has been kicked to run smoke tests |
|
[SF] Trillian test result (tid-17195)
|
|
This pull request has merge conflicts. Dear author, please fix the conflicts and sync your branch with the base branch. |
|
Hi @Pearl1594 can you please address the conflicts? |
|
@blueorangutan package |
|
@Pearl1594 a [SL] Jenkins job has been kicked to build packages. It will be bundled with no SystemVM templates. I'll keep you posted as I make progress. |
|
|
Packaging result [SF]: ✔️ el8 ✔️ el9 ✔️ el10 ✖️ debian ✔️ suse15. SL-JID 19870 |
| * With reportIfHeartBeatFailedForOneStoragePool the host is dead as soon as one pool has no heart beat, | ||
| * otherwise it is dead only when none of the pools has one. | ||
| */ | ||
| private boolean checkPoolsHeartBeat() { |
There was a problem hiding this comment.
| private boolean checkPoolsHeartBeat() { | |
| private boolean doesAnyPoolHasHeartBeat() { |
| * Reads a host's sanlock delta-lease state for a CLVM/CLVM_NG volume group; the lease is renewed | ||
| * by sanlock itself, and a host that stops renewing is reset by its watchdog. | ||
| */ | ||
| public class ClvmSanlockHaChecker { |
There was a problem hiding this comment.
any chance to move this to clvm plugin?



Description
This PR fixes: #14178
This PR does two things for CLVM and CLVM_NG primary storage (lvmlockd + sanlock).
CLVM and CLVM_NG pools were not in
LIBVIRT_STORAGE_POOL_TYPES_WITH_HA_SUPPORT, so the KVM HA activity check never gave a usable answer for them and a failed host was never resolved.sanlock client host_status -s lvm_<vg> -D. The host is dead only whenlast_check - last_live >= 8 * io_timeout + 60(140s with the default io_timeout). Missing or unparsable state is treated as alive, so a host is never declared dead without evidence.lvmconfig local/host_id) as the host detailhost.sanlock.id.KVMHostActivityCheckerpasses it to the checking host inHostTO.sanlockHostId. Sanlock host ids are host-wide and can repeat across clusters, so the lease is looked up by VG name plus host id.KVMHAMonitorno longer unmounts or checks libvirt for CLVM pools, and deleting a CLVM pool removes it from the monitor.After a holder failed or rebooted, the first exclusive activation (
lvchange -aey) can be refused for a short time: either the previous holder's sanlock lease has not expired yet (LV locked by other host), or the lockspace is still being joined on a rebooted host (lock start in progress). Previously the activation was tried once, the lookup returned no holder, and the VM start went ahead with the LV inactive.The agent then waits for the device node (
KVMStoragePoolManager.getPhysicalDisk, 100 tries every 3 seconds). That wait only checks whether/dev/<vg>/<lv>exists. It never requests the lock, andClvmStorageAdaptor.handleMissingDeviceNodeactivates onlytemplate-volumes. So even after the lease expires nothing activates the LV and the start fails after about 6-7 minutes. HA then retries only afterrestart.retry.interval(600s by default).ClvmPoolManagernow retries the exclusive activation on the chosen host until sanlock grants it or the budget runs out:locked by other hostandlock start in progressare retried. Any other failure or exception is a single attempt, as before.clvm.lock.recovery.retry.timeout(default 180s, counted from the start of the lookup; 0 disables the retry) andclvm.lock.recovery.retry.interval(default 10s). The lease expires 8 x io_timeout + 60 seconds after the holder stops renewing, so raise the timeout if lvmlockd runs with a larger--sanlock-timeout.Behaviour changes to be aware of
sanlock,wdmd,lvmlockdandlvmlocksenabled at boot, and a working watchdog device.Types of changes
Feature/Enhancement Scale or Bug Severity
Feature/Enhancement Scale
Screenshots (if appropriate):
How Has This Been Tested?
HA support
Retry
lock start in progress) and the data volume activated at once. VM Running in 232s. Without the retry the same scenario failed after 6m47s and the VM stayed stopped.locked by other host) over 48s, activated about 136s after the reset, VM Running 142s after the reset.clvm.lock.recovery.retry.timeout=0): one refusal per volume, no retry, the start fails as before. Setting back to 180 restored the retry without a restart.How did you try to break this feature and the system with this change?