Azure Database for MariaDB
Key Information: Azure Database for MariaDB is a managed relational database service based on the open-source MariaDB engine. It's ideal for cloud-native applications and existing database workloads that require a fully managed relational database.
Introduction to Azure Database for MariaDB
Azure Database for MariaDB provides an enterprise-grade managed database service that allows developers to use their favorite open-source database MariaDB with the benefits of a fully managed platform on Azure. The service handles most of the database management functions like patching, backups, and high availability without requiring administrator intervention.
Key Features
- Managed Service: No infrastructure management required.
- High Availability: Built-in redundancy and failover capabilities.
- Scalability: Easily scale compute and storage resources up or down.
- Security: Robust security features including network isolation, encryption, and threat detection.
- Compatibility: Full compatibility with the MariaDB open-source engine.
- Performance: Optimized performance for various workloads.
Getting Started
Create a MariaDB Server
You can create an Azure Database for MariaDB server using the Azure portal, Azure CLI, or ARM templates. Here's a quick example using Azure CLI:
az mariadb server create \
--name mydemoserver \
--resource-group myresourcegroup \
--location eastus \
--admin-user myadmin \
--admin-password \
--sku-name B_Gen5_1 \
--tier Basic \
--version 10.3
Connecting to Your Server
Once your server is created, you can connect to it using any standard MariaDB client or application. You'll need the server name, admin username, and password.
Example using mysql
client:
mysql -h mydemoserver.mariadb.database.azure.com -u myadmin -p
Key Concepts
Server Tiers and Compute
Azure Database for MariaDB offers three pricing tiers to accommodate different workloads:
- Basic: Suitable for workloads that are just starting out and require light compute and I/O performance.
- General Purpose: Balances dedicated compute and storage for most business workloads.
- Memory Optimized: Provides high memory-to-compute ratios for performance-sensitive relational database workloads.
Compute is provisioned as vCores, and you can choose between different generations.
Storage
Storage is provisioned in fixed increments. You can scale storage independently of compute. Ensure you provision enough storage for your database's growth.
Networking
Secure your MariaDB server by configuring firewall rules or using Private Link for VNet integration. By default, servers are not accessible from the public internet.
Common Tasks
Backups and Restore
Azure Database for MariaDB automatically performs full backups of your data. You can configure the backup retention period. Point-in-time restore allows you to recover your server to a specific point in time within the retention period.
Monitoring Performance
Utilize Azure Monitor to track key metrics such as CPU utilization, memory usage, I/O operations, and connection counts. Set up alerts to be notified of performance issues.
Scaling Your Server
You can scale your server's compute tier, vCores, and storage through the Azure portal or programmatic interfaces. Plan your scaling operations to minimize downtime.