MySQL onEnable Connection Problem #144


  • New
  • Defect
Open
Assigned to _ForgeUser4509640
  • Lolmewn created this issue Jan 26, 2012

    What steps will reproduce the problem?
    1. Install v0.6.4
    2. Put some details in the config
    3. Get epic error

    What is the expected output? What do you see instead?
    A working plugin, I only saw a big error O.o

    What version of the product are you using?
    v0.6.4

    Do you have an error log of what happened?
    Yep ^^

    22:05:21 [INFO] [WebAuction] Loading WebAuction v0.6.4.
    22:05:21 [INFO] [WebAuction] WebAuction is initializing.
    22:05:21 [INFO] [WebAuction] MySQL Initializing.
    22:05:22 [SEVERE] [WebAuction] Exception getting mySQL Connection
    22:05:22 [SEVERE] com.mysql.jdbc.exceptions.jdbc4.CommunicationsException: Commu
    nications link failure

    The last packet sent successfully to the server was 0 milliseconds ago. The driv
    er has not received any packets from the server.
    22:05:22 [SEVERE]       at sun.reflect.GeneratedConstructorAccessor40.newInstanc
    e(Unknown Source)
    22:05:22 [SEVERE]       at sun.reflect.DelegatingConstructorAccessorImpl.newInst
    ance(Unknown Source)
    22:05:22 [SEVERE]       at java.lang.reflect.Constructor.newInstance(Unknown Sou
    rce)
    22:05:22 [SEVERE]       at com.mysql.jdbc.Util.handleNewInstance(Util.java:407)
    22:05:22 [SEVERE]       at com.mysql.jdbc.SQLError.createCommunicationsException
    (SQLError.java:1116)
    22:05:22 [SEVERE]       at com.mysql.jdbc.MysqlIO.<init>(MysqlIO.java:343)
    22:05:22 [SEVERE]       at com.mysql.jdbc.ConnectionImpl.coreConnect(ConnectionI
    mpl.java:2334)
    22:05:22 [SEVERE]       at com.mysql.jdbc.ConnectionImpl.connectOneTryOnly(Conne
    ctionImpl.java:2371)
    22:05:22 [SEVERE]       at com.mysql.jdbc.ConnectionImpl.createNewIO(ConnectionI
    mpl.java:2163)
    22:05:22 [SEVERE]       at com.mysql.jdbc.ConnectionImpl.<init>(ConnectionImpl.j
    ava:794)
    22:05:22 [SEVERE]       at com.mysql.jdbc.JDBC4Connection.<init>(JDBC4Connection
    .java:47)
    22:05:22 [SEVERE]       at sun.reflect.GeneratedConstructorAccessor37.newInstanc
    e(Unknown Source)
    22:05:22 [SEVERE]       at sun.reflect.DelegatingConstructorAccessorImpl.newInst
    ance(Unknown Source)
    22:05:22 [SEVERE]       at java.lang.reflect.Constructor.newInstance(Unknown Sou
    rce)
    22:05:22 [SEVERE]       at com.mysql.jdbc.Util.handleNewInstance(Util.java:407)
    22:05:22 [SEVERE]       at com.mysql.jdbc.ConnectionImpl.getInstance(ConnectionI
    mpl.java:378)
    22:05:22 [SEVERE]       at com.mysql.jdbc.NonRegisteringDriver.connect(NonRegist
    eringDriver.java:305)
    22:05:22 [SEVERE]       at java.sql.DriverManager.getConnection(Unknown Source)
    22:05:22 [SEVERE]       at java.sql.DriverManager.getConnection(Unknown Source)
    22:05:22 [SEVERE]       at me.exote.webauction.MySQLDataQueries.getConnection(My
    SQLDataQueries.java:46)
    22:05:22 [SEVERE]       at me.exote.webauction.MySQLDataQueries.tableExists(MySQ
    LDataQueries.java:77)
    22:05:22 [SEVERE]       at me.exote.webauction.MySQLDataQueries.initTables(MySQL
    DataQueries.java:114)
    22:05:22 [SEVERE]       at me.exote.webauction.WebAuction.onEnable(WebAuction.ja
    va:76)
    22:05:22 [SEVERE]       at org.bukkit.plugin.java.JavaPlugin.setEnabled(JavaPlug
    in.java:231)
    22:05:22 [SEVERE]       at org.bukkit.plugin.java.JavaPluginLoader.enablePlugin(
    JavaPluginLoader.java:1057)
    22:05:22 [SEVERE]       at org.bukkit.plugin.SimplePluginManager.enablePlugin(Si
    mplePluginManager.java:379)
    22:05:22 [SEVERE]       at org.bukkit.craftbukkit.CraftServer.loadPlugin(CraftSe
    rver.java:191)
    22:05:22 [SEVERE]       at org.bukkit.craftbukkit.CraftServer.enablePlugins(Craf
    tServer.java:174)
    22:05:22 [SEVERE]       at org.bukkit.craftbukkit.CraftServer.reload(CraftServer
    .java:444)
    22:05:22 [SEVERE]       at org.bukkit.Bukkit.reload(Bukkit.java:188)
    22:05:22 [SEVERE]       at org.bukkit.command.defaults.ReloadCommand.execute(Rel
    oadCommand.java:22)
    22:05:22 [SEVERE]       at org.bukkit.command.SimpleCommandMap.dispatch(SimpleCo
    mmandMap.java:168)
    22:05:22 [SEVERE]       at org.bukkit.craftbukkit.CraftServer.dispatchCommand(Cr
    aftServer.java:386)
    22:05:22 [SEVERE]       at org.bukkit.craftbukkit.CraftServer.dispatchCommand(Cr
    aftServer.java:382)
    22:05:22 [SEVERE]       at net.minecraft.server.MinecraftServer.b(MinecraftServe
    r.java:573)
    22:05:22 [SEVERE]       at net.minecraft.server.MinecraftServer.w(MinecraftServe
    r.java:550)
    22:05:22 [SEVERE]       at net.minecraft.server.MinecraftServer.run(MinecraftSer
    ver.java:434)
    22:05:22 [SEVERE]       at net.minecraft.server.ThreadServerApplication.run(Sour
    ceFile:465)
    22:05:22 [SEVERE] Caused by: java.net.ConnectException: Connection refused: conn
    ect
    22:05:22 [SEVERE]       at java.net.DualStackPlainSocketImpl.connect0(Native Met
    hod)
    22:05:22 [SEVERE]       at java.net.DualStackPlainSocketImpl.socketConnect(Unkno
    wn Source)
    22:05:22 [SEVERE]       at java.net.AbstractPlainSocketImpl.doConnect(Unknown So
    urce)
    22:05:22 [SEVERE]       at java.net.AbstractPlainSocketImpl.connectToAddress(Unk
    nown Source)
    22:05:22 [SEVERE]       at java.net.AbstractPlainSocketImpl.connect(Unknown Sour
    ce)
    22:05:22 [SEVERE]       at java.net.PlainSocketImpl.connect(Unknown Source)
    22:05:22 [SEVERE]       at java.net.SocksSocketImpl.connect(Unknown Source)
    22:05:22 [SEVERE]       at java.net.Socket.connect(Unknown Source)
    22:05:22 [SEVERE]       at java.net.Socket.connect(Unknown Source)
    22:05:22 [SEVERE]       at java.net.Socket.<init>(Unknown Source)
    22:05:22 [SEVERE]       at java.net.Socket.<init>(Unknown Source)
    22:05:22 [SEVERE]       at com.mysql.jdbc.StandardSocketFactory.connect(Standard
    SocketFactory.java:254)
    22:05:22 [SEVERE]       at com.mysql.jdbc.MysqlIO.<init>(MysqlIO.java:292)
    22:05:22 [SEVERE]       ... 32 more
    22:05:22 [SEVERE] Error occurred while enabling WebAuction v0.6.4 (Is it up to d
    ate?): null
    java.lang.NullPointerException
            at me.exote.webauction.MySQLDataQueries.tableExists(MySQLDataQueries.jav
    a:82)
            at me.exote.webauction.MySQLDataQueries.initTables(MySQLDataQueries.java
    :114)
            at me.exote.webauction.WebAuction.onEnable(WebAuction.java:76)
            at org.bukkit.plugin.java.JavaPlugin.setEnabled(JavaPlugin.java:231)
            at org.bukkit.plugin.java.JavaPluginLoader.enablePlugin(JavaPluginLoader
    .java:1057)
            at org.bukkit.plugin.SimplePluginManager.enablePlugin(SimplePluginManage
    r.java:379)
            at org.bukkit.craftbukkit.CraftServer.loadPlugin(CraftServer.java:191)
            at org.bukkit.craftbukkit.CraftServer.enablePlugins(CraftServer.java:174
    )
            at org.bukkit.craftbukkit.CraftServer.reload(CraftServer.java:444)
            at org.bukkit.Bukkit.reload(Bukkit.java:188)
            at org.bukkit.command.defaults.ReloadCommand.execute(ReloadCommand.java:
    22)
            at org.bukkit.command.SimpleCommandMap.dispatch(SimpleCommandMap.java:16
    8)
            at org.bukkit.craftbukkit.CraftServer.dispatchCommand(CraftServer.java:3
    86)
            at org.bukkit.craftbukkit.CraftServer.dispatchCommand(CraftServer.java:3
    82)
            at net.minecraft.server.MinecraftServer.b(MinecraftServer.java:573)
            at net.minecraft.server.MinecraftServer.w(MinecraftServer.java:550)
            at net.minecraft.server.MinecraftServer.run(MinecraftServer.java:434)
            at net.minecraft.server.ThreadServerApplication.run(SourceFile:465)

    Please provide any additional information below.

    My config file.

    MySQL:
      Host: 188.40.209.182
      Username: root
      Password: s0mep4ssw0RD <-- not the real one obviously
      Port: '3306'
      Database: minecraft
    Misc:
      ReportSales: false
      SignDelay: 1000
    Development:
      UseMultithreads: false
    Updates:
      SaleAlertFrequency: 30
      ShoutSignUpdateFrequency: 90
      RecentSignUpdateFrequency: 160

  • Lolmewn added the tags New Defect Jan 26, 2012
  • _ForgeUser4509640 posted a comment Jan 26, 2012

    How is the mysql database hosted? Is it local to your minecraft server? or is it on your web server?

    If it is not on your mc server, did you set up remote hosts to allow external servers to connect to it?

  • _ForgeUser4509640 posted a comment Jan 26, 2012

    Also that config file looks like it is from an older version.

    Make sure to get the java and web files off the direct links on the front page if you can, they are far more likely to be up to date.


To post a comment, please login or register a new account.