Not logged in. · Lost password · Register
Forum: Support Installation, update and import RSS
UNB Error: Cannot connect to database. Check the error log for details.
install trouble
otto #1
Member since May 2006 · 2 posts
Group memberships: Members
Show profile · Link to this post
Subject: UNB Error: Cannot connect to database. Check the error log for details.
on a brand new installation i have got as far as going to install.php , but when i try to carry on further i get this message:

UNB Error: Cannot connect to database. Check the error log for details.



the error log says:

11.05.2006 17:40:21 - User   - /forum/install.php - (my ip address is here)
Cannot connect to database: Can't connect to local MySQL server through socket '/var/lib/mysql/mysql.sock' (2)
Backtrace:
  • forum/unb_lib/database.lib.php : 123 : UnbErrorLog("Cannot connect to database: Can't conne…")
  • forum/unb_lib/common.lib.php : 383 : IDatabase->Open()
  • public_html/forum/install.php : 72 : require_once("/websites/LinuxPackage02/fi/er/yi/fiery…")



i created the database and have checked that it is there ok

i think i filled in the install.php fields correctly

any idea what is wrong?
Avatar
Yves (Administrator) #2
User title: UNB developer & webmaster
Member since Jan 2004 · 3814 posts · Location: Erlangen, Germany
Group memberships: Administrators, Members
Show profile · Link to this post
The default socket is obviously wrong. Ask your system administrator to fix that. Meanwhile, you should enter "127.0.0.1" as your database host instead of "localhost", which works around the MySQL client library to override "localhost" with that wrong default socket.
♪ ...nanananah, all in all we’re just brilliant thieves, nanananah... ♪♬
otto #3
Member since May 2006 · 2 posts
Group memberships: Members
Show profile · Link to this post
thankyou for your reply.

i had to phone the admin people to find out what was going on and it turns out that the database is on a different server to the site - confusing  :huh:

i had to get them to tell me the actual name of the database server as it was different to the ip address or the 127.0.0.1

think i have got it installled properly now ~ i'm going to play around now and see how it all works.

thanks,

otto. :-D
Zwegat #4
Member since Sep 2009 · 3 posts
Group memberships: Members
Show profile · Link to this post
Hallo!

Dieser Beitrag ist zwar schon ein bisschen älter, aber ich habe nach einem Versionwechsel (Jaunty - Karmic) ebenfalls diese Fehlermeldung.

Die Logs sagen:

02.03.2010 10:38:13 - User   - /forum/forum.php - IP-Adresse
Cannot connect to database: Can't connect to local MySQL server through socket '/var/run/mysqld/mysqld.sock' (2)
Backtrace:
  • forum/unb_lib/database.lib.php : 128 : UnbErrorLog("Cannot connect to database: Can't conne…")
  • forum/unb_lib/common.lib.php : 397 : IDatabase->Open()
  • www/forum/forum.php : 98 : require_once("/var/www/forum/unb_lib/common.lib.php")

Ich habe mal in der Board.conf.php mal localhost in 127.0.0.1 geändert und dann sagt die Logdatei folgendes:

02.03.2010 10:08:33 - User   - /forum/forum.php - IP-Adresse
Cannot connect to database: Lost connection to MySQL server at 'reading initial communication packet', system error: 111
Backtrace:
  • forum/unb_lib/database.lib.php : 128 : UnbErrorLog("Cannot connect to database: Lost connec…")
  • forum/unb_lib/common.lib.php : 397 : IDatabase->Open()
  • www/forum/forum.php : 98 : require_once("/var/www/forum/unb_lib/common.lib.php")

Irgendwie komme ich nicht weiter ...

Vielleicht ein kleiner Tip, wo ich da noch etwas anpassen muss?

Vielen Dank!
Close Smaller – Larger + Reply to this post:
Verification code: VeriCode Please enter the word from the image into the text field below. (Type the letters only, lower case is okay.)
Smileys: :-) ;-) :-D :-p :blush: :cool: :rolleyes: :huh: :-/ <_< :-( :'( :#: :scared: 8-( :nuts: :-O
Special characters:
Go to forum
This board is powered by the Unclassified NewsBoard software, 20110527-dev, © 2003-2011 by Yves Goergen
Page created in 192.2 ms (101.8 ms) · 56 database queries in 135.9 ms
Current time: 2012-02-07, 20:45:22 (UTC +01:00)