MIGRATION
MySQL
SECURITY
SQL

Introducing MariaDB Catalogs: What They Are and How They Work

intro

MariaDB catalogs are an upcoming feature in MariaDB Server. Catalogs will provide customers of hosting services with better control over their data.

Tools used in the tutorial
Tool Description Link
Dbvisualizer DBVISUALIZER
TOP RATED DATABASE MANAGEMENT TOOL AND SQL CLIENT
mariadb MARIADB
THE MARIADB DATABASE
MySQL logo MySQL
THE MYSQL DATABASE

Many hosting providers have one database server that supports many clients—in that case, customers are assigned differently named schemas. That’s precisely why you may already be familiar with your database being named “u8875_project” instead of the name of your project. It’s all part of the same puzzle—and it all has a lot of limitations including, but not limited to making the use of multiple databases impossible, backing up all the data in a MariaDB Server impossible as users simply don’t have access to the mysql database for security reasons and because of that, the mysql database cannot be copied meaning that we cannot take a copy of our users, their permissions, and other things, and restricting access to the error log in MariaDB Server. MariaDB catalogs solve these issues!

In this article, we’ll delve into MariaDB catalogs, learning what they are and how they work. Let’s dive in!

What Are MariaDB Catalogs?

Catalogs are an upcoming feature in MariaDB. They will solve many issues for hosting providers and for users alike—hosting providers will no longer have to deal with “this user seems to be almost inactive, but we still need to keep the database up” scenarios. Thanks to them, users will have better control over their database schemas with the ability to create multiple databases, back up all the data, access the entirety of the logs, and more.

The purpose of MariaDB catalogs is to provide users with almost the same user experience as if they were the sole owner of the database server, giving hosting providers more leniency to perform database tasks.

How Do MariaDB Catalogs Work?

MariaDB catalogs solve issues in the following ways:

  1. Each user is assigned their own MariaDB catalog—their own MariaDB “space” designed exclusively for them.
  2. When connecting to a MariaDB Server, the catalog needs to be specified—by default, MariaDB Server will use the default—or “def”—catalog.
  3. When users are connected to their MariaDB Server and catalog, the privilege system about that catalog is being used (each catalog will have its own privileges.)
  4. Upon login, a user will be able to see catalogs, but not access or change other catalogs (in particular, catalogs not belonging to them.)
  5. If we want to change the catalog we’re working in, we must either log out from the current catalog and then log in to another, or log in to a catalog anew.

In other words, catalogs are mini MariaDB dedicated servers. Each user is assigned one catalog which may either be specified in my.cnf option file or as an argument. Plus, each user has access to the entirety of the MariaDB database (that includes all settings, the user table in the mysql database, etc.)

That also means that specific MariaDB functionality will also work differently:

  1. SHOW STATUS; will show the status data for the entire MariaDB Server and not for the catalog you’re currently in.
  2. The MariaDB Server will only have the ability to read specific tables from the mysql schema. These include plugin, help_*, time_zone*, gtid_slave_pos, innodb_index_stats, servers, transaction_registry, udf, and performance_schema.
  3. There will be a new concept called a catalog root user—the permissions for these users will be stored in the def catalog. These users will usually be superadmins.
  4. The storage layout used by MariaDB will have the ability to be changed — there will be an “original” data layout and a “catalog” data layout. The layout will depend how MariaDB Server will be installed on the server in the first place (i.e. if MariaDB Server is installed with the use-catalogs option or not.)
  5. Once MariaDB catalogs are introduced, there will be a couple of commands available exclusively for them. These include USE CATALOG, CREATE CATALOG, DROP CATALOG, ALTER CATALOG, SHOW CATALOGS, SHOW CREATE CATALOG, SELECT CATALOG, and others.

Wondering the difference between MySQL and MariaDB? Check out our MariaDB vs MySQL comparison article!

What to Expect in the Future?

With MariaDB catalogs now in the headlights of MariaDB Server, different things may be on the horizon too. Judging by December 2023 blog entry by MariaDB, in the future, MariaDB users can expect:

  1. Online schema changes (a similar topic has been discussed in depth by MariaDB engineers in the most recent MariaDB Server Fest) to avoid ALTER TABLE messing up other operations.
  2. More JSON-based functions within MariaDB Server.
  3. Improved InnoDB table space management
  4. Enhanced and fine-tuned privilege system
  5. A brand-new query optimizer.

All of those features are meant to make MariaDB run as smooth as butter—however, with them or without, SQL clients like the one developed by DbVisualizer will help smooth the way.

DbVisualizer is the #1 choice for many top-notch companies across the globe including Tesla, NASA, Volkswagen, and many others. Click here to grab your free trial and try the power of DbVisualizer and unleash the support for many database management systems, ERD-like schema generation, and so much more for yourself.

FAQ

What are MariaDB catalogs?

MariaDB catalogs are an upcoming feature within MariaDB that aims to provide users with almost the same experience as if they were the sole owners of the database server and provide hosting providers with more leniency when performing database-related tasks.

When will MariaDB catalogs be introduced?

According to MariaDB, catalogs will be introduced in an upcoming release of MariaDB Server.

Should I use MariaDB catalogs?

MariaDB catalogs are not for everyone. However, as it’s a multi-tenancy feature where a single instance of MariaDB Server handles multiple “tenants” (customers) using it, it will be mostly used by hosting providers or those using shared hosting services.

Why should I use an SQL client?

You should use a SQL client like the one provided by DbVisualizer because it provides support for many database management systems, allows you to easily access, optimize, and explore your data, as well as lets you take control of your data by letting you visualize the results in it, edit, or export the data as necessary.

Dbvis download link img
About the author
LukasVileikisPhoto
Lukas Vileikis
Lukas Vileikis is an ethical hacker and a frequent conference speaker. He runs one of the biggest & fastest data breach search engines in the world - BreachDirectory.com, frequently speaks at conferences and blogs in multiple places including his blog over at lukasvileikis.com.
The Table Icon
Sign up to receive The Table's roundup
More from the table
Title Author Tags Length Published
title

MySQL Nullable Columns: Everything You Need to Know

author Antonello Zanini tags MySQL 6 min 2024-12-03
title

A Complete Guide to the MySQL GROUP_CONCAT Function

author Antonello Zanini tags Data aggregation MySQL 8 min 2024-12-02
title

How and Why to Add an Index in SQL

author Lukas Vileikis tags MySQL POSTGRESQL Search SQL SQL SERVER 8 min 2024-11-28
title

MySQL 9.0 and the New EXPLAIN Features

author Lukas Vileikis tags MySQL SQL 9 min 2024-11-27
title

Massive SQL DELETE Operations and Database Purging Explained

author Lukas Vileikis tags DELETE SQL 4 min 2024-11-26
title

MySQL CAST: A Guide to the Data Conversion Function

author Antonello Zanini tags MySQL 3 min 2024-11-25
title

Postgres Create Array of Numbers: Complete Guide

author Lukas Vileikis tags POSTGRESQL SQL 7 min 2024-11-21
title

List of SQL Reserved Words in All Major Databases

author Antonello Zanini tags MySQL ORACLE POSTGRESQL SQL SQL SERVER 16 min 2024-11-20
title

A Beginner’s Guide to SQL & Relational Database Management Systems

author Leslie S. Gyamfi tags BEGINNER SQL 5 min 2024-11-19
title

SQL Variable: What It Is and How To Use It

author Antonello Zanini tags MySQL ORACLE POSTGRESQL SQL SQL SERVER 8 min 2024-11-18

The content provided on dbvis.com/thetable, including but not limited to code and examples, is intended for educational and informational purposes only. We do not make any warranties or representations of any kind. Read more here.

Cookie policy

We use cookies to ensure that we give you the best experience on our website. However you can change your cookie settings at any time in your browser settings. Please find our cookie policy here ↗