Jump to content
  • 0
Sign in to follow this  
deliver

GTLVote help !! (error connecting to database)

Question

[GTLVote V1.1] Settings initializing...
[GTLVote V1.1] Error connecting to the database.
com.mysql.jdbc.exceptions.jdbc4.CommunicationsException: Communications link fai
lure

The last packet successfully received from the server was 1,414,767,871,557 mill
iseconds ago. The last packet sent successfully to the server was 0 millisecond
s ago.
at sun.reflect.NativeConstructorAccessorImpl.newInstance0(Native Method)

at sun.reflect.NativeConstructorAccessorImpl.newInstance(Unknown Source)

at sun.reflect.DelegatingConstructorAccessorImpl.newInstance(Unknown Sou
rce)
at java.lang.reflect.Constructor.newInstance(Unknown Source)
at com.mysql.jdbc.Util.handleNewInstance(Util.java:406)
at com.mysql.jdbc.SQLError.createCommunicationsException(SQLError.java:1
074)
at com.mysql.jdbc.ConnectionImpl.createNewIO(ConnectionImpl.java:2214)
at com.mysql.jdbc.ConnectionImpl.<init>(ConnectionImpl.java:773)
at com.mysql.jdbc.JDBC4Connection.<init>(JDBC4Connection.java:46)
at sun.reflect.NativeConstructorAccessorImpl.newInstance0(Native Method)

at sun.reflect.NativeConstructorAccessorImpl.newInstance(Unknown Source)

at sun.reflect.DelegatingConstructorAccessorImpl.newInstance(Unknown Sou
rce)
at java.lang.reflect.Constructor.newInstance(Unknown Source)
at com.mysql.jdbc.Util.handleNewInstance(Util.java:406)
at com.mysql.jdbc.ConnectionImpl.getInstance(ConnectionImpl.java:352)
at com.mysql.jdbc.NonRegisteringDriver.connect(NonRegisteringDriver.java
:282)
at java.sql.DriverManager.getConnection(Unknown Source)
at java.sql.DriverManager.getConnection(Unknown Source)
at org.Vote.Connect.connect(Connect.java:18)
at org.Vote.MainLoader.<init>(MainLoader.java:22)
at server.Server.<clinit>(Server.java:73)
Caused by: com.mysql.jdbc.exceptions.jdbc4.CommunicationsException: Communicatio
ns link failure

The last packet successfully received from the server was 1,414,767,871,555 mill
iseconds ago. The last packet sent successfully to the server was 0 millisecond
s ago.
at sun.reflect.NativeConstructorAccessorImpl.newInstance0(Native Method)

at sun.reflect.NativeConstructorAccessorImpl.newInstance(Unknown Source)

at sun.reflect.DelegatingConstructorAccessorImpl.newInstance(Unknown Sou
rce)
at java.lang.reflect.Constructor.newInstance(Unknown Source)
at com.mysql.jdbc.Util.handleNewInstance(Util.java:406)
at com.mysql.jdbc.SQLError.createCommunicationsException(SQLError.java:1
074)
at com.mysql.jdbc.MysqlIO.<init>(MysqlIO.java:341)
at com.mysql.jdbc.ConnectionImpl.createNewIO(ConnectionImpl.java:2137)
... 14 more
Caused by: java.net.ConnectException: Connection refused: connect
at java.net.DualStackPlainSocketImpl.connect0(Native Method)
at java.net.DualStackPlainSocketImpl.socketConnect(Unknown Source)
at java.net.AbstractPlainSocketImpl.doConnect(Unknown Source)
at java.net.AbstractPlainSocketImpl.connectToAddress(Unknown Source)
at java.net.AbstractPlainSocketImpl.connect(Unknown Source)
at java.net.PlainSocketImpl.connect(Unknown Source)
at java.net.SocksSocketImpl.connect(Unknown Source)
at java.net.Socket.connect(Unknown Source)
at java.net.Socket.connect(Unknown Source)
at java.net.Socket.<init>(Unknown Source)
at java.net.Socket.<init>(Unknown Source)
at com.mysql.jdbc.StandardSocketFactory.connect(StandardSocketFactory.ja
va:253)
at com.mysql.jdbc.MysqlIO.<init>(MysqlIO.java:290)
... 15 more
[10/31/14 4:04 PM]: Server is running.
[10/31/14 4:04 PM]: [ObjectDef] DONE LOADING OBJECT CONFIGURATION
[10/31/14 4:04 PM]: [Region] DONE LOADING REGION CONFIGURATIONS
[10/31/14 4:04 PM]: Accepting connections on port 43594


I have done all correct in MYSQL + SERVER SIDED BUT I STILL GET THIS...

can anyone assist me by teamview or something?

please leave ur skype below :s

Share this post


Link to post
Share on other sites

8 answers to this question

Recommended Posts

  • 0
[quote name='deliver'][GTLVote V1.1] Settings initializing...
[GTLVote V1.1] Error connecting to the database.
com.mysql.jdbc.exceptions.jdbc4.CommunicationsException: [B]Communications link failure[/B]
[/QUOTE]

Honestly though, read the error prints.. they help. Your server cannot connect to the SQL database. It's most likely wrong login credentials, so double check those. Also make sure your server is white-listed on your website if you're using cPanel or any other website management softwares.

Following a tutorial doesn't always guarantee success. Be prepared think critically and understand what you're using. Edited by Hope

Share this post


Link to post
Share on other sites
  • 0
[quote name='Hope']Honestly though, read the error prints.. they help. Your server cannot connect to the SQL database. It's most likely wrong login credentials, so double check those. Also make sure your server is white-listed on your website if you're using cPanel or any other website management softwares.

Following a tutorial doesn't always guarantee success. Be prepared think critically and understand what you're using.[/QUOTE]

Thank you for that but im almost 100% confident i have done everything correct.. Any chance you might wonna help out?

skype - juniorcy1994

I'd very much appriciate some help.

cheers

Share this post


Link to post
Share on other sites
  • 0
Misunderstood your question - sorry, you're trying to make it connect to highscores?

Share this post


Link to post
Share on other sites
  • 0
[quote name='deliver']no. its for autovote[/QUOTE]

It's been a long day.

Anyways, what you could do, to troubleshoot, is set up a free mySQL, and connect the server to that, and if it connects, then it's your database on your website.

Or, you could post the server sided code (comment out the passwords and maybe bits of the IP), and maybe take a screenshot of your database set up.

Share this post


Link to post
Share on other sites
  • 0
could any member just add me on skype to help me out over teamviewer?

skype - juniorcy1994

Share this post


Link to post
Share on other sites
  • 0
what hope mentioned earlier: whitelisting the servers IP Address
make sure your web host provides you with Remote MySQL
if it does add your vps or public ip to it

Its saying it cannot connect at all
so before you get Access Denied due to incorrect login info
youd have to make sure its actually connecting.
so make sure your mysql host is correct server sided
and make sure your mysql table is the one used for your voting page web sided

if you cant afford a webhost with remote mysql then host it yourself
with XAMPP
using xampp is probably your best bet. ofc youd have to keep your pc on all the time
but errors wont occur as often gl!

Share this post


Link to post
Share on other sites
Sign in to follow this  

×