RES: [rt-users] RT2 and DBI problems

Presciliano dos Santos Neto psneto at telepar.com.br
Thu Nov 29 12:37:15 EST 2001


I found this message at http://groups.yahoo.com/group/modperl/message/17512.
Does the "DBI pragma" aplies to my problem ? How to use it ?

Thanks,

Presciliano

From:  Geoffrey Young <gyoung at l...>
Date:  Thu Jan 6, 2000  2:50 pm
Subject:  RE: problem with Apache::DBI

Apache::DBI and DBI are different packages - Apache::DBI requires DBI to
function.

thus, you still need to include the use DBI pragma.

HTH

--Geoff

> -----Original Message-----
> From: Michael Baxter [mailto:fineprint at w...]
> Sent: Thursday, January 06, 2000 4:17 AM
> To: modperl at a...
> Subject: problem with Apache::DBI
> 
> 
> I've posted this to comp.lang.perl.modules but got no 
> response. Perhaps
> you can help.
> 
> I've been accessing a mysql db with (non-mod)perl/cgi. I've installed
> mod_perl as per the eagle book (right down to the suggested directory
> layout) and have run examples 2.1 and 2.3, so I'm
> assuming Apache::Registry works. But when I try to run one of my old
> scripts (with the use DBI commented out) all I get is an error msg:
> 
> [Sun Jan  2 16:29:41 2000] [error] [Sun Jan  2 16:29:41 2000] null:
> Can't locate object method "connect" via package "Apache::DBI" at
> /usr/lib/perl5/site_perl/DBI.pm line 382. The file is there.
> 
> I'm running redhat 5.2, mysql 2.22.26a, apache 1.3.9 and 
> mod_perl 1.21.
> 
> Any suggestions - I've run out of ideas and curses.
>          Thanks,
>              MickB.
> 


> ----- Mensagem original -----
> De:		Presciliano dos Santos Neto 
> Enviada em:		Quinta-feira, 29 de Novembro de 2001 09:19
> Para:		'rt-users at lists.fsck.com'
> Assunto:		RES: [rt-users] RT2 and DBI problems
> 
> Ops ! CPAN installed perl 5.6.1 to me, but I have used perl5.6.0. When
> installing RT, I've changed the PERL line:
> 
> PERL=/usr/bin/perl5.6.0
> 
> [root at pinguim rt-2-0-9]# make testdeps
> /usr/bin/perl5.6.0 ./tools/testdeps -warn mysql
> Checking for DBI 1.18 ...found
> Checking for DBIx::DataSource 0.02 ...found
> Checking for DBIx::SearchBuilder 0.47 ...found
> Checking for HTML::Entities...found
> Checking for MLDBM...found
> Checking for Net::Domain...found
> Checking for Net::SMTP...found
> Checking for Params::Validate 0.02 ...found
> Checking for HTML::Mason 0.896 ...found
> Checking for CGI::Cookie 1.20 ...found
> Checking for Apache::Cookie...found
> Checking for Apache::Session 1.53 ...found
> Checking for Date::Parse...found
> Checking for Date::Format...found
> Checking for MIME::Entity 5.108 ...found
> Checking for Mail::Mailer 1.20 ...found
> Checking for Getopt::Long 2.24 ...found
> Checking for Tie::IxHash...found
> Checking for Text::Wrapper...found
> Checking for Text::Template...found
> Checking for File::Spec 0.8 ...found
> Checking for Errno...found
> Checking for FreezeThaw...found
> Checking for File::Temp...found
> Checking for Log::Dispatch 1.6 ...found
> Checking for DBD::mysql 2.0416 ...found
> 
> [root at pinguim bin]# perl -v
> This is perl, v5.6.1 built for i686-linux
> 
> [root at pinguim bin]# pwd
> /usr/bin
> 
> [root at pinguim bin]# cp perl5.6.0 perl
> 
> [root at pinguim bin]# perl -v
> This is perl, v5.6.0 built for i386-linux
> 
> [root at pinguim rt-2-0-9]# /usr/local/apache/bin/apachectl restart
> /usr/local/apache/bin/apachectl restart: httpd restarted
> 
> Tried to load RT2 page ... the error in apache error_log is the same:
> 
> [root at pinguim rt-2-0-9]# tail /usr/local/apache/logs/error_log 
> [Thu Nov 29 07:10:38 2001] [notice] Apache/1.3.20 (Unix) PHP/4.0.6
> mod_perl/1.26 configured -- resuming normal operations
> [Thu Nov 29 07:11:18 2001] [error] Can't locate object method "connect"
> via
> package "Apache::DBI::connect" at
> /usr/lib/perl5/site_perl/5.6.0/i386-linux/DBI.pm line 420.
> [Thu Nov 29 07:11:37 2001] [error] Can't locate object method "connect"
> via
> package "Apache::DBI::connect" at
> /usr/lib/perl5/site_perl/5.6.0/i386-linux/DBI.pm line 420.
> [Thu Nov 29 07:11:39 2001] [error] Can't locate object method "connect"
> via
> package "Apache::DBI::connect" at
> /usr/lib/perl5/site_perl/5.6.0/i386-linux/DBI.pm line 420.
> 
> Presciliano
> 
> 
> > ----- Mensagem original -----
> > De:		Jesse Vincent [SMTP:jesse at bestpractical.com]
> > Enviada em:		Quarta-feira, 28 de Novembro de 2001 19:54
> > Para:		Presciliano dos Santos Neto
> > Cc:		'rt-users at lists.fsck.com'
> > Assunto:		Re: [rt-users] RT2 and DBI problems
> > 
> > what does perl -v tell you?
> > 
> > 
> > On Wed, Nov 28, 2001 at 07:38:02PM -0200, Presciliano dos Santos Neto
> > wrote:
> > > Hello !
> > > 
> > > I have installed RT2, checked all the documentation but I can't
> resolve
> > an
> > > issue with DBI. I think the following lines describes the problem
> better
> > > than my poor english :-)
> > > I know DBI and Apache::DBI are diferent modules, and I think somebody
> is
> > > calling the wrong one. Any help ?
> > > 
> > > Thanks in advance,
> > > 
> > > Presciliano
> > > 
> > > ------ I've installed all the RT2 dependencies with CPAN, and
> > Apache::DBI
> > > again by hand ...
> > > 
> > > cpan> install DBI
> > > DBI is up to date.
> > > 
> > > cpan> install Apache::DBI
> > > Apache::DBI is up to date.
> > > 
> > > cpan> exit
> > > Lockfile removed.
> > > 
> > > ------- http.conf
> > > ...
> > > <VirtualHost *>
> > >     DocumentRoot /usr/local/rt2/WebRT/html
> > >     ServerName security.telepar.net.br
> > >     PerlModule Apache::DBI
> > >     PerlFreshRestart On
> > >     PerlRequire /usr/local/rt2/bin/webmux.pl
> > >     <Location />
> > >         SetHandler perl-script
> > >         PerlHandler RT::Mason
> > >     </Location>
> > > </VirtualHost>
> > > ...
> > > 
> > > ------ httpd loads fine
> > > 
> > > [root at pinguim /root]# /usr/local/apache/bin/apachectl restart
> > > /usr/local/apache/bin/apachectl restart: httpd restarted
> > > 
> > > ------ Tried to load RT2 page in a browser. Received the Internal
> Server
> > 500
> > > error
> > > 
> > > [root at pinguim /root]# tail /usr/local/apache/logs/error_log 
> > > [Wed Nov 28 17:08:42 2001] [notice] SIGHUP received.  Attempting to
> > restart
> > > [Wed Nov 28 17:08:42 2001] [notice] Apache/1.3.20 (Unix) PHP/4.0.6
> > > mod_perl/1.26 configured -- resuming normal operations
> > > [Wed Nov 28 17:08:56 2001] [error] Can't locate object method
> "connect"
> > via
> > > package "Apache::DBI::connect" at
> > > /usr/lib/perl5/site_perl/5.6.0/i386-linux/DBI.pm line 420.
> > > 
> > > [root at pinguim /root]# find / -name DBI.pm
> > > /usr/lib/perl5/site_perl/5.6.0/i386-linux/Bundle/DBI.pm
> > > /usr/lib/perl5/site_perl/5.6.0/i386-linux/DBI.pm
> > > /usr/lib/perl5/site_perl/5.6.0/Apache/Session/Store/DBI.pm
> > > /usr/lib/perl5/site_perl/5.6.0/Apache/DBI.pm
> > > 
> > > _______________________________________________
> > > rt-users mailing list
> > > rt-users at lists.fsck.com
> > > http://lists.fsck.com/mailman/listinfo/rt-users
> > > 
> > 
> > -- 
> > http://www.bestpractical.com/products/rt  -- Trouble Ticketing. Free.
> 
> _______________________________________________
> rt-users mailing list
> rt-users at lists.fsck.com
> http://lists.fsck.com/mailman/listinfo/rt-users




More information about the rt-users mailing list