Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

backport: core: fix network faults handling and fencing flow #306

Merged

Commits on Apr 25, 2022

  1. core: fix network faults handling and fencing flow

    This patch fixes network exception handling and fencing flow logic.
    Problems in current code:
    
        1. Hard fencing happens too fast since we waited on number of
    attempts <or> grace period, since number of attempts is configured to a
    value of "2", grace period was ~20 seconds.
    
        2. VdsManager::isHostInGracePeriod was called periodically from
    VdsManager:handleNetworkExeception and from
    SsshSoftFencingCommand::checkIfHostBecomeUp which makes the logic
    complex in not working as expected
    While we have to handle the network exception grace period when the host
    is switched to 'connecting' state due to its load regarding number of
    running VMs and SPM status, in the case of soft-fencing flow, the host
    is already in not-responding status, other host already took the SPM
    role and all its running VMs set to 'unknown' status. So we should not
    consider the host load at all and a fixed grace period (configurable 1
    min) is enough to restart the vdsmd service on the host and get it up
    and running.
    
    Solution was tested with host as SPM with running VMs (some are HA),
    with a non SPM host running VMs and with a regular host.
    
    Results:
    
    1. Both initial grace between connecting and non-responding and between
    soft-fencing and hard-fencing are honored.
    
    2. Code is more readable and straight foreword
    
    Signed-off-by: Eli Mesika <emesika@redhat.com>
    Bug-Url: https://bugzilla.redhat.com/2071468
    emesika authored and mwperina committed Apr 25, 2022
    Configuration menu
    Copy the full SHA
    24420d6 View commit details
    Browse the repository at this point in the history