DevLeoko / AdvancedBan

AdvancedBan is a Spigot plugin to manage punishments on single servers and server networks
GNU General Public License v3.0
162 stars 131 forks source link

Mysql not work #635

Closed ibrahim12651 closed 9 months ago

ibrahim12651 commented 9 months ago
[21:09:01] An unexpected error has occurred connecting to the database
Check if your MySQL data is correct and if your MySQL-Server is online
Please check the plugins/AdvancedBan/logs/latest.log file and report this error in: https://github.com/DevLeoko/AdvancedBan/issues
[21:09:01] java.lang.NullPointerException: Cannot invoke "me.leoko.advancedban.shaded.com.zaxxer.hikari.HikariDataSource.getConnection()" because "this.dataSource" is null
    at me.leoko.advancedban.manager.DatabaseManager.executeStatement(DatabaseManager.java:111)
    at me.leoko.advancedban.manager.DatabaseManager.executeStatement(DatabaseManager.java:107)
    at me.leoko.advancedban.manager.DatabaseManager.executeStatement(DatabaseManager.java:92)
    at me.leoko.advancedban.manager.PunishmentManager.setup(PunishmentManager.java:41)
    at me.leoko.advancedban.Universal.setup(Universal.java:79)
    at me.leoko.advancedban.bukkit.BukkitMain.onEnable(BukkitMain.java:22)
    at org.bukkit.plugin.java.JavaPlugin.setEnabled(JavaPlugin.java:263)
    at org.bukkit.plugin.java.JavaPluginLoader.enablePlugin(JavaPluginLoader.java:342)
    at org.bukkit.plugin.SimplePluginManager.enablePlugin(SimplePluginManager.java:480)
    at org.bukkit.craftbukkit.v1_16_R3.CraftServer.enablePlugin(CraftServer.java:492)
    at org.bukkit.craftbukkit.v1_16_R3.CraftServer.enablePlugins(CraftServer.java:406)
    at net.minecraft.server.v1_16_R3.MinecraftServer.loadWorld(MinecraftServer.java:554)
    at net.minecraft.server.v1_16_R3.DedicatedServer.init(DedicatedServer.java:257)
    at net.minecraft.server.v1_16_R3.MinecraftServer.w(MinecraftServer.java:928)
    at net.minecraft.server.v1_16_R3.MinecraftServer.lambda$0(MinecraftServer.java:273)
    at java.base/java.lang.Thread.run(Thread.java:831)

Mysql online..

Hopefuls commented 9 months ago

Please provide more logs related to advanced an, such as on start. With this information you have provided we can't try to check what the issue is

ibrahim12651 commented 9 months ago

Please provide more logs related to advanced an, such as on start. With this information you have provided we can't try to check what the issue is

There was only this in the log.

ibrahim12651 commented 9 months ago

MySQL settings are correct

image

Hopefuls commented 9 months ago

MySQL settings are correct

image

According to this, your MySQL credentials are incorrect. Please ensure that you've set the correct credentials and possibly grants within your MySQL Database and that your server is trying to connect to the correct one. There's a few tutorials on how to do so.

ibrahim12651 commented 9 months ago

fix.