Raised This Month: $51 Target: $400
 12% 

MySQL - Could Not Connect to Database, error: [2003]


Post New Thread Reply   
 
Thread Tools Display Modes
Author Message
RiessDK
Member
Join Date: Sep 2012
Old 03-28-2017 , 18:28   MySQL - Could Not Connect to Database, error: [2003]
Reply With Quote #1

Hello. (frist, sorry for my bad english)

For history:
Well, for just like one / two week ago, i have a game server 'talking' to my mysql server.
with no problems, it just works fine.

But for like 3-4 days ago. It just stop, (Could not start my server)
I was not sure why, game console say somthing about some plugins.
I try to disable some of the plugins, them and then my server works again.

But after not being able to get a proper answer from the logs and console.
I ended up having to reinstall my game server.

The problem is:
I'm trying to connect to remote MySQL, The MySQL driver is force to load.
I am doing this just to be safe it works, have some problem with that before.

Also, I have type my game server ip in the remote mysql connection. (Cpanel)
Also. tested it with "heidimysql" with my own ip, it works.

I have try to plugins to get a clear connection:

First plugin: mysqlt_bans.smx
second plugin: admin-sql-threaded.smx

Both say the same error in game conesole that is:
Could Not Connect to Database, error: [2003]: Can't connect to MySQL server on 'myprovider.com' (4)

I have tried me with a new created database and user.
Also, I have reinstalled 3 times.

I have try different version of SourceMod
First: 1.8.0 - 5981
second: 1.8.0 - 5967

Well now I'm lost, can't say why it will not make that connection.
It was before with no problem.

Hope some of you maybe, have a trick or can say something.

Best.
RiessDK
Attached Thumbnails
Click image for larger version

Name:	exts-plugins001.png
Views:	249
Size:	68.4 KB
ID:	161762  

Last edited by RiessDK; 03-28-2017 at 18:32.
RiessDK is offline
OSWO
Senior Member
Join Date: Jul 2015
Location: United Kingdom, London
Old 03-29-2017 , 01:21   Re: MySQL - Could Not Connect to Database, error: [2003]
Reply With Quote #2

did you comment out:

bind-address:127.0.0.1 in my.cnf

i have no clue if its a vps or a offered database.
__________________
SourceTimer | WeaponSkins++ | BasePlugins++ https://github.com/OSCAR-WOS

Last edited by OSWO; 03-29-2017 at 01:22.
OSWO is offline
RiessDK
Member
Join Date: Sep 2012
Old 03-29-2017 , 01:31   Re: MySQL - Could Not Connect to Database, error: [2003]
Reply With Quote #3

Quote:
Originally Posted by OSWO View Post
did you comment out:

bind-address:127.0.0.1 in my.cnf

i have no clue if its a vps or a offered database.
Both things are hosted outside, the are not on the same server.
That is also why i need to use the remote connection.

Also, my database is on a web-server. (like a webhotel service)

I don't understand what you mean with (bind-address:127.0.0.1 in my.cnf)
RiessDK is offline
micazoid
Veteran Member
Join Date: Oct 2010
Location: Munich - Germany
Old 03-29-2017 , 09:09   Re: MySQL - Could Not Connect to Database, error: [2003]
Reply With Quote #4

Please show the errorlog what is mentioned in your screenshot.

Where is you gameserver at? OS? Dedicated Server or rented?

What Game is this for?
__________________
micazoid is offline
RiessDK
Member
Join Date: Sep 2012
Old 03-29-2017 , 16:32   Re: MySQL - Could Not Connect to Database, error: [2003]
Reply With Quote #5

Quote:
Originally Posted by micazoid View Post
Please show the errorlog what is mentioned in your screenshot.

Where is you gameserver at? OS? Dedicated Server or rented?

What Game is this for?
It is a rented CSGO server. And the error is in the title.

But here is the full code:
Code:
L 03/28/2017 - 14:21:33: Error log file session closed.
L 03/28/2017 - 23:50:06: SourceMod error session started
L 03/28/2017 - 23:50:06: Info (map "de_dust2") (file "errors_20170328.log")
L 03/28/2017 - 23:50:06: [mysqlt_bans.smx] [MYBans] Could Not Connect to Database, error: [2003]: Can't connect to MySQL server on 'hvid1.azehosting.net' (4)
L 03/28/2017 - 23:50:07: [SM] Exception reported: Script execution timed out
L 03/28/2017 - 23:50:07: [SM] Blaming: mysqlt_bans.smx
L 03/28/2017 - 23:50:07: [SM] Call stack trace:
L 03/28/2017 - 23:50:07: [SM]   [1] Line 18, /home/groups/alliedmodders/forums/files/5/8/2/6/8/115397.attach::OnPluginStart
L 03/28/2017 - 23:50:07: [SM] Unable to load plugin "mysqlt_bans.smx": Error detected in plugin startup (see error logs)
RiessDK is offline
micazoid
Veteran Member
Join Date: Oct 2010
Location: Munich - Germany
Old 03-30-2017 , 07:46   Re: MySQL - Could Not Connect to Database, error: [2003]
Reply With Quote #6

Ask your host if he closed some ports. It worked, so the host has changed something
__________________
micazoid is offline
OSWO
Senior Member
Join Date: Jul 2015
Location: United Kingdom, London
Old 03-30-2017 , 15:29   Re: MySQL - Could Not Connect to Database, error: [2003]
Reply With Quote #7

https://gyazo.com/d18e46b34cebee69f89ce5d3721d6e1f

When it's commented out, it means the sql servers accepts all inbound requests.
__________________
SourceTimer | WeaponSkins++ | BasePlugins++ https://github.com/OSCAR-WOS
OSWO is offline
RiessDK
Member
Join Date: Sep 2012
Old 03-30-2017 , 16:20   Re: MySQL - Could Not Connect to Database, error: [2003]
Reply With Quote #8

Quote:
Originally Posted by OSWO View Post
https://gyazo.com/d18e46b34cebee69f89ce5d3721d6e1f

When it's commented out, it means the sql servers accepts all inbound requests.
Not sure i can't edit in that file, both my gameserver and my databasse.
Is hosted in a rented server. But if that not is the case. I will need a bit of more help please.


Quote:
Originally Posted by micazoid View Post
https://gyazo.com/d18e46b34cebee69f89ce5d3721d6e1f

Ask your host if he closed some ports. It worked, so the host has changed something
With one, the gameserver or the webhotel (there mysql databasse is)
Just to be sure.
RiessDK is offline
WildCard65
Veteran Member
Join Date: Aug 2013
Location: Canada
Old 03-30-2017 , 17:57   Re: MySQL - Could Not Connect to Database, error: [2003]
Reply With Quote #9

Quote:
Originally Posted by RiessDK View Post
Not sure i can't edit in that file, both my gameserver and my databasse.
Is hosted in a rented server. But if that not is the case. I will need a bit of more help please.




With one, the gameserver or the webhotel (there mysql databasse is)
Just to be sure.
The mysql server's (on machine where database lives) config.
__________________
WildCard65 is offline
RiessDK
Member
Join Date: Sep 2012
Old 03-30-2017 , 18:39   Re: MySQL - Could Not Connect to Database, error: [2003]
Reply With Quote #10

Quote:
Originally Posted by WildCard65 View Post
The mysql server's (on machine where database lives) config.
Okay, but the MySQL is also an rented service. I am not sure i have access to that config.
Or any config at all.
RiessDK is offline
Reply



Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off

Forum Jump


All times are GMT -4. The time now is 12:05.


Powered by vBulletin®
Copyright ©2000 - 2024, vBulletin Solutions, Inc.
Theme made by Freecode