Jump to content


Photo

Connecting to MySQL 5.0


  • Please log in to reply
1 reply to this topic

#1 kulmacet

kulmacet
  • New Members
  • Pip
  • Newbie
  • 3 posts

Posted 02 November 2005 - 04:38 AM

The following line of code connects fine to MySQL 4.0 but will not connect to MySQL 5.0 code is :
@ $db = mysql_pconnect($dbip, $dbuser, $dbpass);
when connecting to MySQL 5 get error
Warning: mysql_pconnect(): Client does not support authentication protocol requested by server; consider upgrading MySQL

Have upgraded to latest client software... Not sure what is the issue.
Any help appreciated.
Thanks in advance.
Kulmacet


#2 Zane

Zane
  • Administrators
  • Advanced Member
  • 4,134 posts

Posted 02 November 2005 - 06:39 AM

you need to get to the mysql console
through DOS or your terminal or whatever you are using

and use the OLD_PASSWORD algorithm

G:\mysql\bin>mysql -u your username -p
Enter password: your password
Welcome to the MySQL monitor.  Commands end with ; or \g.
Your MySQL connection id is 1091 to server version: 4.1.14-nt

Type 'help;' or '\h' for help. Type '\c' to clear the buffer.

mysql> SET PASSWORD FOR 'your username'@'localhost' = OLD_PASSWORD('your pasword');
//If your doing it for a remote user use their IP or domain name for the localhost part
Query OK, 0 rows affected (0.03 sec)


btn_donate_SM.gif Want to thank me? Contribute to my PayPal piggy-bank
 

172938.png




0 user(s) are reading this topic

0 members, 0 guests, 0 anonymous users