In our support boards we aim to provide support for the B3 core in its current state. Older releases of B3 are NOT supported. Check our front page for the latest version. You may post feature requests in our General Discussion board. Modifications and Hacks of the core B3 code are NOT supported.
Before you ask for support: [ Read the Support Instructions ] - More info: [ Full Support Disclaimer ]

You are here: Big Brother Bot ForumSupport ForumsInstallation Support (Moderator: MordyT)Can't connect to Database
Pages: [1]   Go Down
  Print  
Author Topic: Can't connect to Database  (Read 771 times) Bookmark and Share
Newbie
*
OS: --No B3 installed--
Type: --No B3 installed--
Posts: 6
Offline Offline
« on: January 23, 2011, 11:54:07 PM »

Hello,

I've a little problem setting up b3. i have an old computer where i decided to run a cod 4 server on. i did and it works perfectly. now i want to install b3 on it. the problem is, ive now already been working on it 2 days and i still can't connect to my database.
here is the log file:
Quote
020103 01:28:06   BOT       www.bigbrotherbot.net (b3) v1.4.1 [nt] (Daniel) [Win32 standalone]
020103 01:28:06   BOT       Python: 2.6.1 (r261:67517, Dec  4 2008, 16:51:00) [MSC v.1500 32 bit (Intel)]
020103 01:28:06   BOT       Starting Cod4Parser v1.3.2 for server 127.0.0.1:28960
020103 01:28:06   BOT       --------------------------------------------
020103 01:28:06   BOT       Attempting to connect to database mysql://b3_user:******@127.0.0.1/b3_db...
020103 01:28:07   ERROR   Database connection failed, working in remote mode: (2003, "Can't connect to MySQL server on '127.0.0.1' (10061)") - [('b3\\storage.pyo', 207, 'connect', None), ('b3\\storage.pyo', 161, 'getConnection', None), ('MySQLdb\\__init__.pyo', 81, 'Connect', None), ('MySQLdb\\connections.pyo', 188, '__init__', None)]
020103 01:28:07   BOT       Game log games_mp.log
020103 01:28:07   BOT       Starting bot reading file games_mp.log
020103 01:28:07   ERROR   Error reading file games_mp.log

i use this to connect to my mysql database:
Quote
mysql://b3:userpass@localhost/b3
later i tried:
Quote
mysql://b3:userpass@localhost:3306/b3
but that doesn't work either.

the database is called "b3", the user is called "b3" and the password is "userpass". i run the mysql database via WAMPServer wich i never used before, and i set up the database via PHPMyAdmin. i really don't know what to do with this now. if anyone can help me? thank you.

BeMacized
Logged

Beta Testers
*
OS: Windows
Type: Owner dedicated server(s)
Gameservers: CoD W@W, COD BO, MOH
Posts: 92
Offline Offline
WWW
« Reply #1 on: January 24, 2011, 01:09:00 AM »

First thing I would suggest is make sure you have gave the user you made (b3) privileges to the database u made (b3) in PhP admin,if it doesnt have read/write privileges it wont connect, also make sure all the details are correct.
Another thing is make sure you have the correct games_mp.log path as that seems to be incorrect as well (bottom line of the piece of log u posted) as this will cause the bot not to work after you have the database sorted out. 
Logged

Newbie
*
OS: --No B3 installed--
Type: --No B3 installed--
Posts: 6
Offline Offline
« Reply #2 on: January 24, 2011, 02:50:37 AM »

yes i already fixed the games_mp.log problem. in PHPMyAdmin i also gave the user permission to everything. there shouldn't be a problem. how do i fix this?
Logged
[ www.xlrstats.com ]
Project Lead
*
OS: Linux
Type: Owner dedicated server(s)
Gameservers: CoD, CoD2, CoD5, UrT
Posts: 2022
Offline Offline
WWW
Support Specialty: B3-Core, CoD/UrT/WoP/ETPro parsers, Plugin development
« Reply #3 on: January 24, 2011, 03:26:00 AM »

This seems to be a mysql error. Here's a good starting point to identity your problem and hopefully fix it:
http://dev.mysql.com/doc/refman/5.5/en/can-not-connect-to-server.html
Logged

Newbie
*
OS: --No B3 installed--
Type: --No B3 installed--
Posts: 6
Offline Offline
« Reply #4 on: January 24, 2011, 05:02:44 AM »

thank you for the link. i will try to solve it now. hope it works.
Logged
Newbie
*
OS: --No B3 installed--
Type: --No B3 installed--
Posts: 6
Offline Offline
« Reply #5 on: January 24, 2011, 05:24:27 AM »

ok i've found the problem, but stil don't know what to do with it. the problem is:
Quote
The error (2003) Can't connect to MySQL server on 'server' (10061) indicates that the network connection has been refused. You should check that there is a MySQL server running, that it has network connections enabled, and that the network port you specified is the one configured on the server.

Start by checking whether there is a process named mysqld running on your server host. (Use ps xa | grep mysqld on Unix or the Task Manager on Windows.).

there is no process called mysqld running on my system while wampserver IS running. so i go to the part where it sais:
Quote
If there is no such process, you should start the server. See Section 2.10.1.3, “Starting and Troubleshooting the MySQL Server”.

so i start the server by putting the command
Quote
mysqld
into the command prompt, (windows). it first didn't work and i got a bunch of errors, but then i figured out i had to run the command prompt as administrator. when i now started mysqld, it showed up in the process list, but then it quit again after like 3 seconds. no errors in the command prompt. how do i sove this when it doesn't give me any error?

EDIT:
now ive got it running. it was a system process not a user process. im going to look further for the problem in that url

EDIT2:
ok got another log file now from b3. now it says acces denied instead of the other error:
Quote
020103 18:25:11   BOT       www.bigbrotherbot.net (b3) v1.4.1 [nt] (Daniel) [Win32 standalone]
020103 18:25:11   BOT       Python: 2.6.1 (r261:67517, Dec  4 2008, 16:51:00) [MSC v.1500 32 bit (Intel)]
020103 18:25:11   BOT       Starting Cod4Parser v1.3.2 for server 127.0.0.1:28960
020103 18:25:11   BOT       --------------------------------------------
020103 18:25:11   BOT       Attempting to connect to database mysql://b3:******@localhost/b3...
020103 18:25:11   ERROR   Database connection failed, working in remote mode: (1045, "Access denied for user 'b3'@'localhost' (using password: NO)") - [('b3\\storage.pyo', 207, 'connect', None), ('b3\\storage.pyo', 161, 'getConnection', None), ('MySQLdb\\__init__.pyo', 81, 'Connect', None), ('MySQLdb\\connections.pyo', 188, '__init__', None)]
020103 18:25:11   BOT       Game log C:/games_mp.log
020103 18:25:11   BOT       Starting bot reading file C:\games_mp.log
020103 18:25:11   VERBOSE   RCON sending (127.0.0.1:28960) status
020103 18:25:12   BOT       Loading Plugins (external plugin directory: C:\b3\extplugins)
020103 18:25:12   BOT       Loading Plugin #1 spamcontrol [@conf\plugin_spamcontrol.xml]
020103 18:25:12   BOT       SpamcontrolPlugin: Loading config @conf\plugin_spamcontrol.xml for SpamcontrolPlugin
020103 18:25:12   DEBUG   Register Event: Stop Process: SpamcontrolPlugin
020103 18:25:12   DEBUG   Register Event: Program Exit: SpamcontrolPlugin
020103 18:25:12   BOT       Plugin spamcontrol (1.1.2 - ThorN) loaded
020103 18:25:12   BOT       Loading Plugin #2 admin [@conf\plugin_admin.xml]
020103 18:25:12   BOT       AdminPlugin: Loading config @conf\plugin_admin.xml for AdminPlugin
020103 18:25:12   DEBUG   Register Event: Stop Process: AdminPlugin
020103 18:25:12   DEBUG   Register Event: Program Exit: AdminPlugin
020103 18:25:12   BOT       Plugin admin (1.8.2 - ThorN, xlr8or, Courgette) loaded
020103 18:25:12   BOT       Loading Plugin #3 tk [@conf\plugin_tk.xml]
020103 18:25:12   BOT       TkPlugin: Loading config @conf\plugin_tk.xml for TkPlugin
020103 18:25:12   DEBUG   TkPlugin: tk max level is 40
020103 18:25:12   DEBUG   TkPlugin: Send messages privately ? True
020103 18:25:12   DEBUG   Register Event: Stop Process: TkPlugin
020103 18:25:12   DEBUG   Register Event: Program Exit: TkPlugin
020103 18:25:12   BOT       Plugin tk (1.2.4 - ThorN) loaded
020103 18:25:12   BOT       Loading Plugin #4 stats [@conf\plugin_stats.xml]
020103 18:25:12   BOT       StatsPlugin: Loading config @conf\plugin_stats.xml for StatsPlugin
020103 18:25:12   DEBUG   StatsPlugin: Using default value (0) for commands::mapstats
020103 18:25:12   DEBUG   StatsPlugin: Using default value (0) for commands::testscore
020103 18:25:12   DEBUG   StatsPlugin: Using default value (2) for commands::topstats
020103 18:25:12   DEBUG   Register Event: Stop Process: StatsPlugin
020103 18:25:12   DEBUG   Register Event: Program Exit: StatsPlugin
020103 18:25:12   BOT       Plugin stats (1.3.4 - ThorN, GrosBedo) loaded
020103 18:25:12   BOT       Loading Plugin #5 pingwatch [@conf\plugin_pingwatch.xml]
020103 18:25:12   BOT       PingwatchPlugin: Loading config @conf\plugin_pingwatch.xml for PingwatchPlugin
020103 18:25:12   VERBOSE   Added crontab <bound method PingwatchPlugin.check of <b3.plugins.pingwatch.PingwatchPlugin instance at 0x01E3A788>> (31711600) - [0, 30]s -1m -1h -1d -1M -1DOW
020103 18:25:12   DEBUG   AdminPlugin: Command "ci (None)" registered with cmd_ci for level (20, 100)
020103 18:25:12   DEBUG   Register Event: Stop Process: PingwatchPlugin
020103 18:25:12   DEBUG   Register Event: Program Exit: PingwatchPlugin
020103 18:25:12   BOT       Plugin pingwatch (1.2.2 - ThorN) loaded
020103 18:25:12   BOT       Loading Plugin #6 adv [@conf\plugin_adv.xml]
020103 18:25:12   BOT       AdvPlugin: Loading config @conf\plugin_adv.xml for AdvPlugin
020103 18:25:12   INFO   AdvPlugin: adv rate is 2
020103 18:25:12   VERBOSE   AdvPlugin: self._feedmaxitems: 4
020103 18:25:12   DEBUG   AdvPlugin: 2 -> (*/2,0)
020103 18:25:12   VERBOSE   Added crontab <bound method AdvPlugin.adv of <b3.plugins.adv.AdvPlugin instance at 0x01E3AAD0>> (32251056) - 0s [0, 2, 4, 6, 8, 10, 12, 14, 16, 18, 20, 22, 24, 26, 28, 30, 32, 34, 36, 38, 40, 42, 44, 46, 48, 50, 52, 54, 56, 58]m -1h -1d -1M -1DOW
020103 18:25:12   DEBUG   Register Event: Stop Process: AdvPlugin
020103 18:25:12   DEBUG   Register Event: Program Exit: AdvPlugin
020103 18:25:12   BOT       Plugin adv (1.2.2 - ThorN) loaded
020103 18:25:12   BOT       Loading Plugin #7 status [@conf\plugin_status.xml]
020103 18:25:12   BOT       StatusPlugin: Loading config @conf\plugin_status.xml for StatusPlugin
020103 18:25:12   VERBOSE   Added crontab <bound method StatusPlugin.update of <b3.plugins.status.StatusPlugin instance at 0x01EC0468>> (39882608) -
  • s -1m -1h -1d -1M -1DOW
020103 18:25:12   DEBUG   Register Event: Stop Process: StatusPlugin
020103 18:25:12   DEBUG   Register Event: Program Exit: StatusPlugin
020103 18:25:12   BOT       Plugin status (1.4.3 - ThorN) loaded
020103 18:25:12   BOT       Loading Plugin #8 welcome [@conf\plugin_welcome.xml]
020103 18:25:12   BOT       WelcomePlugin: Loading config @conf\plugin_welcome.xml for WelcomePlugin
020103 18:25:12   DEBUG   AdminPlugin: Command "greeting (None)" registered with cmd_greeting for level (20, 100)
020103 18:25:12   INFO   WelcomePlugin: delay set to 30. The bot will wait 30s after a player connects to write the welcome message
020103 18:25:12   INFO   WelcomePlugin: min_gap set to 3600. The bot will not welcome a player more than once every 3600 seconds
020103 18:25:12   DEBUG   Register Event: Stop Process: WelcomePlugin
020103 18:25:12   DEBUG   Register Event: Program Exit: WelcomePlugin
020103 18:25:12   BOT       Plugin welcome (1.1 - ThorN) loaded
020103 18:25:12   BOT       Loading Plugin publist
020103 18:25:12   BOT       PublistPlugin: No config file found for PublistPlugin. (was not required either)
020103 18:25:12   DEBUG   Register Event: Stop Process: PublistPlugin
020103 18:25:12   DEBUG   Register Event: Program Exit: PublistPlugin
020103 18:25:12   BOT       Plugin publist (1.8 - ThorN, Courgette) loaded
020103 18:25:12   VERBOSE   0 cid changed from None to -1
020103 18:25:12   DEBUG   Client Connected: [-1] World - WORLD ({})
020103 18:25:12   DEBUG   Storage: getClient <b3.clients.Client object at 0x02611870>
020103 18:25:12   BOT       Attempting to connect to database mysql://b3:******@localhost/b3...
020103 18:25:12   DEBUG   User not found WORLD: 'No client matching guid WORLD in admins_cache'
020103 18:25:12   BOT       Client not found in the storage WORLD, create new
020103 18:25:12   DEBUG   Storage: setClient <b3.clients.Client object at 0x02611870>
020103 18:25:12   DEBUG   Storage: setClient data {'time_add': 1010078712, 'time_edit': 1010078712, 'name': 'World', 'group_bits': 0, 'ip': '', 'greeting': '', 'auto_login': 1, 'connections': 1, 'mask_level': 0, 'guid': 'WORLD', 'pbid': 'WORLD'}
020103 18:25:12   BOT       Attempting to connect to database mysql://b3:******@localhost/b3...
020103 18:25:12   DEBUG   Client Authorized: [-1] World - WORLD
020103 18:25:12   VERBOSE   RCON sending (127.0.0.1:28960) status
020103 18:25:13   INFO   map is: mp_backlot
020103 18:25:13   DEBUG   Forcing server cvar g_logsync to 1
020103 18:25:13   VERBOSE   RCON sending (127.0.0.1:28960) say ^0(^2b3^0)^7: ^8www.bigbrotherbot.net ^0(^8b3^0) ^9v1.4.1 [nt] ^9(^3Daniel^9)^3 ^2[ONLINE]
020103 18:25:14   VERBOSE   RCON sending (127.0.0.1:28960) set g_logsync 1
020103 18:25:15   VERBOSE   RCON sending (127.0.0.1:28960) fs_game
020103 18:25:16   DEBUG   Get cvar fs_game = ["fs_game" is: "^7" default: "^7"
  Domain is any text]
020103 18:25:16   VERBOSE   RCON sending (127.0.0.1:28960) fs_basepath
020103 18:25:16   DEBUG   Get cvar fs_basepath = ["fs_basepath" is: "C:\Program Files\Activision\Call of Duty 4 - Modern Warfare^7" default: "C:\Program Files\Activision\Call of Duty 4 - Modern Warfare^7"
  Domain is any text]
020103 18:25:16   DEBUG   fs_basepath: C:\Program Files\Activision\Call of Duty 4 - Modern Warfare
020103 18:25:16   VERBOSE   RCON sending (127.0.0.1:28960) fs_homepath
« Last Edit: January 24, 2011, 05:29:08 AM by BeMacized » Logged
Newbie
*
OS: --No B3 installed--
Type: --No B3 installed--
Posts: 6
Offline Offline
« Reply #6 on: January 24, 2011, 06:22:04 AM »

Thank you all! it worked. i deleted the database and user and remade them. i made a new db and user nd edited the user with the right rights. ty!
Logged
Tags: mysql  database  can't  connect. 
Pages: [1]   Go Up
  Print  
 
Jump to:  


Rate this page +1 at Google Search


SimplePortal 2.3.1 © 2008-2009, SimplePortal