954,523 Members — Technology Publication meets Social Media
Username:
Password:
Lost login information?
Have something to say? Contribute New Article Reply to this Article

DBI connect - Bad Handshake - Frustration beyond belief

All,

I have been trying to debug this problem all weekend but I haven't been able to get any closer to the solution...

I have just upgraded Mysql to 5.1 from 4.1 on a Red Hat 4 box. Everything is fine. I can connect to the database using the shell, I can connect to the database using a Perl script using DBI (also from the shell), However I cannot connect to the database using a Perl/CGI (inside Apache).

All I get is this error:

Bad handshake at line 123

That line is actually referring to the DBI->connect function.

my $dbh = DBI->connect('DBI:mysql:test:'.get_db(), 'root', '') or die $DBI::errstr;

I have scoured the internet looking for solutions, but I haven't found anything of much help. My original thought was that it was something to do with the DBD::mysql driver. But usually the mysql-shared-compat rpm takes care of that for me... Does anyone know any of the modules/packages I'd need to recompile?

Any help is greatly appreciated.

nonshatter
Posting Whiz
377 posts since Nov 2009
Reputation Points: 39
Solved Threads: 63
 

For those who may be interested,

I never found out the cause of the problem, but I uninstalled MySQL 5.1 and went back to 5.0 which sprung it into life again.

nonshatter
Posting Whiz
377 posts since Nov 2009
Reputation Points: 39
Solved Threads: 63
 

This question has already been solved

Post: Markdown Syntax: Formatting Help
You