Re: MySQL and Perl DBI Persistent Connection
On Fri, 16 Jan 2004 17:54:06 -0500 Syed Ali [EMAIL PROTECTED] wrote: I have a Perl CGI script which uses DBI to access MySQL. I noticed that each query through the Perl CGI script using DBI has a connect, query and then quit. I was wondering if there is a way of keeping the connection persistent to Mysql through the Perl CGI script. In my Apache httpd.conf I inserted PerlModule Apache::DBI before all LoadModule lines, but that does not solve the problem. I also downloaded the Apache::DBI module from CPAN and installed it. Perhaps I need to do something else? Is your script running through mod_perl or plain CGI? If it is running through CGI, you can't make persistent connection to MySQL. You should check: http://perl.apache.org/docs/index.html -- MySQL General Mailing List For list archives: http://lists.mysql.com/mysql To unsubscribe:http://lists.mysql.com/[EMAIL PROTECTED]
Re: Mysql and Perl DBI
Use only GCC-2.95.2 Gordon Stewart wrote: I am running Redhat 7 and mysql and I have tried to install Msql-Mysql DBI module But I get errors when I do a make I have enclosed a screen dump of the output I get. I seams to be getting stuck with dbimon. I have installed DBI-1-14.tar.gz. User name for connecting to database test? [undef] Password for connecting to database test? [undef] Creating files for MySQL Checking if your kit is complete... Looks good Using DBI 1.14 installed in /usr/lib/perl5/site_perl/5.6.0/i386-linux/auto/DBI Writing Makefile for DBD::mysql Writing Makefile for Msql-Mysql-modules [gordon@fido Msql-Mysql-modules-1.2213]$ make mkdir blib mkdir blib/lib mkdir blib/arch mkdir blib/arch/auto mkdir blib/arch/auto/Msql-Mysql-modules mkdir blib/lib/auto mkdir blib/lib/auto/Msql-Mysql-modules mkdir blib/man1 /usr/bin/perl -Iblib/arch -Iblib/lib -I/usr/lib/perl5/5.6.0/i386-linux \ -I/usr/lib/perl5/5.6.0 -Ilib -MExtUtils::PerlPP \ -e ppp "dbd/dbimon.in" "dbimon" "lib/DBD/mysql/Install/Config.pm" /usr/bin/pod2text mysql/lib/DBD/mysql.pm README make[1]: Entering directory `/home/gordon/Msql-Mysql-modules-1.2213/mysql' mkdir ../blib/lib/DBD mkdir ../blib/arch/auto/DBD mkdir ../blib/arch/auto/DBD/mysql mkdir ../blib/lib/auto/DBD mkdir ../blib/lib/auto/DBD/mysql mkdir ../blib/man3 cp lib/DBD/mysql.pm ../blib/lib/DBD/mysql.pm cp lib/Bundle/DBD/mysql.pm ../blib/lib/Bundle/DBD/mysql.pm cp lib/Mysql/Statement.pm ../blib/lib/Mysql/Statement.pm cp lib/Mysql.pm ../blib/lib/Mysql.pm gcc -c -I/usr/lib/perl5/site_perl/5.6.0/i386-linux/auto/DBI -I/usr/include/m ysql -I../dbd -I/usr/lib/perl5/site_perl/5.6.0/i386-linux/auto/DBI -I/usr/li b/perl5/5.6.0/i386-linux -fno-strict-aliasing -O2 -march=i386 -mcpu=i686 -DVERSION=\"2.0413\" -DXS_VERSION=\"2.0413\" -fPIC -I/usr/lib/perl5/5.6.0/i 386-linux/CORE -DDBD_MYSQL dbdimp.c /usr/bin/perl -p -e "s/~DRIVER~/mysql/g" /usr/lib/perl5/site_perl/5.6.0/i386-linux/auto/DBI/Driver.xst mysql.xsi /usr/bin/perl -I/usr/lib/perl5/5.6.0/i386-linux -I/usr/lib/perl5/5.6.0 /usr/lib/perl5/5.6.0/ExtUtils/xsubpp -typemap /usr/lib/perl5/5.6.0/ExtUtils/typemap mysql.xs mysql.xsc mv mysql.xsc mysql.c gcc -c -I/usr/lib/perl5/site_perl/5.6.0/i386-linux/auto/DBI -I/usr/include/m ysql -I../dbd -I/usr/lib/perl5/site_perl/5.6.0/i386-linux/auto/DBI -I/usr/li b/perl5/5.6.0/i386-linux -fno-strict-aliasing -O2 -march=i386 -mcpu=i686 -DVERSION=\"2.0413\" -DXS_VERSION=\"2.0413\" -fPIC -I/usr/lib/perl5/5.6.0/i 386-linux/CORE -DDBD_MYSQL mysql.c Running Mkbootstrap for DBD::mysql () chmod 644 mysql.bs LD_RUN_PATH="/usr/lib/mysql:/lib:/usr/lib/gcc-lib/i386-redhat-linux/2.96" gcc -o ../blib/arch/auto/DBD/mysql/mysql.so -shared -L/usr/local/lib dbdimp.o mysql.o -L/usr/lib/mysql-L/usr/lib/mysql -lmysqlclient -lm -L/usr/lib/gc c-lib/i386-redhat-linux/2.96 -lgcc chmod 755 ../blib/arch/auto/DBD/mysql/mysql.so cp mysql.bs ../blib/arch/auto/DBD/mysql/mysql.bs chmod 644 ../blib/arch/auto/DBD/mysql/mysql.bs Manifying ../blib/man3/DBD::mysql.3pm Manifying ../blib/man3/Bundle::DBD::mysql.3pm Manifying ../blib/man3/Mysql.3pm make[1]: Leaving directory `/home/gordon/Msql-Mysql-modules-1.2213/mysql' mkdir blib/script cp dbimon blib/script/dbimon /usr/bin/perl -I/usr/lib/perl5/5.6.0/i386-linux -I/usr/lib/perl5/5.6.0 -MExt Utils::MakeMaker -e "MY-fixin(shift)" blib/script/dbimon Manifying blib/man1/dbimon.1 *** ERROR: unterminated C... at line 1426 in file dbimon *** ERROR: unterminated C... at line 1450 in file dbimon Can any one help Gordon - Before posting, please check: http://www.mysql.com/manual.php (the manual) http://lists.mysql.com/ (the list archive) To request this thread, e-mail [EMAIL PROTECTED] To unsubscribe, e-mail [EMAIL PROTECTED] Trouble unsubscribing? Try: http://lists.mysql.com/php/unsubscribe.php - Before posting, please check: http://www.mysql.com/manual.php (the manual) http://lists.mysql.com/ (the list archive) To request this thread, e-mail [EMAIL PROTECTED] To unsubscribe, e-mail [EMAIL PROTECTED] Trouble unsubscribing? Try: http://lists.mysql.com/php/unsubscribe.php
RE: Mysql and Perl DBI
The redhat 7 mysql version doesn't work correctly...i.e. the mysql.h is missing. The solution is to re-install with the a tarball from the mysql site.. :( eric -Original Message- From: Gordon Stewart [mailto:[EMAIL PROTECTED]] Sent: Wednesday, April 11, 2001 5:29 AM To: [EMAIL PROTECTED] Subject: Mysql and Perl DBI I am running Redhat 7 and mysql and I have tried to install Msql-Mysql DBI module But I get errors when I do a make. Can any one help Gordon - Before posting, please check: http://www.mysql.com/manual.php (the manual) http://lists.mysql.com/ (the list archive) To request this thread, e-mail [EMAIL PROTECTED] To unsubscribe, e-mail [EMAIL PROTECTED] Trouble unsubscribing? Try: http://lists.mysql.com/php/unsubscribe.php - Before posting, please check: http://www.mysql.com/manual.php (the manual) http://lists.mysql.com/ (the list archive) To request this thread, e-mail [EMAIL PROTECTED] To unsubscribe, e-mail [EMAIL PROTECTED] Trouble unsubscribing? Try: http://lists.mysql.com/php/unsubscribe.php
RE: Mysql and Perl DBI
I highly recommend a source installation for everyone anyway. The RPMs are problematic to say the least. The source install is easy anyway. At 09:21 AM 4/11/2001 -0700, Eric Fegraus wrote: The redhat 7 mysql version doesn't work correctly...i.e. the mysql.h is missing. The solution is to re-install with the a tarball from the mysql site.. :( eric -Original Message- From: Gordon Stewart [mailto:[EMAIL PROTECTED]] Sent: Wednesday, April 11, 2001 5:29 AM To: [EMAIL PROTECTED] Subject: Mysql and Perl DBI I am running Redhat 7 and mysql and I have tried to install Msql-Mysql DBI module But I get errors when I do a make. Can any one help Gordon - Before posting, please check: http://www.mysql.com/manual.php (the manual) http://lists.mysql.com/ (the list archive) To request this thread, e-mail [EMAIL PROTECTED] To unsubscribe, e-mail [EMAIL PROTECTED] Trouble unsubscribing? Try: http://lists.mysql.com/php/unsubscribe.php - Before posting, please check: http://www.mysql.com/manual.php (the manual) http://lists.mysql.com/ (the list archive) To request this thread, e-mail [EMAIL PROTECTED] To unsubscribe, e-mail [EMAIL PROTECTED] Trouble unsubscribing? Try: http://lists.mysql.com/php/unsubscribe.php - Scott Baker - Webster Internet - Network Technician 503.266.8253 - [EMAIL PROTECTED] "It has been said that the primary function of schools is to impart enough facts to make children stop asking questions. Some, with whom the schools do not succeed, become scientists." - Knut Schmidt-Nielson - Before posting, please check: http://www.mysql.com/manual.php (the manual) http://lists.mysql.com/ (the list archive) To request this thread, e-mail [EMAIL PROTECTED] To unsubscribe, e-mail [EMAIL PROTECTED] Trouble unsubscribing? Try: http://lists.mysql.com/php/unsubscribe.php
Re: Mysql and Perl DBI
Gordon, What kind of errors? A copy/paste of errors would be useful. Cheers Ben - Original Message - From: Gordon Stewart [EMAIL PROTECTED] To: [EMAIL PROTECTED] Sent: Wednesday, April 11, 2001 1:29 PM Subject: Mysql and Perl DBI I am running Redhat 7 and mysql and I have tried to install Msql-Mysql DBI module But I get errors when I do a make. Can any one help Gordon - Before posting, please check: http://www.mysql.com/manual.php (the manual) http://lists.mysql.com/ (the list archive) To request this thread, e-mail [EMAIL PROTECTED] To unsubscribe, e-mail [EMAIL PROTECTED] Trouble unsubscribing? Try: http://lists.mysql.com/php/unsubscribe.php - Before posting, please check: http://www.mysql.com/manual.php (the manual) http://lists.mysql.com/ (the list archive) To request this thread, e-mail [EMAIL PROTECTED] To unsubscribe, e-mail [EMAIL PROTECTED] Trouble unsubscribing? Try: http://lists.mysql.com/php/unsubscribe.php