List:MySQL and Perl« Previous MessageNext Message »
From:Michael Widenius Date:June 5 1999 1:43pm
Subject:Perl Module error
View as plain text  
>>>>> "John" == John Walker <john@stripped> writes:

John> I apologize if this is a FAQ, but I can't seem to quite track down
John> exactly what I'm missing. (I am somewhat confused by the whole DBD::DBI
John> thing.)

John> I am having problems executing a select from an html form. Here is the
John> error from the web server:

John>  DBI::install_driver('DBI', 'mysql') called at
John> /usr/lib/perl5/site_perl/ line 329
John>         DBI::connect('DBI', 'DBI:mysql:john', 'jsw', undef) called at
John> /home/httpd/cgi-bin/mhdir.cgi line 37
John> install_driver(mysql) failed: Can't load
John> '/usr/lib/perl5/site_perl/i386-linux/auto/DBD/mysql/' for module
John> DBD::mysql: cannot open shared object file: No such file or
John> directory at /usr/lib/perl5/i386-linux/5.00405/ line
John> 169.       

John> Here's why I don't understand the error:

John> [root@sql cgi-bin]# rpm -qa |grep My
John> MySQL-client-3.22.21-1
John> MySQL-devel-3.22.21-1
John> MySQL-3.22.21-1
John> Msql-Mysql-DBI-perl-bin-1.1823-1             

John> Here's some other random information, in the hopes that it will help
John> someone to point me in the right direction.


From the MySQL manual:

If Perl reports that it can't find the `../mysql/' module, then
the problem is probably that Perl can't locate the shared library

You can fix this by any of the following methods:

   * Compile the `Msql-Mysql-modules' distribution with `perl
     Makefile.PL -static' rather than `perl Makefile.PL'

   * Copy `' to the directory where your other shared
     libraries are located (probably `/usr/lib' or `/lib').

   * On `Linux' you can add the pathname of the directory where
     `' is located to the `/etc/' file.

   * Add the pathname of the directory where `' is
     located to the `LD_RUN_PATH' environment variable.



Perl Module errorJohn Walker4 Jun
  • Perl Module errorMichael Widenius5 Jun