SRCDS Steam group


Cannot connect to the database (any plugin) after moving to linux.
#1
Hi. I'm using CentOS 5. And after moving to Linux, neither of the plugins (for example sourcebans) can connect to the database. I believe this is linux related, but must've been solved before by someone here. And i'm just getting errors, like the database being offline for example. It works from home pc too. It doesn't from dedicated server PC.

Anyway, if someone know something - please share. Thanks.

P.S. i have also tried apt-get install lib32gcc1 on Ubuntu 9.10, but it didn't worked, the packed couldn't be installed, so i moved to CentOs 5.
Reply
#2
Is mysql running?
Did you install PhpMyAdmin?

More info please
Reply
#3
I repeat myself, maybe i didn't made myself clear last time, sorry, i'm not a native english speaker.

Everything is working now from my old computer (home pc). It connects to the database and everything).
Everything is NOT working from the new server PC. Players can connect to the server, but the server cannot connect to the database.
At the same time. I also tried to turn off the old pc, in case there is a limit of connections.
Database is on my webserver.
My old PC have Windows 7 x64.
My new PC have CentOs 5.
They are both connecting to the same webserver PC.
Running SRCDS (Counter - Strike Source).
Reply
#4
I repeat Arjen: Give us more informations!

Where is the mysql server running/hosted Is it working in general, etc., etc.
Reply
#5
Is there anything in the logging of the gameserver?

../addons/sourcemod/logs/sourcebans.log

Did you change ../addons/sourcemod/configs/databases.cfg on the gameserver?

Did you change the ip in the sourcebans webconfig?
Reply
#6
Maybe you should allow the new PC to connect to the database and double verify that the information is correctly set.
Reply
#7
@terror:

Webserver is hosted on another computer. A webhosting computer. Database is there, webserver is there. A hosting at my friend's company. Everything is okay in there. My old server connects there and works. New server doesn't.

@Arjen:

I can copy you it directly from the terminal:

L 06/20/2010 - 17:25:23: [sourcebans.smx] Database failure: [2003]: Can't connec t to MySQL server on '***************(changed)' (111)
L 06/20/2010 - 17:25:23: [sm_commstools.smx] Database failure: [2003]: Can't con nect to MySQL server on '*********(changed...)' (111)
CommsTools - Unable to connect to database
L 06/20/2010 - 17:25:23: [sm_rename.smx] Database failure: [2003]: Can't connect to MySQL server on '*******(and changed)' (111)
Rename - Unable to connect to database
L 06/20/2010 - 17:25:23: [SM] Native "SetCookieMenuItem" reported: Clientprefs i s disabled due to a failed database connection
L 06/20/2010 - 17:25:23: [SM] Displaying call stack trace for plugin "savescores .smx":


And later:

L 06/20/2010 - 17:30:23: [SM] Native "SQL_TQuery" reported: Invalid database Handle 0 (error: 4)
L 06/20/2010 - 17:30:23: [SM] Displaying call stack trace for plugin "sourcebans.smx":
L 06/20/2010 - 17:30:23: [SM] [0] Line 1382, sourcebans.sp:rocessQueueCallback()

And i've copied old database.cfg file over to the game server. so yes, it is correct. I double checked it too.

@realchamp:

Okay, how can i do that? And yes, i've verified that the information in all configurations are correct. A few times. I was trying to make it work whole day yesterday and today. Even reinstalled Linux to Ubuntu and then back to CentOs.


And by the way, at the website my server is being showed as running, people count is okay, so the website can communicate with my server, but the database cannot. Same as people can join, but the server cannot connect to the database.
Reply
#8
http://www.sourcebans.net/faq/i-get-following-error-database-failure-1045
Reply
#9
That has already been done, contacted and asked my web provider. That's why it works with my old computer. I can think of something firewall or some chmod need at Linux. But i have no idea about such things, because i don't know anything about Linux.
Reply
#10
Your server is 64 bit, amirite? If so - you need some more 32bit libraries for dbi.mysql.ext.so to work. Use ldd to find which one you need.
Reply
#11
Yea, it's 64x. I've ran this:
ldd -d dbi.mysql.ext.so
libz.so.1 => /usr/lib/libz.so.1 (0xb7d2d000)
libpthread.so.0 => /lib/libpthread.so.0 (0xb7d16000)
libm.so.6 => /lib/libm.so.6 (0xb7cef000)
libc.so.6 => /lib/libc.so.6 (0xb7bab000)
/lib/ld-linux.so.2 (0xb7f1f000)

Then checked those places for the files and they all were there.
Reply
#12
try connecting the mysql server from linux console, i.e. run
Code:
mysql --host=<database-ip> -u <database-username> -p
if that works, the problem is with sourcemod not being able to connect to (probably) any mysql databse - you might have done something wrong during installation. if even that does not work it's not sourcemod. maybe your mysql server doesn't allow connections from your new machine.
http://www.fpsmeter.org
http://wiki.fragaholics.de/index.php/EN:Linux_Optimization_Guide (Linux Kernel HOWTO!)
Do not ask technical questions via PM!
Reply
#13
(06-22-2010, 05:36 PM)BehaartesEtwas Wrote:  try connecting the mysql server from linux console, i.e. run
Code:
mysql --host=<database-ip> -u <database-username> -p
if that works, the problem is with sourcemod not being able to connect to (probably) any mysql databse - you might have done something wrong during installation. if even that does not work it's not sourcemod. maybe your mysql server doesn't allow connections from your new machine.

Probably.. But I had a similar error. Reason - one .so wasn't present in 32bit version (I don't remember which one). Maybe he should run ldd on those libraries - perhaps some child library is missing.
Reply
#14
That's what i get after running
mysql --host=<address> -u <username> -p:
-bash: address: No such file or directory

I've ran ldd on every so file i could find in cstrike folder or sourcemod folder. That's told me, that i'm lack of two files:

vstdlib_i486.so => not found
tier0_i486.so => not found

But they are in srcds/bin folder. So i guess, that i need some library to install or something?

And ldd those two libs led to tier0_i486.so which is also there and isn't short of any other library.
Reply
#15
I bet you just copied and pasted the command.
You need to replace address etc. with your data...
Reply


Forum Jump:


Users browsing this thread: 1 Guest(s)