discuz! Database Error
(2003) Notconnect
PHP Debug
No. File Line Code
1 forum.php discuz_application->init ()
2 source/class/discuz/discuz_application.php discuz_application->_init_db ()
3 source/class/discuz/discuz_application.php 399 Discuz_database::init (%s, Array)
4 source/class/discuz/discuz_database.php Db_driver_mysql->connect ()
5 source/class/db/db_driver_mysql.php Db_driver_mysql->_dbconnect (%s,%s,%s,%s,%s,%s)
6 source/class/db/db_driver_mysql.php Db_driver_mysql->halt (%s,%d)
7 source/class/db/db_driver_mysql.php 224 Break ()
solution One, also the most common problem
Install directory/config/config_global.php
Install directory/config/config_ucenter.php
installation directory/uc_server/data/config.inc.php (easy to omit)
The changes are roughly:
Define (' uc_dbhost ', ' localhost ');/generally localhost, remote database to fill in the corresponding IP
Define (' Uc_dbuser ', ' user ');//Database username
Define (' UC_DBPW ', ' password ');//Database with password
Define (' Uc_dbname ', ' database ');//DB name
Solution Two, a rare problem
Workaround:
1, stop the Web server work;
2, use the net stop MySQL command to stop MySQL work;
3, the manual package backup mysql below the data packet;
4, to the BBS or wwwroot below delete all files, that is, empty operation;
5, re-copy DZ program to perform a new installation;
6, the use of net start MySQL command to start the MySQL service work;
7, start the Web server and browse the homepage or see if there are any new problems, this time because it is a new installation so the problem opportunity for 0!
8, use the net stop MySQL command to stop the MySQL service;
9, extract the data packet and cover to the original location
10, the use of net start MySQL command to start the MySQL service work;
11, restart the Web server!