Skip to main content

MariaDB Overview

Fully managed MariaDB databases with Galera Cluster for high availability, automated backups, and easy scaling.

What is SailOps MariaDB?​

SailOps provides fully managed MariaDB databases that take care of the operational complexity:

  • Galera Cluster for synchronous multi-master replication
  • Automated backups with on-demand and scheduled backups
  • High availability with automatic failover
  • Automatic updates and security patches
  • Monitoring and alerting built-in
  • Easy scaling without downtime

Supported Versions​

VersionStatusBest For
MariaDB 11.4 LTSCurrentProduction workloads, new projects
Version Selection

MariaDB 11.4 LTS is the recommended version for all production workloads. It provides long-term support and the latest features.

Key Features​

Galera Cluster (High Availability)​

MariaDB on SailOps uses Galera Cluster for true multi-master replication:

  • Synchronous replication - All nodes are always in sync
  • Multi-master - Read and write on any node
  • Automatic failover - No single point of failure
  • Automatic node recovery - Failed nodes rejoin automatically
  • Configurable replicas - 1, 3, or 5 nodes (odd numbers recommended)

Automated Backups​

  • Daily automated backups (when enabled)
  • On-demand backups via UI or API
  • Configurable backup schedule (cron expressions)
  • S3-compatible storage
  • Retention based on your support plan (7 days default)
  • One-click restore

Security​

  • Encrypted at rest by the hosting infrastructure
  • Encrypted in transit (TLS)
  • Network isolation per project
  • Automatic security updates
  • User and database management with granular privileges

Monitoring​

  • Real-time metrics (CPU, memory, connections)
  • Query performance insights
  • Automated alerts
  • Log access

Compute Classes​

Database compute classes define the performance tier and resource allocation.

ClassDescriptionBest For
EcoShared resources, cost-effectiveDevelopment, testing, budget-conscious workloads
StandardBalanced performanceGeneral production databases
ProductionDedicated resourcesSensitive workloads requiring guaranteed performance
Choosing a Compute Class
  • Start with Eco for development and testing
  • Use Standard for most production databases
  • Choose Production when you need dedicated performance guarantees for critical data

Database Flavors​

Within each compute class, choose a flavor that defines CPU and memory allocation:

FlavorDescriptionBest For
SmallEntry-level resourcesDevelopment, small apps
MediumBalanced resourcesStandard production
LargeHigher resourcesHigh-traffic applications
XLargeMaximum resourcesEnterprise workloads

The exact CPU and memory values depend on the selected compute class. Pricing is displayed when selecting a flavor.

Storage Classes​

Choose the storage class based on your I/O requirements:

ClassMax IOPSBest For
standard5,000General workloads, development
performance15,000High I/O, OLTP, analytics

Storage can be increased at any time without downtime. All storage uses NVMe SSDs.

High Availability with Galera​

Enable Galera for production-grade high availability:

ConfigurationNodesBest For
Standalone1Development, testing
Galera (3 nodes)3Production (recommended)
Galera (5 nodes)5High-demand production
Galera Cluster

With Galera enabled, your database runs on multiple nodes with synchronous replication. All nodes can accept reads and writes, providing both high availability and load distribution.

Connection Details​

After creating a database, you'll receive connection details using short service names (resolvable within the same project namespace):

FieldExample
Host (primary)my-mariadb-primary
Host (read)my-mariadb
Port3306
Databasemydb
Usernameapp_user
PasswordAuto-generated or user-defined

Connection String​

mysql://app_user:PASSWORD@my-mariadb-primary:3306/mydb

You can find the full connection string in the database Overview tab under "Connection Information".

MariaDB Endpoints

MariaDB databases expose two endpoints:

  • Primary: my-mariadb-primary:3306 — use for writes
  • Read: my-mariadb:3306 — use for reads (load-balanced across Galera nodes)

Endpoints include the port number and use short service names without the namespace suffix.

Internal Access (Default)​

By default, databases are only accessible from within your project via internal DNS.

Public Access (Optional)​

You can enable public access to connect from external applications:

  1. Go to your database settings
  2. Enable Public Access
  3. Configure the IP Allowlist — add each allowed CIDR and an optional note (up to 100 characters) to identify its purpose

When enabled:

  • A dedicated gateway is created for your database
  • Port 3306 is exposed with TLS encryption
  • Only IPs in your allowlist can connect
Security

Always use IP allowlisting when enabling public access. Never expose your database without restrictions.

Services that depend on an instance​

Some services store their data in a MariaDB instance of the project. Such a service gets its own schema and user on the MariaDB instance. These items appear in the Databases & Users tab with a read-only badge naming the service that manages them. You cannot delete a dependency-managed schema or user, or reset its password — make changes through the service that owns them instead. The MariaDB instance cannot be deleted while one of them exists.

Quick Start​

Create a Database​

  1. Go to Services in the sidebar
  2. Click Create Service and select MariaDB
  3. Enter a name for your database cluster
  4. Select compute class and flavor
  5. Configure storage size and class
  6. Enable Galera for high availability (recommended for production)
  7. Add at least one database and one user
  8. Click Create

Your database is ready in about 60 seconds (longer for Galera clusters).

Database Detail Tabs​

Once created, your MariaDB database detail view has the following tabs:

TabDescription
OverviewStatus, connection information, configuration summary
Databases & UsersCreate and manage additional databases and users
BackupsView backup history, trigger manual backups, restore from backup
ObservabilityCPU, memory, storage, and connection metrics
LogsReal-time and historical database logs

Connect from a Container​

// Node.js example with mysql2
const mysql = require('mysql2/promise');

const connection = await mysql.createConnection({
host: 'my-mariadb-primary',
user: 'app_user',
password: process.env.DB_PASSWORD,
database: 'mydb'
});

const [rows] = await connection.execute('SELECT NOW()');
console.log(rows[0]);
# Python example with mysql-connector
import mysql.connector
import os

conn = mysql.connector.connect(
host="my-mariadb-primary",
user="app_user",
password=os.environ["DB_PASSWORD"],
database="mydb"
)

cursor = conn.cursor()
cursor.execute("SELECT NOW()")
print(cursor.fetchone())

Database Architecture​

Standalone Mode​

Galera Cluster Mode​

User and Database Management​

You can create multiple users and databases within a single MariaDB instance.

Create a Database​

When creating or updating your MariaDB cluster:

  1. Navigate to the Services section
  2. Add a new database with:
    • Name: Database name (e.g., myapp_prod)
    • Character Set: Default utf8mb4
    • Collation: Default utf8mb4_unicode_ci

Create a User​

When creating or updating your MariaDB cluster:

  1. Navigate to the Users section
  2. Add a new user with:
    • Username: User identifier
    • Password: Secure password (min 8 characters)
    • Database Access: Select databases and privileges

User Privileges​

Available privileges for database access:

PrivilegeDescription
ALLAll privileges
SELECTRead data
INSERTInsert data
UPDATEUpdate data
DELETEDelete data
CREATECreate tables
DROPDrop tables
INDEXManage indexes
ALTERAlter table structure

Backups​

Automated Backups​

Configure automated backups when creating or updating your database:

  • Enable: Toggle automatic backups on/off
  • Schedule: Cron expression (default: 0 2 * * * - daily at 2 AM)
  • Retention: Based on your support plan (7 days default, contact support for extended options)
  • Storage: S3 or PVC

On-Demand Backups​

Create instant backups anytime:

  1. Go to your database
  2. Navigate to the Backups tab
  3. Click Create Backup
  4. Wait for the backup to complete

Restore from Backup​

  1. Go to the Backups tab
  2. Find the backup you want to restore
  3. Click Restore
  4. Confirm the restore operation
Restore Warning

Restoring from a backup will overwrite the current database data. This operation cannot be undone.

Download Backup​

You can download backups for offline storage:

  1. Go to the Backups tab
  2. Click the download icon on the backup
  3. A presigned URL will be generated for secure download

Pricing​

Databases are billed per-hour based on compute class, flavor, and storage:

ComponentPricing
ComputePer flavor (displayed when selecting)
Storage€0.1234/GiB/month (standard) or €0.168/GiB/month (performance)
Backups€0.07/GiB/month of backup storage, from the first byte
Galera Pricing

With Galera enabled, compute costs are multiplied by the number of nodes. For example, a 3-node cluster costs 3x the single-node price.