help: db connection refused!

Post here your questions about SFS2X. Here we discuss all server-side matters. For client API questions see the dedicated forums.

Moderators: Lapo, Bax

User avatar
mhdside
Posts: 236
Joined: 04 May 2008, 07:57
Location: Egypt
Contact:

help: db connection refused!

Postby mhdside » 03 Apr 2012, 00:36

I`m facing a strange connection refused message as show below although I`m sure I`m providing all the information successfully in the zone config as below:

Code: Select all

<databaseManager active="true">
    <driverName>com.microsoft.sqlserver.jdbc.SQLServerDriver</driverName>
    <connectionString>jdbc:sqlserver://localhost:1433;DatabaseName=GameDB</connectionString>
   <userName>sa</userName>
    <password>qwe</password>
    <testSql>SELECT COUNT(*) FROM Player</testSql>
    <maxActiveConnections>10</maxActiveConnections>
    <maxIdleConnections>10</maxIdleConnections>
    <exhaustedPoolAction>FAIL</exhaustedPoolAction>
    <blockTime>3000</blockTime>
  </databaseManager>


the error I get when I run the server:
Image

I`m using windows7 64bit, sfs2x final latest version.

Please advice what can I try so my sqlserver allows the connection.

regards,
Mahmoud Badri
Senior actionscript developer
http://www.el3ab.com
User avatar
Lapo
Site Admin
Posts: 23027
Joined: 21 Mar 2005, 09:50
Location: Italy

Re: help: db connection refused!

Postby Lapo » 03 Apr 2012, 10:26

You should make sure that the database server is configured to receive connections from the client or, since it runs on the localhost, check that the local firewall is not blocking communication.
Lapo
--
gotoAndPlay()
...addicted to flash games
User avatar
mhdside
Posts: 236
Joined: 04 May 2008, 07:57
Location: Egypt
Contact:

Re: help: db connection refused!

Postby mhdside » 03 Apr 2012, 12:29

Lapo wrote:You should make sure that the database server is configured to receive connections from the client or, since it runs on the localhost, check that the local firewall is not blocking communication.


can you tell me steps to try? I`m not a good system guy. ie: how to know if the local firewall is blocking communication?
Mahmoud Badri

Senior actionscript developer

http://www.el3ab.com
User avatar
Lapo
Site Admin
Posts: 23027
Joined: 21 Mar 2005, 09:50
Location: Italy

Re: help: db connection refused!

Postby Lapo » 03 Apr 2012, 12:59

I am sorry I never worked with SQLServer, I think you should check the docs provided by Microsoft.
Anyways before that I would suggest a simple test, try disabling the Windows firewall and see if it helps, if so you will need to configure it so that it allows TCP traffic on the SQLServer port (which is the one specified in the error message)

I don't have a Windows pc at hand right now but turning off the firewall is pretty easy, just start from the Control Panel > Firewall.
Lapo

--

gotoAndPlay()

...addicted to flash games

Return to “SFS2X Questions”

Who is online

Users browsing this forum: Google [Bot] and 93 guests