My Blog

October 8, 2008

Encountered error when using Mysql ODBC client connects to server

Filed under: Mysql — by enotebook @ 3:50 pm

I actually got this error before while using Mysql ODBC client connects to Mysql server, however i did not note it down at once, so when i face the same problem i even don’t know how to fix it, surely it has been solved after doing some research, here i place a post as note.
Mysql ODBC driver: MySQL ODBC 3.51 Driver
Mysql Server version: MySQL Community Server 5.0.51a
Error message: Client does not support authentication protocol requested by server; consider upgrading MySQL client
MySQL 5.0 uses an authentication protocol based on a password hashing algorithm that is incompatible with that used by older (pre-4.1) clients, when using an older client to connect the server, you may get with the error message.
To solve the problem, it needs to issue a command to reset the password to pre-4.1 style for each user that needs to use a pre-4.1 client program like following:
-> [email=’some_user’@’some_host’] = OLD_PASSWORD(‘newpwd’);
Alternatively, use UPDATE and FLUSH PRIVILEGES:
mysql> UPDATE mysql.user SET Password = OLD_PASSWORD(‘newpwd’)
-> WHERE Host = ‘some_host’ AND User = ‘some_user’;


August 20, 2008

MySql installation on Linux

Filed under: Mysql — by enotebook @ 3:16 pm

Information about Host & MySql as belows:
# uname -a
Linux localhost.localdomain 2.6.9-22.ELsmp #1 SMP Mon Sep 19 18:00:54 EDT 2005 x86_64 x86_64 x86_64 GNU/Linux
# mysql -u root -p
Enter password:
Welcome to the MySQL monitor. Commands end with ; or \g.
Your MySQL connection id is 17 to server version: 5.0.51a-log
Type ‘help;’ or ‘\h’ for help. Type ‘\c’ to clear the buffer.
mysql> select version();
| version() |
| 5.0.51a-log |
1 row in set (0.00 sec)

Install Mysql using RPM
rpm -ivh rpmfile (you will encounter error like the mysql package conflicts since it has been installed when you installing OS, use rpm -e to uninstalled them and try again)
default Installation location:
1、data folder
2、configuration files
/usr/share/mysql(mysql.server etc.)
3、binary file
/usr/bin(mysqladmin mysqldump etc.)
4、booting scripts

Install Mysql using distributed file
1. create folder and grant proper permission
# mkdir -p /u01/CfgFiles
# chown -R mysql /u01/
# chgrp -R mysql /u01/

2. transfer file(mysql-5.0.51a-linux-i686.tar.gz) to linux host

3. unzip
# tar -xf mysql-5.0.51a-linux-i686.tar
# mv mysql-5.0.51a-linux-i686 MySql
# ls
app lost+found MySql mysql-5.0.51a-linux-i686.tar oradata

4. copy my-large.cnf & mysql.server to a specific location and moodify them accordingly
# cd MySql/
# cp support-files/my-large.cnf support-files/mysql.server /u01/CfgFiles/
# cd /u01/CfgFiles/
# mv my-large.cnf my.cnf
# mv mysql.server mysqld
# vi mysqld
1). specify the location path to basedir&datadir in line number 46:
46 basedir=/u01/MySql
47 datadir=/u01/MySql/data
2). specify the configuration file in line number 195:
195 #conf=/etc/my.cnf
196 conf=/u01/CfgFiles/my.cnf
# vi my.cnf
1). specify the location path for socket file in line number 20 & 28:
20 #socket = /tmp/mysql.sock
21 socket =/u01/MySql/mysql.sock
28 #socket = /tmp/mysql.sock
29 socket =/u01/MySql/mysql.sock

5. startup Mysql
# ./mysqld start
Starting MySQL [ OK ]
6. Modify password for root:
# mysqladmin -u root password ‘newpassword’

7. Enable remote login:
mysql> grant all on *.* to [email=root@’%’]root@’%’ identified by ‘password’;


Create a free website or blog at