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 Database for Your Server.
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 Spigot or Paper. The steps may be different when used in other server types.
As an example, let's configure the plugin LuckPerms to store permissions data into your newly created MySQL database. This is a very popular plugin for managing player permissions.
# Using a MySQL Database
As an example, let's configure the plugin LuckPerms to store permissions data into your newly created MySQL database. This is a very popular plugin for managing player permissions.
- Navigate to the Files Tab
- Head into the plugins folder, and then the LuckPerms folder.
- Click the
config.yml
file to edit it. - Locate the Storage Method option and change it to
mysql
. - Under the data section, change the values to your MySQL database information.
Note
For the purpose of this tutorial, we will be using sample information as an example, which you can find on your panel under Databases and then clicking on your desired database.
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. If not, feel free to let our support team know and we can help you out.