Skip to content

Home Lab - Online notes

  • Full-Stack Infrastructure Docs

Installing MariaDB (12.3)

June 12, 2026November 23, 2025 by sandeep

Why MariaDB 12.3? — Native Vector DB Support

The key motivation for deploying MariaDB 11.8 is its new native vector data type and vector indexes, allowing the database to efficiently store and query embedding vectors used in:

  • Semantic search
  • LLM response ranking
  • Recommendation systems
  • Similarity detection
  • Metadata-enriched AI pipelines

MariaDB 11.8 introduces:

  • VECTOR column type
  • Distance functions like cosine similarity, Euclidean distance
  • Approximate nearest neighbor (ANN) search
  • Optimizations for fast multi-dimensional vector operations

This makes MariaDB 11.8 ideal for environments where an application database and vector store can be unified into a single system.


1. Install Required Packages

Update the package index and install utilities needed for adding external repositories:

sudo apt update
sudo apt install -y curl ca-certificates software-properties-common

2. Download and execute the official MariaDB setup script.

curl -LsSO https://r.mariadb.com/downloads/mariadb_repo_setup

sudo bash mariadb_repo_setup --mariadb-server-version="mariadb-12.3"

3. Install Mariadb

sudo apt update
sudo apt install -y mariadb-server mariadb-client

4. Lock Down the DB

sudo mariadb-secure-installation

5. Verify the MariaDB Service

Check whether the service is running:

sudo systemctl status mariadb

If everything is correct, the service should display as active (running).

6. Enable Auto-Start on Boot

Ensure MariaDB starts automatically:

sudo systemctl enable mariadb

7. Enable Remote Connectivity (Optional)

To allow external servers or applications to connect, edit MariaDB’s main server configuration:

sudo nano /etc/mysql/mariadb.conf.d/50-server.cnf

Locate:

bind-address = 127.0.0.1

Modify to:

bind-address = 0.0.0.0

Restart MariaDB:

sudo systemctl restart mariadb

You must also create remote MySQL users with appropriate privileges:

Example:

CREATE DATABASE pm;

CREATE USER 'pmuser'@'%' IDENTIFIED BY 'strongpassword';

GRANT ALL PRIVILEGES ON pm.* TO 'pmuser'@'%';

FLUSH PRIVILEGES;
Categories How To Tags 11.8, ANN search, cosine similarity, Euclidean distance, LLM response ranking, mariadb, Metadata-enriched AI pipelines, Semantic search, Similarity detection, vector db
WordPress for documenting and sharing information.
Installing PostgreSQL 16

Recent Posts

  • VLLM Service
  • RabbitMQ for PoCs
  • NFS Server for PoCs
  • Custom Cloud Image for AI Workloads
  • Installing Ceph with cephadm
  • Preparing Servers for Ceph
  • Installing Gerrit Code Review
  • Installing PostgreSQL 16
  • Installing MariaDB (12.3)
  • WordPress for documenting and sharing information.
  • Setting up Ubuntu repository mirror
  • Wildcard SSL Certficates
  • Orchestrating VMs using scripts and templates
  • Install KVM and Build a Custom Ubuntu 24.04 Cloud Image
  • Management Server for Home Lab
  • Infrastructure overview
© 2026 Home Lab - Online notes • Built with GeneratePress