Skip to content

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

5 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

TFG - High Availability MariaDB/Galera Cluster

Final ASIR project based on the deployment of a high availability database infrastructure using MariaDB Galera Cluster, HAProxy, Keepalived, OpenVPN, physical backups and a web-based monitoring and audit portal.

Project Description

This project implements a high availability environment made up of several virtual servers connected through an internal network. The system keeps MariaDB database access available even if one of the database nodes or one of the load balancers fails.

The infrastructure consists of:

  • Three MariaDB/Galera nodes with synchronous replication.
  • Two HAProxy load balancers.
  • Keepalived to manage virtual IP addresses and failover.
  • OpenVPN for secure remote access from a Windows client.
  • Physical backup system using 'mariabackup'.
  • WebTelegram portal developed in PHP for monitoring, auditing and SQL injection attempt detection.
  • Monitoring scripts and email alerts.

Objectives

  • Design a fault-tolerant database infrastructure.
  • Ensure service continuity in case of node or load balancer failure.
  • Centralize access to MariaDB through a virtual IP address.
  • Allow secure remote access through VPN.
  • Implement physical MariaDB backups.
  • Log access attempts and security incidents in an audit database.
  • Document the installation, configuration and verification of the system.

Environment Architecture

Machine System IP Role
Node1 Ubuntu Server 24.04 '192.168.19.10' MariaDB + Galera
Node2 Ubuntu Server 24.04 '192.168.19.20' MariaDB + Galera
Node3 Ubuntu Server 24.04 '192.168.19.30' MariaDB + Galera
LoadBalancer1 Ubuntu Server 24.04 '192.168.19.40' HAProxy + Keepalived + OpenVPN
LoadBalancer2 Ubuntu Server 24.04 '192.168.19.50' HAProxy + Keepalived + OpenVPN
WebTelegram Ubuntu Server 24.04 '192.168.19.60' Apache + PHP
Client Windows 10 '192.168.1.X' OpenVPN + MariaDB client

Virtual IP Addresses

Virtual IP Role
'192.168.19.100' Internal access to the MariaDB cluster through HAProxy
'192.168.1.165' External access to the VPN through OpenVPN

Technologies Used

  • Ubuntu Server 24.04
  • Windows 10
  • MariaDB
  • Galera Cluster
  • HAProxy
  • Keepalived
  • OpenVPN
  • Apache
  • PHP
  • PDO
  • Bash
  • 'mariabackup'
  • 'msmtp'
  • Git and GitHub

Repository Structure

TFG-Cluster-HA/
├── backups/
├── docs/
├── galera/
├── haproxy/
├── keepalived/
├── openvpn/
├── scripts/
├── sql/
├── webtelegram/
├── .gitignore
└── README.md

About

ClusterX is a high-availability infrastructure project with a MariaDB Galera cluster, HAProxy load balancing, Keepalived failover, VPN access, security monitoring and automated backups.

Topics

Resources

Stars

0 stars

Watchers

0 watching

Forks

Releases

Packages

Contributors

Languages