jeanluca has asked for the wisdom of the Perl Monks concerning the following question:

Dear Monks

I would like to have some advice on the following issue:
I have this server running MySQL 4.0.X. This mysql server is only used locally for our CMS (php stuff). However my perl-scripts connect to a remote MySQL server (4.1.X). This is what I get when I try to connect:
~/tmp $ ./mtest.pl DBI connect('database=my_db:host=sname.domain.com:port=3306','my_usr', +...) failed: Client does not support authentication protocol requested by server; consider upgrading MySQL client at ./mtest.pl line 5 Can't call method "disconnect" on an undefined value at ./mtest.pl lin +e 7.
I upgraded DBI and DBD::mysql but that didn't change anything.
Should I install a more recent MySQL client ? (Note this is a production envirnoment and I don't wanna break the CMS)

Any suggestions ?

Thnx a lot
LuCa

Replies are listed 'Best First'.
Re: Connection problem with MySQL( Client does not support auth...)
by Joost (Canon) on Jun 19, 2007 at 21:40 UTC
      is that library not also used by php ?

      LuCa
Re: Connection problem with MySQL( Client does not support auth...)
by graff (Chancellor) on Jun 20, 2007 at 01:56 UTC
    Should I install a more recent MySQL client ?

    Yes. In fact, I would upgrade to the latest stable version of Mysql client (5.something these days). --update: Then, after that's in place, reinstall DBD::mysql, of course.

    I'm actually a little surprised that you are running into this problem with a v4.1 mysql server. MySQL changed their (default) password encryption method as of 5.0, and that error message is the one I got whenever I happened to try connecting from a machine with a 4.x client library.