#plugins having trouble connecting to database
25 messages · Page 1 of 1 (latest)
If your server cannot see the database, please make sure your mod/plugin is connecting to pterodactyl0 interface 172.18.0.1 or the public IP to reach the local database. You can not use localhost or 127.0.0.1 as that would be the container itself.
You also have to configure the database bind-address to listen on all interfaces following the guide below.
https://pterodactyl.io/tutorials/mysql_setup.html#creating-a-database-host-for-nodes
I did bind it too 0.0.0.0 and in the plugin and in the database on the panel I use my domain
Show your config
The plugin config where you're telling it what to connect to
Is the database on the same machine as your game server?
Use 172.18.0.1 as the IP in your config if it's on the same machine
that didnt work
You may need a firewall rule if that doesn't connect after the change.
sudo ufw allow from 172.18.0.0/16 to any port 3306 proto tcp
[21:23:10 ERROR]: [LiteBans] litebans-pool - Exception during pool initialization.
[21:23:10 ERROR]: [LiteBans] Failed to connect to [jdbc:mysql://172.18.0.1:3306/s1_litebans_;useSSL=false&serverTimezone=UTC].
[21:23:10 ERROR]: [LiteBans] Error: Failed to initialize pool: Unknown system variable 'transaction_isolation'
[21:23:10 ERROR]: [LiteBans] Cause: Unknown system variable 'transaction_isolation'
[21:23:10 INFO]: Litebans reloaded. Failed to connect to database.
Also if you're using MariaDB make sure to set the driver in the config to MariaDB instead of MySQL. If you followed the default guide when installing the panel you'll have MariaDB.
👍