My next development has MySQL as relational database, then at OpenBSD I will use MariaDB.

“MariaDB Server is one of the most popular database servers in the world. It’s made by the original developers of MySQL and guaranteed to stay open source. Notable users include Wikipedia, WordPress.com and Google”.

Installation

doas pkg_add mariadb-server

I fully recommend following instructions from /usr/local/share/doc/pkg-readmes

img

Additional steps that I did:

Install databases:

doas mysql_install_db

Start MariaDB:

doas /etc/rc.d/mysqld start

Finnaly make MariaDB secure:

mysql_secure_installation

Configuration

To start MariaDB at booting time:

doas rcctl enable mysqld

If you don’t want to start at booting time:

doas rcctl start mysqld

MariaDB Documentation

At the MariaDB website you can find a lot of documentation.

Creating a database for development

CREATE DATABASE generic_development;

Creates an user for development

CREATE USER x7cc@localhost IDENTIFIED BY 'password';
GRANT ALL PRIVILEGES ON  generic_development.* to 'x7cc'@'localhost' WITH GRANT OPTION;

Enjoy! 😄