MySQL connection on a mac

Need help with SmartFoxServer? You didn't find an answer in our documentation? Please, post your questions here!

Moderators: Lapo, Bax

Post Reply
Thunder
Posts: 19
Joined: 04 May 2008, 10:12

MySQL connection on a mac

Post by Thunder »

Hi all,
I am now using a mac. I am trying to get MySQL working with SFS. I have copied mysql-connector-java-5.1.12-bin to my Library/Java/Extensions folder. Below is my config file:

Code: Select all

<DatabaseManager active="true">
	<Driver>org.gjt.mm.mysql.Driver</Driver>
	<ConnectionString>jdbc:mysql://localhost:3306/flash</ConnectionString>
	<TestSQL><![CDATA[SELECT COUNT(*) FROM player]]></TestSQL>
	<UserName>root</UserName>
	<Password>PASSWORD</Password>
	<MaxActive>100</MaxActive>
	<MaxIdle>10</MaxIdle>
	<OnExhaustedPool>fail</OnExhaustedPool>
	<BlockTime>5000</BlockTime>
</DatabaseManager>
The error I get is:
17:26:03.545 - [ SEVERE ] > DbManager could not retrive a connection. com.mysql.jdbc.exceptions.jdbc4.CommunicationsException: Communications link failure

The last packet sent successfully to the server was 0 milliseconds ago. The driver has not received any packets from the server.
it.gotoandplay.smartfoxserver.exceptions.DbManagerException: The Test SQL statement failed! Please check your configuration.
at it.gotoandplay.smartfoxserver.SmartFoxServer.setupZone(SmartFoxServer.java:1843)
at it.gotoandplay.smartfoxserver.lib.ConfigReader.parse_Zones(ConfigReader.java:806)
at it.gotoandplay.smartfoxserver.lib.ConfigReader.readZoneConfig(ConfigReader.java:174)
at it.gotoandplay.smartfoxserver.SmartFoxServer.initServerSocket(SmartFoxServer.java:339)
at it.gotoandplay.smartfoxserver.SmartFoxServer.run(SmartFoxServer.java:607)
Problems in config file: The Test SQL statement failed! Please check your configuration.
it.gotoandplay.smartfoxserver.exceptions.ConfigurationException: The Test SQL statement failed! Please check your configuration.
at it.gotoandplay.smartfoxserver.lib.ConfigReader.readZoneConfig(ConfigReader.java:199)
at it.gotoandplay.smartfoxserver.SmartFoxServer.initServerSocket(SmartFoxServer.java:339)
at it.gotoandplay.smartfoxserver.SmartFoxServer.run(SmartFoxServer.java:607)

Errors found in configuration files.
Unable to start the server.


Shutting down server...
Any ideas? I am certain my Test SQL statement is correct

Cheers all
User avatar
Lapo
Site Admin
Posts: 23438
Joined: 21 Mar 2005, 09:50
Location: Italy

Post by Lapo »

Hey there,
we had some other users reporting a similar problem and they solved it from the MySQL side.
http://forums.smartfoxserver.com/viewtopic.php?t=7380
Lapo
--
gotoAndPlay()
...addicted to flash games
Post Reply