How to install MySQL in order for DBI/DBD MySQL install to work

How to install MySQL in order for DBI/DBD MySQL install to work

am 09.10.2003 20:26:15 von Carol Andrejak

--0-1097725964-1065723975=:16255
Content-Type: text/plain; charset=us-ascii

Hello listers,

I have been having a terrible time trying to get the perl DBD module installed to interface between my WebEvent calendar program and the MySQL database. I used to have a working MySQL that had been compiled from the binaries; but now I don't thanks to this fiasco. Things had gotten so messed up that I removed everything I could find that had anything to do with MySQL and now I am going to start over. Before I install MySQL (from RPMs as I am running RedHat 8.0) is there anything I need to do before hand to make sure the install will put files where they need to go so that I can get the DBD module to install. Before, the DBD module was looking for the mysql.d file to be in /usr/include/ and for a libmysqlclient.so file to be in /usr/shared/. (There was no such file on my machine.)

I am about to install MySQL server, client, shared, and devel rpm's. Before I do, I am ready to listen to any advice you folks can offer. Thanks.



Carol Andrejak
DSU Webmaster
Grossley Hall Rm. 7
302-857-7045

--0-1097725964-1065723975=:16255--

Re: How to install MySQL in order for DBI/DBD MySQL install to work

am 10.10.2003 05:22:11 von Rudy Lippan

tOn Thu, 9 Oct 2003, Carol Andrejak wrote:

> Hello listers,
> I have been having a terrible time trying to get the perl DBD module
> installed to interface between my WebEvent calendar program and the
> MySQL database. I used to have a working MySQL that had been compiled
> from the binaries; but now I don't thanks to this fiasco. Things had
> gotten so messed up that I removed everything I could find that had
> anything to do with MySQL and now I am going to start over. Before I
> install MySQL (from RPMs as I am running RedHat 8.0) is there anything I
> need to do before hand to make sure the install will put files where

The RPMs should put the files where they need to go on a red hat rpm
installed system. If you have any problems after you get the database
server and client libs installed email the list and we will help try and
debug what is going wrong. One thing that you might want to try is a
DBD::mysql RPM for RedHat 8 which might be easier to install on your
system (I don't know if there is one, but I thought that RH had an RPM for
mysql, so I would assume that they put together one for the DBD driver??).


Rudy


--
MySQL Perl Mailing List
For list archives: http://lists.mysql.com/perl
To unsubscribe: http://lists.mysql.com/perl?unsub=gcdmp-msql-mysql-modules@m .gmane.org

Re: How to install MySQL in order for DBI/DBD MySQL install to work

am 10.10.2003 05:22:11 von Rudy Lippan

tOn Thu, 9 Oct 2003, Carol Andrejak wrote:

> Hello listers,
> I have been having a terrible time trying to get the perl DBD module
> installed to interface between my WebEvent calendar program and the
> MySQL database. I used to have a working MySQL that had been compiled
> from the binaries; but now I don't thanks to this fiasco. Things had
> gotten so messed up that I removed everything I could find that had
> anything to do with MySQL and now I am going to start over. Before I
> install MySQL (from RPMs as I am running RedHat 8.0) is there anything I
> need to do before hand to make sure the install will put files where

The RPMs should put the files where they need to go on a red hat rpm
installed system. If you have any problems after you get the database
server and client libs installed email the list and we will help try and
debug what is going wrong. One thing that you might want to try is a
DBD::mysql RPM for RedHat 8 which might be easier to install on your
system (I don't know if there is one, but I thought that RH had an RPM for
mysql, so I would assume that they put together one for the DBD driver??).


Rudy


--
MySQL Perl Mailing List
For list archives: http://lists.mysql.com/perl
To unsubscribe: http://lists.mysql.com/perl?unsub=gcdmp-msql-mysql-modules@m .gmane.org

Re: How to install MySQL in order for DBI/DBD MySQL install to work

am 10.10.2003 06:19:42 von John Von Essen

Carol,

I am not sure where your problem lies, in mysql, in the DBD driver, or
in both.

One thing I have found is that when you install the DBD driver from
source, sometimes it can't find your mysql libs. The mysql DBD driver
requires these libs to function. Below is some info to help you out.
However, one alternative (assuming mysql is installed and running) is
to use the mysqlPP module. This perl module does not depend on any
mysql libs, so it should compile straightforward. Unfortunately, if you
use it, you will have to modify perl scripts.

I recommend the following, as it sounds you are starting from scratch.

1. Make sure Mysql is installed and working. Once it is installed make
sure it starts up fine, create standard users, try to access it, etc.,.

2. Install Perl DBI and DBD::mysql modules from source. They can be
downloaded from cpan:

http://www.cpan.org/modules/by-module/DBI/DBI-1.x.tar.gz
http://www.cpan.org/modules/by-module/DBD/DBD-mysql-2.x.tar. gz

Where x is the latest version. If you are not running perl 5.8 the
newer DBI might not compile - you'll have to use an older one. Unpack
the modules and build them as such:

For DBI:

perl Makefile.PL
make
make test
make install

For DBD::mysql:

perl Makefile.PL \
--libs="-L/usr/local/mysql/lib/mysql -lmysqlclient -lz" \
--cflags=-I/usr/local/mysql/include/mysql \
--testhost=localhost \
--testuser=someuser \
--testpassword=somepass
make
make test
make install

The libs and cflags are paths to your installed mysql libs and
includes. The examples I used are typical. I am not sure how/where
redhat puts the libs when you install mysql from RPM (might be just
/usr/local/lib). The way to find out is just search for the files
"libmysqlclient.so.10" and "mysql.h". The other args are just var's in
order to make test connections when you run make test.


John Von Essen (john@essenz.com)
President, Essenz Consulting (www.essenz.com)
Phone: (800) 248-1736
Fax: (800) 852-3387


On Thursday, October 9, 2003, at 02:26 PM, Carol Andrejak wrote:

> Hello listers,
>
> I have been having a terrible time trying to get the perl DBD module
> installed to interface between my WebEvent calendar program and the
> MySQL database. I used to have a working MySQL that had been compiled
> from the binaries; but now I don't thanks to this fiasco. Things had
> gotten so messed up that I removed everything I could find that had
> anything to do with MySQL and now I am going to start over. Before I
> install MySQL (from RPMs as I am running RedHat 8.0) is there anything
> I need to do before hand to make sure the install will put files where
> they need to go so that I can get the DBD module to install. Before,
> the DBD module was looking for the mysql.d file to be in /usr/include/
> and for a libmysqlclient.so file to be in /usr/shared/. (There was no
> such file on my machine.)
>
> I am about to install MySQL server, client, shared, and devel rpm's.
> Before I do, I am ready to listen to any advice you folks can offer.
> Thanks.
>
>
>
> Carol Andrejak
> DSU Webmaster
> Grossley Hall Rm. 7
> 302-857-7045
>


--
MySQL Perl Mailing List
For list archives: http://lists.mysql.com/perl
To unsubscribe: http://lists.mysql.com/perl?unsub=gcdmp-msql-mysql-modules@m .gmane.org

Re: How to install MySQL in order for DBI/DBD MySQL install to work

am 10.10.2003 06:19:42 von John Von Essen

Carol,

I am not sure where your problem lies, in mysql, in the DBD driver, or
in both.

One thing I have found is that when you install the DBD driver from
source, sometimes it can't find your mysql libs. The mysql DBD driver
requires these libs to function. Below is some info to help you out.
However, one alternative (assuming mysql is installed and running) is
to use the mysqlPP module. This perl module does not depend on any
mysql libs, so it should compile straightforward. Unfortunately, if you
use it, you will have to modify perl scripts.

I recommend the following, as it sounds you are starting from scratch.

1. Make sure Mysql is installed and working. Once it is installed make
sure it starts up fine, create standard users, try to access it, etc.,.

2. Install Perl DBI and DBD::mysql modules from source. They can be
downloaded from cpan:

http://www.cpan.org/modules/by-module/DBI/DBI-1.x.tar.gz
http://www.cpan.org/modules/by-module/DBD/DBD-mysql-2.x.tar. gz

Where x is the latest version. If you are not running perl 5.8 the
newer DBI might not compile - you'll have to use an older one. Unpack
the modules and build them as such:

For DBI:

perl Makefile.PL
make
make test
make install

For DBD::mysql:

perl Makefile.PL \
--libs="-L/usr/local/mysql/lib/mysql -lmysqlclient -lz" \
--cflags=-I/usr/local/mysql/include/mysql \
--testhost=localhost \
--testuser=someuser \
--testpassword=somepass
make
make test
make install

The libs and cflags are paths to your installed mysql libs and
includes. The examples I used are typical. I am not sure how/where
redhat puts the libs when you install mysql from RPM (might be just
/usr/local/lib). The way to find out is just search for the files
"libmysqlclient.so.10" and "mysql.h". The other args are just var's in
order to make test connections when you run make test.


John Von Essen (john@essenz.com)
President, Essenz Consulting (www.essenz.com)
Phone: (800) 248-1736
Fax: (800) 852-3387


On Thursday, October 9, 2003, at 02:26 PM, Carol Andrejak wrote:

> Hello listers,
>
> I have been having a terrible time trying to get the perl DBD module
> installed to interface between my WebEvent calendar program and the
> MySQL database. I used to have a working MySQL that had been compiled
> from the binaries; but now I don't thanks to this fiasco. Things had
> gotten so messed up that I removed everything I could find that had
> anything to do with MySQL and now I am going to start over. Before I
> install MySQL (from RPMs as I am running RedHat 8.0) is there anything
> I need to do before hand to make sure the install will put files where
> they need to go so that I can get the DBD module to install. Before,
> the DBD module was looking for the mysql.d file to be in /usr/include/
> and for a libmysqlclient.so file to be in /usr/shared/. (There was no
> such file on my machine.)
>
> I am about to install MySQL server, client, shared, and devel rpm's.
> Before I do, I am ready to listen to any advice you folks can offer.
> Thanks.
>
>
>
> Carol Andrejak
> DSU Webmaster
> Grossley Hall Rm. 7
> 302-857-7045
>


--
MySQL Perl Mailing List
For list archives: http://lists.mysql.com/perl
To unsubscribe: http://lists.mysql.com/perl?unsub=gcdmp-msql-mysql-modules@m .gmane.org