wfaleiro
asked on
Mysql database configuration for Bugzilla
Hi,
I am getting the error while running checksetup.pl for a bugzilla installation.
Checking user setup ...
Removing existing compiled templates ...
Precompiling templates ...
DBI connect(';localhost;3306', 'mysql',.. .) failed: Can't connect to local MySQL server through socket '/tmp/mysql.sock' (2) at ./checksetup.pl line 1434
Can't connect to the mysql database. Is the database installed and
up and running? Do you have the correct username and password selected in
localconfig?
The script uses a file localconfig to login the mysql database and perform some tests.
The username/password given in the config file are mysql/mysql.
But if I use mysql -u mysql -p
password:mysql
I can login the database.
How can I rectify the error.
--Walter
I am getting the error while running checksetup.pl for a bugzilla installation.
Checking user setup ...
Removing existing compiled templates ...
Precompiling templates ...
DBI connect(';localhost;3306',
Can't connect to the mysql database. Is the database installed and
up and running? Do you have the correct username and password selected in
localconfig?
The script uses a file localconfig to login the mysql database and perform some tests.
The username/password given in the config file are mysql/mysql.
But if I use mysql -u mysql -p
password:mysql
I can login the database.
How can I rectify the error.
--Walter
ASKER
the correct mysql.sock file is presend in /var/lib/mysql.
so do i use the following setting
$db_sock = '/var/lib/mysql/mysql.sock ';
--W
so do i use the following setting
$db_sock = '/var/lib/mysql/mysql.sock
--W
yes
ASKER
And yes
DBI connect(';localhost;3306', 'mysql',.. .) failed: Can't connect to local MySQL server through socket '/tmp/mysql.sock' (2) at ./checksetup.pl line 1434
Looks like there is a semicolon.
Regards,
--Walter
DBI connect(';localhost;3306',
Looks like there is a semicolon.
Regards,
--Walter
First try with the mysql.sock change and then replace the semicolon with localhost:3306 change and re-try it.
ASKER
Checking user setup ...
Removing existing compiled templates ...
Precompiling templates ...
DBI connect(';localhost;3306;m ysql_socke t=/var/lib /mysql/mys ql.sock',' mysql',... ) failed: Client does not support authentication protocol requested by server; consider upgrading MySQL client at ./checksetup.pl line 1434
Can't connect to the mysql database. Is the database installed and
up and running? Do you have the correct username and password selected in
localconfig?
Removing existing compiled templates ...
Precompiling templates ...
DBI connect(';localhost;3306;m
Can't connect to the mysql database. Is the database installed and
up and running? Do you have the correct username and password selected in
localconfig?
ASKER
And these are the settings, which I dont think need a change
#
# How to access the SQL database:
#
$db_host = "localhost"; # where is the database?
$db_port = 3306; # which port to use
$db_name = "mysql"; # name of the MySQL database
$db_user = "mysql"; # user to attach to the MySQL database
#
# How to access the SQL database:
#
$db_host = "localhost"; # where is the database?
$db_port = 3306; # which port to use
$db_name = "mysql"; # name of the MySQL database
$db_user = "mysql"; # user to attach to the MySQL database
Just leave these setting alone and just have the mysql.sock file path changed and try connecting through bugzilla
Sorry i read the error messages now. What is the version of the client & server you have looks like you might have to upgrade it.
ASKER
MySQL-shared-standard-5.0. 26-0.rhel4
MySQL-client-standard-5.0. 26-0.rhel4
MySQL-server-standard-5.0. 26-0.rhel4
MySQL-devel-standard-5.0.2 6-0.rhel4
And the database is tarred/untarred from
mysql-server-3.23.58-13
mysql-3.23.58-13
mysql-devel-3.23.58-13
mysql-bench-3.23.58-13
maybe I need to use mysqldump and restore. But the very fact that i can use mysql -u mysql -p and login to the database makes me think otherwise.
--W
MySQL-client-standard-5.0.
MySQL-server-standard-5.0.
MySQL-devel-standard-5.0.2
And the database is tarred/untarred from
mysql-server-3.23.58-13
mysql-3.23.58-13
mysql-devel-3.23.58-13
mysql-bench-3.23.58-13
maybe I need to use mysqldump and restore. But the very fact that i can use mysql -u mysql -p and login to the database makes me think otherwise.
--W
ASKER
If I try to connect via bugzilla I get the same error
DBI connect('host=localhost;da tabase=mys ql;port=33 06;mysql_s ocket=/var /lib/mysql /mysql.soc k','mysql' ,...) failed: Client doe
s not support authentication protocol requested by server; consider upgrading MySQL client at /usr/local/bugzilla/bugzil la-2
.18/lib/perl5/site_perl/5. 6.2/i686-l inux/DBI.p m line 597
DBI::__ANON__(undef, undef) called at /usr/local/bugzilla/bugzil la-2.18/li b/perl5/si te_perl/5. 6.2/i686-l inux/DBI.p m
line 648
DBI::connect('DBI', 'DBI:mysql:host=localhost; database=m ysql;port= 3306;mysql _socket=/. ..', '', '', 'HASH(0x987b6c4)'
) called at Bugzilla/DB.pm line 146
Bugzilla::DB::_connect('DB I:mysql:ho st=localho st;databas e=mysql;po rt=3306;my sql_socket =/...') called at Bugzilla/DB.
DBI connect('host=localhost;da
s not support authentication protocol requested by server; consider upgrading MySQL client at /usr/local/bugzilla/bugzil
.18/lib/perl5/site_perl/5.
DBI::__ANON__(undef, undef) called at /usr/local/bugzilla/bugzil
line 648
DBI::connect('DBI', 'DBI:mysql:host=localhost;
) called at Bugzilla/DB.pm line 146
Bugzilla::DB::_connect('DB
ASKER
think i need to upgrade the perl dbi
ASKER
or rather DBI:mysql
ASKER
Actually looking at the error
DBI connect('host=localhost;da tabase=mys ql;port=33 06;mysql_s ocket=/var /lib/mysql /mysql.soc k','mysql' ,...) failed: Client doe
s not support authentication protocol requested by server; consider upgrading MySQL client at /usr/local/bugzilla/bugzil la-2
.18/lib/perl5/site_perl/5. 6.2/i686-l inux/DBI.p m line 597
It's asking to upgrade MySQL client, at DBI.pm, what client is it referring too?
--Walter
DBI connect('host=localhost;da
s not support authentication protocol requested by server; consider upgrading MySQL client at /usr/local/bugzilla/bugzil
.18/lib/perl5/site_perl/5.
It's asking to upgrade MySQL client, at DBI.pm, what client is it referring too?
--Walter
ASKER
The checksetup.pl script is failing at
my $dbh = DBI->connect($dsn, $my_db_user, $my_db_pass)
my $dbh = DBI->connect($dsn, $my_db_user, $my_db_pass)
I am not sure about this one,
Try upgrading the perl-DBD-MySQL-2.1021-3
Does the bugs databases already exist?
From what i read from this link
http://www.softwaretesting.de/article/view/33/1/8/parent/40/
bugzilla needs to have a username "bugs" any other username doesn;t work. Look at the Bugzilla readme and see if there is a specific requirement for mysql
Try upgrading the perl-DBD-MySQL-2.1021-3
Does the bugs databases already exist?
From what i read from this link
http://www.softwaretesting.de/article/view/33/1/8/parent/40/
bugzilla needs to have a username "bugs" any other username doesn;t work. Look at the Bugzilla readme and see if there is a specific requirement for mysql
ASKER
This is the original server
rpm -qa | grep perl-DBD
perl-DBD-MySQL-2.9003-5
perl-DBD-Pg-1.31-6
rpm -qa | grep mysql
mysql-server-3.23.58-13
mysql-3.23.58-13
libdbi-dbd-mysql-0.6.5-9
mysql-devel-3.23.58-13
mod_auth_mysql-20030510-5
php-mysql-4.3.9-3
mysql-bench-3.23.58-13
And this is the new server
rpm -qa | grep MySQL
MySQL-shared-standard-5.0. 26-0.rhel4
MySQL-server-standard-5.0. 26-0.rhel4
MySQL-devel-standard-5.0.2 6-0.rhel4
MySQL-client-standard-5.0. 26-0.rhel4
rpm -qa | grep perl-DBD
#
When I try to install
yum install perl-DBD-MySQL-2.1021-3
Setting up Install Process
Setting up repositories
Reading repository metadata in from local files
Parsing package install arguments
No Match for argument: perl-DBD-MySQL-2.1021-3
Nothing to do
But this one works
Dependencies Resolved
========================== ========== ========== ========== ========== ========== =
Package Arch Version Repository Size
========================== ========== ========== ========== ========== ========== =
Installing:
perl-DBD-MySQL i386 2.9004-3.1 base 111 k
Installing for dependencies:
mysql i386 4.1.20-1.RHEL4.1 base 2.9 M
here it will instal mysql 4.1 and uninstall my current mysql which is not what i want.
any suggestions?
--W
rpm -qa | grep perl-DBD
perl-DBD-MySQL-2.9003-5
perl-DBD-Pg-1.31-6
rpm -qa | grep mysql
mysql-server-3.23.58-13
mysql-3.23.58-13
libdbi-dbd-mysql-0.6.5-9
mysql-devel-3.23.58-13
mod_auth_mysql-20030510-5
php-mysql-4.3.9-3
mysql-bench-3.23.58-13
And this is the new server
rpm -qa | grep MySQL
MySQL-shared-standard-5.0.
MySQL-server-standard-5.0.
MySQL-devel-standard-5.0.2
MySQL-client-standard-5.0.
rpm -qa | grep perl-DBD
#
When I try to install
yum install perl-DBD-MySQL-2.1021-3
Setting up Install Process
Setting up repositories
Reading repository metadata in from local files
Parsing package install arguments
No Match for argument: perl-DBD-MySQL-2.1021-3
Nothing to do
But this one works
Dependencies Resolved
==========================
Package Arch Version Repository Size
==========================
Installing:
perl-DBD-MySQL i386 2.9004-3.1 base 111 k
Installing for dependencies:
mysql i386 4.1.20-1.RHEL4.1 base 2.9 M
here it will instal mysql 4.1 and uninstall my current mysql which is not what i want.
any suggestions?
--W
ASKER
Hi,
I have done the bugzilla installation anew, loaded the DBD::myql module.
Now I need help in restoring all the database of bugs to the new installation. I have already tarred/untarre the database under /var/lib/mysql
--Walter
I have done the bugzilla installation anew, loaded the DBD::myql module.
Now I need help in restoring all the database of bugs to the new installation. I have already tarred/untarre the database under /var/lib/mysql
--Walter
how did you backup?
from what you are saying it looks like you have compressed the data directory and uncompressed it the in new server. A mysql restart would be good at this point.
That would be consistent backup only if no one was using the db/you flushed the tables & locked it. mysqldump/mysqlhotcopy would be best
from what you are saying it looks like you have compressed the data directory and uncompressed it the in new server. A mysql restart would be good at this point.
That would be consistent backup only if no one was using the db/you flushed the tables & locked it. mysqldump/mysqlhotcopy would be best
ASKER
I did a tar and untar as suggested.
# mysql -u root -p
Enter password:
Welcome to the MySQL monitor. Commands end with ; or \g.
Your MySQL connection id is 9 to server version: 5.0.26-standard
Type 'help;' or '\h' for help. Type '\c' to clear the buffer.
mysql> show databases;
+--------------------+
| Database |
+--------------------+
| bugs |
| mysql |
| test |
+--------------------+
3 rows in set (0.00 sec)
mysql> use mysql ;
Reading table information for completion of table and column names
You can turn off this feature to get a quicker startup with -A
Database changed
mysql> show tables;
+------------------------- --+
| Tables_in_mysql |
+------------------------- --+
| columns_priv |
| db |
| help_topic |
| host |
| user |
+------------------------- --+
I am stuck at reflecting the database in bugzilla. As when I search the bugzilla page for bugs, I get zero bugs found for all searches .
-Walter
# mysql -u root -p
Enter password:
Welcome to the MySQL monitor. Commands end with ; or \g.
Your MySQL connection id is 9 to server version: 5.0.26-standard
Type 'help;' or '\h' for help. Type '\c' to clear the buffer.
mysql> show databases;
+--------------------+
| Database |
+--------------------+
| bugs |
| mysql |
| test |
+--------------------+
3 rows in set (0.00 sec)
mysql> use mysql ;
Reading table information for completion of table and column names
You can turn off this feature to get a quicker startup with -A
Database changed
mysql> show tables;
+-------------------------
| Tables_in_mysql |
+-------------------------
| columns_priv |
| db |
| help_topic |
| host |
| user |
+-------------------------
I am stuck at reflecting the database in bugzilla. As when I search the bugzilla page for bugs, I get zero bugs found for all searches .
-Walter
Do this to backup & restore
on source server to backup.
mysqldump –-useruser –-password=password bugs > bugs.sql
on target/new server to restore
mysql -umysql -pmysql bugs < bugs.sql
on source server to backup.
mysqldump –-useruser –-password=password bugs > bugs.sql
on target/new server to restore
mysql -umysql -pmysql bugs < bugs.sql
ASKER
Hi,
I used
mysqldump -u root -p --all-databases > bugs.pl
Now when I try to restore it on the new server I get this option
mysql < bugs.pl
ERROR 1045 (28000): Access denied for user 'root'@'localhost' (using password: NO)
I used
mysqldump -u root -p --all-databases > bugs.pl
Now when I try to restore it on the new server I get this option
mysql < bugs.pl
ERROR 1045 (28000): Access denied for user 'root'@'localhost' (using password: NO)
mysql -uroot -ppassword bugs < bugs.pl
You do know the password for root right?
You do know the password for root right?
ASKER
Yup Thanks, I got that working. Ran ./checksetup.pl and bugzilla is displaying fine. But the users are complaining they cannot login with the username and passwords to the site. Do I need to reset the same in the mysql database?
--W
--W
ASKER CERTIFIED SOLUTION
membership
This solution is only available to members.
To access this solution, you must be a member of Experts Exchange.
Do a ps -ef | grep -i mysql
That should give you the correct mysql.sock, enter that path in the config.
Also, is that a semicolon localhost;3306 ?