High Availability
Overview
Storware Backup & Recovery can be deployed in an active/passive cluster using Pacemaker and Corosync.
This chapter describes configurations with two or three cluster hosts. Each host runs a local MariaDB instance and has the Storware Backup & Recovery Server and Node components installed.
Pacemaker manages the floating IP address and the Storware services. Only one host runs the Storware Server and Node services at a time. MariaDB remains running on all hosts to maintain database replication.
Users and Storware Nodes connect to the Server through a shared hostname that resolves to the floating IP address.
Component
Two-host configuration
Three-host configuration
Storware Server and Node services
Active on one host
Active on one host
MariaDB
Running on both hosts
Running on all three hosts
Database replication
Bidirectional replication
Circular replication
Client access
Shared hostname and floating IP
Shared hostname and floating IP
Backup storage
Accessible from both hosts
Accessible from all three hosts
Important: Database replication in this configuration is asynchronous. Failover does not guarantee that the destination database contains every transaction committed on the previous active host. Pacemaker service monitoring alone does not verify replication consistency or select the most up-to-date database.
Example Environment
The examples use the following addresses:
Host or resource
Hostname
IP address
First cluster host
node1.example.com
10.1.1.2
Second cluster host
node2.example.com
10.1.1.3
Third cluster host — three-host configuration only
node3.example.com
10.1.1.4
Cluster access address
storware.example.com
10.1.1.5/24
NFS server used in this example
—
10.1.1.1
Replace these values with the addresses and hostnames used in your environment.
Complete Common Preparation, follow the section for your selected cluster size, and then continue with Configuring Cluster Resources.
Two and Three node cluster
Prerequisites
Before starting, prepare:
Two or three hosts running a supported operating system. The commands in this chapter target Red Hat Enterprise Linux 9 on x86_64.
The same Storware Backup & Recovery version and compatible MariaDB versions on all hosts.
Access to the required operating system, High Availability, Storware, and MariaDB repositories.
Unique hostnames and working name resolution between all hosts.
An unused floating IP address that can be assigned to any cluster host.
A shared hostname resolving to the floating IP address.
A server certificate valid for the shared hostname.
Backup destinations accessible from every host that can run the Storware Node service.
Network connectivity for cluster communication, database replication, HTTPS access, and backup storage.
A fencing mechanism appropriate for the physical or virtual infrastructure.
Administrative access to all hosts.
All shell commands in this chapter are executed as root.
This procedure assumes a new cluster. When using an existing Storware deployment as the source, first back up its database and configuration and stop all backup, restore, and administrative activity.
Common Preparation
1. Install Storware Server and Node
Run on every cluster host.
Follow the Server and Node installation instructions for your operating system, including repository configuration and operating system preparation.
During installation:
Do not start
vprotect-serverorvprotect-node.Do not register the Node yet.
Complete any required operating system reboot before configuring the cluster.
Ensure that both Storware services are stopped and disabled:
Pacemaker will manage these services after the cluster resources have been created.
MariaDB must remain available independently on every host:
Do not disable MariaDB as part of disabling the Storware services. Both database replication configurations require MariaDB to run on all participating hosts.
2. Configure Name Resolution
Run on every cluster host.
Configure DNS or add the following entries to /etc/hosts:
For a three-host cluster, also add:
Ensure that each cluster hostname resolves to its actual network address. Remove any conflicting mapping of a cluster hostname to a loopback address, while preserving the standard localhost entries.
3. Install Cluster Packages
Run on every cluster host.
Enable the RHEL 9 High Availability repository:
Install the cluster packages:
Install the fence agent required by your infrastructure.
Enable the PCS management service:
Set a password for the hacluster account:
Use the same password on all cluster hosts.
PCS authentication is configured later with pcs host auth. Passwordless SSH between every pair of hosts is not required for PCS cluster authentication.
4. Configure Network Access
Run on every cluster host.
Allow cluster communication:
Allow MariaDB replication from the participating cluster hosts. For example, add a rule for each peer, replacing <PEER_IP>:
Apply the changes:
Apply the rules to the firewall zone associated with the relevant interface.
Also allow the HTTPS and storage connections required by the deployment.
If HTTPS access uses the installation’s port redirection from TCP 443 to TCP 8181, configure local access to the floating IP:
This rule applies to deployments using that port-redirection model. Adapt it if HTTPS is provided by a reverse proxy or another configuration.
Keep the firewall and SELinux configured according to the supported installation requirements. Disabling them is not part of this procedure.
5. Configure Shared Backup Storage
Run on every cluster host.
Configure access to the selected backup destination. Each host must have the required connectivity, credentials, and permissions.
For filesystem destinations, use the same path on every host.
The following example mounts an NFS export at /vprotect_data.
Install the NFS client and create the mount point:
Add the following entry to /etc/fstab:
Mount and verify the filesystem:
Run once, from one cluster host:
Configure ownership and permissions so that the vprotect account can access these directories from every host. Ensure consistent UID/GID mapping and appropriate NFS export permissions.
The shared storage must remain available when the active cluster host changes. Its availability is a separate dependency from the Storware cluster.
Creating a directory on NFS does not make it a synthetic backup destination. Configure synthetic destinations according to their storage backend requirements.
6. Configure HTTPS and Synchronize Server Configuration
Prepare on node1.example.com, then apply to the other hosts.
Configure HTTPS for storware.example.com using the procedure described in Enabling HTTPS Connectivity for Nodes.
Synchronize the Server configuration and certificate material required by your Storware release. Depending on the release, these files can include:
For releases using a local license file, also synchronize:
Preserve file ownership and restrictive permissions when transferring configuration files and private keys.
Review host-specific settings after copying. In this architecture, each Storware Server must connect to its local MariaDB instance.
Configure the same application database password on every host, matching the password in quarkus.properties.
For an existing vprotect database account using password authentication, execute locally on each MariaDB instance:
Use the account host value created by the installation if it differs from localhost.
7. Prepare MariaDB for Replication
Run on every cluster host.
Add or update the following settings in the [mysqld] section of /etc/my.cnf.d/server.cnf:
Assign a unique server_id:
Host
Setting
node1.example.com
server_id=10
node2.example.com
server_id=20
node3.example.com
server_id=30
Preserve other settings required by the Storware installation.
Ensure that MariaDB accepts replication connections on the host’s network address. A configuration restricted to 127.0.0.1 will prevent remote replication.
Restart MariaDB:
Do not change
lower_case_table_nameson an already initialized database as part of this procedure. Its value must be consistent across hosts and established during database initialization. MariaDB Documentation
Create a replication account locally on each database:
Use a strong password and restrict the permitted source addresses to the replication network or individual peers.
Because replication is restricted to the vprotect database, database accounts and grants must be maintained locally on every host.
8. Initialize the Databases from a Common Source
Use node1.example.com as the authoritative source.
Keep Storware services stopped on all hosts throughout database initialization and replication setup. Prevent other processes, scheduled database events, and administrators from modifying the application database during this period.
Create a database dump:
Copy the dump to the second host:
For a three-host cluster, also copy it to the third host:
On each destination host, import the dump through a local MariaDB session:
Disabling binary logging in this import session prevents the initialization data from later circulating through the replication topology.
The destination databases must contain the same application data and schema as the source before replication begins. This step is intended for newly prepared destination databases, not for merging independent deployments.
After completing all imports and local account configuration, run the following on each host:
Record the File and Position values separately for each host.
Use those values in the appropriate configuration below. Do not copy example positions from another environment, and do not allow application writes between this step and completion of replication setup.
Two-Node Cluster Configuration
1. Configure Bidirectional Database Replication
The databases replicate changes in both directions:
Replica
Replication source
node1.example.com
node2.example.com
node2.example.com
node1.example.com
On node1.example.com:
On node2.example.com:
These commands assume that no replication channel has previously been configured.
Start replication on both hosts:
Verify that both replication threads are running:
Check for replication errors and confirm that both databases have reached the recorded source positions before continuing.
2. Create the Pacemaker Cluster
Run on node1.example.com.
Authenticate both hosts:
Create the cluster:
Start the cluster and enable startup at boot:
Check its status:
3. Configure Fencing and Verify Quorum
Configure and test fencing for both hosts using the fence agent appropriate for your infrastructure.
Retain the quorum behavior appropriate for the two-host configuration generated by PCS. Do not set no-quorum-policy=ignore merely because the cluster contains two hosts.
Two-host quorum behavior differs from ordinary majority voting. Initial startup can also require both hosts to have been visible before the cluster becomes quorate. Verify startup, isolation, and recovery behavior for your deployment. Red Hat Documentation
Continue with Configuring Cluster Resources.
Three-Node Cluster Configuration
1. Configure Circular Database Replication
The databases form a replication ring:
Replica
Replication source
node1.example.com
node3.example.com
node2.example.com
node1.example.com
node3.example.com
node2.example.com
The log-slave-updates setting allows replicated changes to be forwarded to the next database in the ring.
On node1.example.com:
On node2.example.com:
On node3.example.com:
Start replication on all three hosts:
Verify on every host:
Check replication errors and confirm that every database has reached its source’s recorded position.
Important: A failed database host breaks the replication ring. Pacemaker does not automatically repair replication channels or reconnect the remaining databases into a new topology. Restore or reconfigure replication before relying on further failovers. mariadb.com
2. Create the Pacemaker Cluster
Run on node1.example.com.
Authenticate all three hosts:
Create the cluster:
Start the cluster and enable startup at boot:
Check its status:
3. Configure Fencing and Verify Quorum
Configure and test fencing for all three hosts.
Retain the normal majority-quorum behavior. With one vote per host, two communicating hosts constitute a majority; one isolated host does not.
Do not disable fencing simply because the cluster contains three hosts. Quorum and fencing address different parts of failure handling.
Continue with the common resource configuration below.
Configuring Cluster Resources
Complete this section for either cluster size.
Before proceeding, verify that:
Database initialization and replication have completed.
All cluster hosts are online.
Fencing is configured and tested.
The cluster has quorum.
Shared storage is accessible.
Server configuration and certificates are synchronized.
The local database credentials work on every host.
RHEL HA deployments require a fencing device for each cluster node. Use the platform-specific configuration procedure rather than disabling STONITH. docs.redhat.com
1. Configure Resource Defaults
Run once, from node1.example.com.
These defaults control how recorded resource failures affect placement and when they expire. Adjust them to the operational requirements of your environment.
2. Create the Floating IP and Server Resources
Temporarily place the cluster in maintenance mode while defining the initial resources:
Create the floating IP resource:
Create the Server resource:
Prefer the first host for the initial startup:
Return the cluster to managed operation:
Check the resources:
Once the Server is running, verify access through:
The resources belong to the same group, so the floating IP and Server are colocated. Group members start in the order in which they were added and stop in reverse order.
MariaDB is not part of this active/passive group. It runs independently on every host.
3. Configure Storware Node Registration
On every host, import the Server certificate using the documented certificate-trust procedure:
Verify the certificate before trusting it.
Two-Node Configuration: Shared Node Identity
The original two-host configuration uses a single Storware Node identity shared between both hosts.
Register the Node once on node1.example.com:
With the Node service stopped on both hosts, copy its session file:
Preserve the original file permissions and ensure that the file is owned by vprotect on the destination.
Only the cluster-managed active host may run this shared Node identity.
Three-Node Configuration: Separate Node Identities
The original three-host configuration registers a separate Storware Node on each host.
Run on every host, specifying its unique Node name:
Use names such as node1, node2, and node3.
Do not copy .session.properties between separately registered Nodes.
Configure Node configurations and backup destination availability so that the Node on each possible active host can execute the required tasks.
4. Add the Node Service to the Cluster
Run once, from a cluster host.
After registration is complete, add the Node resource:
The resource group now starts in this order:
Floating IP address.
Storware Server.
Storware Node.
Verify the configuration:
Only one host should run the complete resource group.
The systemd resource agents monitor service state. They do not verify that a database replica is current, that the application API is ready, or that backup storage remains accessible. Production failover procedures must account for these dependencies.
Verification and Failover Testing
1. Verify Normal Operation
Confirm that:
All expected cluster hosts are online.
The cluster has quorum and fencing is operational.
The floating IP, Server, and Node resources run on the same host.
MariaDB runs on every host.
Database replication has no errors.
The web interface is accessible through the shared hostname.
The active Storware Node can access its backup destinations.
A backup and a test restore complete successfully.
2. Test a Planned Switchover
First, allow active backup and restore tasks to finish.
For a controlled database handover, stop the Storware resource group:
Verify that the database on the intended destination has applied all changes from the previous active host. Check replication positions and errors; running replication threads alone do not prove that the replica is current.
Place the previous active host in standby:
Re-enable the resource group:
Verify that it starts on another eligible host:
Check web access, Node availability, backup destination access, and database replication again.
When the original host is ready to rejoin resource scheduling:
Returning a host from standby makes it eligible to host resources. Whether resources move back depends on the configured placement preferences and stickiness.
For a three-host configuration, repeat the test to verify operation on each host.
3. Test Failure Handling Separately
A planned standby test does not validate fencing or unexpected host failure.
During a controlled maintenance window, test the agreed failure scenarios, including host loss and cluster-network interruption. Verify that the previous active host is isolated before another host runs the Storware services.
After an unexpected failure, assess database consistency and replication topology before further failover or failback.
Do not assume that interrupted backup or restore tasks resume automatically.
Maintenance and Useful Commands
Run cluster-wide administration commands from one cluster host.
Operation
Command
Display cluster status
pcs status
Display quorum status
pcs quorum status
Put a host in standby
pcs node standby node1.example.com
Remove a host from standby
pcs node unstandby node1.example.com
Stop Storware resources
pcs resource disable sbr-group --wait=300
Start Storware resources
pcs resource enable sbr-group --wait=300
Temporarily stop managing the resource group
pcs resource unmanage sbr-group
Resume management of the resource group
pcs resource manage sbr-group
Stop cluster services on one host
pcs cluster stop node1.example.com
Stop cluster services on all hosts
pcs cluster stop --all
Start cluster services on all hosts
pcs cluster start --all
Clear failure history for a corrected resource
pcs resource cleanup <RESOURCE_ID>
Unmanaging a resource does not stop it. Use the appropriate maintenance procedure before manually operating services or installing updates.
Before restoring a host to service after maintenance, verify its configuration, storage access, database consistency, and replication state.
For planned operating system shutdown, stop or relocate the resources first and confirm the resulting cluster state.
Last updated