Skip to content

AG Failover Testing - No failover when storage disconnected #1

Description

@dbafromthecold

Description

During failover testing of the AG operator on a 4-node Kubernetes cluster, automatic failover did not occur after a simulated storage failure affecting the primary replica.

The Kubernetes environment consists of: -

  • 1 control plane node
  • 3 worker nodes
  • All nodes deployed as VMware virtual machines
  • Persistent storage is provisioned through PX-CSI.

The environment consisted of the sample Availability Group deployment with: -

  • 1 primary replica
  • 2 secondary replicas
  • Database health enabled

Both secondary replicas configured as: -

  • Synchronous commit
  • Automatic failover enabled

Test Procedure

Generate transactional workload against the primary replica using HammerDB.
Identify the node hosting the primary AG pod.
Simulate a storage failure by disconnecting the volume provisioned to the primary pod from the underlying node.

Expected Behaviour

When the primary replica becomes unavailable due to storage loss, the Availability Group should automatically fail over to one of the synchronous secondary replicas configured for automatic failover. The application workload should reconnect to the new primary with minimal interruption.

Actual Behaviour

After the primary replica loses access to its storage: -

  • The primary replica goes offline.
  • No automatic Availability Group failover occurs.
  • The AG remains unavailable until manual intervention is performed.

Recovery required: -

  • Reattaching the disconnected volume to the original node.
  • Bringing the original primary replica back online.
  • Manually failing over the Availability Group.

Impact

A storage-level failure affecting the primary replica results in complete AG unavailability, despite synchronous replicas with automatic failover being configured. This prevents the deployment from meeting expected high availability behaviour during node or storage fault scenarios.

Logs

Operator Issue.zip

Activity

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions