Home Discord Store Get ClothesPlus Login
Esc

MySQL Setup

Configure MySQL for cross-server skin synchronization on Velocity and BungeeCord networks.

Overview

MySQL is required when running ClothesPlus on a Velocity or BungeeCord network to synchronize player skins and wardrobe data across multiple backend servers.

MySQL is optional for single-server setups. ClothesPlus uses file-based storage by default.

Prerequisites

  • A MySQL 5.7+ or MariaDB 10.3+ database server
  • Network access from your Minecraft server(s) to the database
  • A database user with CREATE, SELECT, INSERT, UPDATE, DELETE privileges

Configuration

1
Create the database

Create a new database on your MySQL server:

```sql CREATE DATABASE clothesplus; CREATE USER 'clothesuser'@'%' IDENTIFIED BY 'your-secure-password'; GRANT ALL PRIVILEGES ON clothesplus.* TO 'clothesuser'@'%'; FLUSH PRIVILEGES; ```

2
Update config.yml

Edit plugins/ClothesPlus/config.yml on each backend server:

```yaml config.yml mysql: enabled: true host: "your-mysql-host.com" port: 3306 database: "clothesplus" username: "clothesuser" password: "your-secure-password" pool-size: 10 use-ssl: false ```

3
Enable Velocity sync (if applicable)

If using Velocity or BungeeCord as a proxy:

```yaml config.yml velocity: enabled: true ```

For full functionality, install the ClothesPlusVelocity plugin on your proxy server. This ensures skin resets and updates are broadcast to all backend servers.

4
Restart all servers

Restart each backend server. ClothesPlus will automatically create the required tables in the database.

5
Verify

Run /clothes mysql on each server to check the connection status.

Configuration Reference

SettingDefaultDescription
enabledfalseEnable MySQL storage
host127.0.0.1MySQL server hostname or IP
port3306MySQL server port
databaseclothesplusDatabase name
usernameclothesuserDatabase user
passwordchangemeDatabase password
pool-size10Connection pool size (increase for busy servers)
use-sslfalseEnable SSL for database connections

Make sure all backend servers point to the same database with identical credentials. Mismatched configurations will cause sync issues.