How to Use a MySQL Database on Your Minecraft Server

MySQL Databases are one of the many ways to store server data, commonly available for plugins.

Your Shockbyte server comes with a free MySQL database that can be used to store new or existing data. If you do not have one yet, you can create a MySQL Database by following this tutorial: Creating a MySQL Database

Once you've created a MySQL database, to use it you simply need to provide your database information on the configuration file of a plugin that supports storing of data into a MySQL database. Generally, the information required are the host, username, password, and the name of the database.

Note: The example below assumes your server is running Bukkit or Spigot. The steps may be different when used in other server types.

As an example, let's configure LuckPerms to store permissions data into your newly created MySQL database. 

  1. On the left sidebar of your Multicraft Panel, navigate  to Files > FTP File Access to access your server directory (How to Access Your Server Directory).
    MySQL Luckperms - access server files

  2. On your server directory, navigate to Luckperms folder found within the plugins folder.
    MySQL Luckperms - Luckperms folder

  3. In the Luckperms folder, edit the config.yml file. 
    MySQL Luckperms - edit config file

  4. Locate the storage-method option. By default, it is set to h2 so change its value to mysql
    MySQL Luckperms - storage method

  5. Under the data section of the config file, change the values so that it corresponds to your MySQL database information.

    For the purpose of this tutorial, we will be using these information as an example which can be found when you navigate to Advanced > MySQL Database on your Multicraft panel.
    MySQL Luckperms - SQL Information

    MySQL Luckperms - enter details into config

  6. Save the config.yml file and restart your server to apply the changes made.
    MySQL Luckperms - save config.yml file

If you have successfully setup Luckperms to use a MySQL database, it should begin storing all plugin data into the database. Each plugin that supports MySQL database storage will have similar steps to configure the plugin to use your database.

Looking for more MySQL guides? Click here! 

If you require any further assistance, please contact our support at: https://shockbyte.com/billing/submitticket.php

Mitchell Smith

Managing Director @ Shockbyte

  • MySQL, MySQL Database, database, plugins
  • 48 Users Found This Useful
Was this answer helpful?

Related Articles

How to Configure Autosaving of Your Minecraft World

Minecraft servers have the ability to automatically save world data periodically. By default,...

How to Disable Player Advancement Announcements

Advancement is a feature available exclusively on Minecraft Java Edition wherein players can...

How to Download Your Minecraft Server World

We have a video tutorial on downloading your Minecraft server world: If you want to use your...

How to Modify Spigot Configuration (spigot.yml)

The Spigot Config file has many options and settings that can be modified to change the behavior...

How to Reset The Nether on Your Minecraft Server

With the drastic change to the nether in the latest 1.16 update, many players may want to reset...