Perl Installing, Uninstalling

I have some problems with mysql, and maybe perl installation faults.
I have installed perl by source. I followed default configuration (e.g. ./configure, make, make install).
I have installed perl just because it was required for mysql's installation.

But now I have some problems.

If I will uninstall perl, and reinstall it as package, what may will happen???? :slight_smile:

Or its better to uninstall mysql first, uninstall perl,
and then reinstall them???????

The problems that i have to handle are:
at webmin, servers , mysql, provides the following warning

Warning: The Perl modules DBI and DBD::mysql are not installed on your system, so Webmin will not be able to reliably access your MySQL database. Click here to install them now.

and the link is broken.

and i copy/pasted a database from redhat to solaris, and i cant open ISM tables. always provides errono : 138, and I tried many things, but nothing.
I tried isamchk , but nothing.
I tried from mysql tool from my pc (windows xp), nothing again.

I'm the same guy with Solaris 7 sparc 5 thread, for more information.

Maybe some will say:
Throw away the god damn machine.
:slight_smile:

I cant say that they are wrong in their believes.:slight_smile:

Thanks.

DBD::mysql is a perl module which it sounds like you need to install. You should be able to install it quite happily without uninstalling/re-instaling perl.

If have already setup security on your mysql server then you'll have to install it manually. You can get it from www.cpan.org. Read the README first.

I believe the problem is huge :slight_smile:

So, so far, I have installed successfully DBI.
But, I'm trying to install DBD, and the pain begins :slight_smile: .

I've tried to install many distributions with many ways of compilation.

I'm posting the last compilation, and the following errors.

# perl Makefile.PL --libs="-L/usr/local/mysql/lib/mysql -L/usr/local/lib -lmysqlclient -lz -lposix4 -lgen -lsocket -lnsl -lm" --cflags=-I/usr/local/mysql/include/mysql/
I will use the following settings for compiling and testing:

cflags (User's choice) = -I/usr/local/mysql/include/mysql/
embedded (mysql_config ) =
libs (User's choice) = -L/usr/local/mysql/lib/mysql -L/usr/local/lib -lmysqlclient -lz -lposix4 -lgen -lsocket -lnsl -lm
mysql_config (guessed ) = mysql_config
nocatchstderr (default ) = 0
nofoundrows (default ) = 0
ps-protocol (default ) = 1
ssl (guessed ) = 0
testdb (default ) = test
testhost (default ) =
testpassword (default ) =
testsocket (default ) =
testuser (default ) =

To change these settings, see 'perl Makefile.PL --help' and
'perldoc INSTALL'.

Note (probably harmless): No library found for -lmysqlclient
Using DBI 1.48 (for perl 5.008005 on sun4-solaris) installed in /usr/local/lib/perl5/site_perl/5.8.5/sun4-solaris/auto/DBI/
Writing Makefile for DBD::mysql

So far one "harmless" warning.

but,

#make

cp lib/DBD/mysql.pm blib/lib/DBD/mysql.pm
cp lib/DBD/mysql/GetInfo.pm blib/lib/DBD/mysql/GetInfo.pm
cp lib/Mysql.pm blib/lib/Mysql.pm
cp lib/DBD/mysql/INSTALL.pod blib/lib/DBD/mysql/INSTALL.pod
cp lib/Mysql/Statement.pm blib/lib/Mysql/Statement.pm
cp lib/Bundle/DBD/mysql.pm blib/lib/Bundle/DBD/mysql.pm
gcc -c -I/usr/local/lib/perl5/site_perl/5.8.5/sun4-solaris/auto/DBI/ -I/usr/local/mysql/include/mysql/ -DDBD_MYSQL_INSERT_ID_IS_GOOD -g -fno-strict-aliasing -pipe -I/usr/local/include -D_LARGEFILE_SOURCE -D_FILE_OFFSET_BITS=64 -O -DVERSION=\"3.0002_1\" -DXS_VERSION=\"3.0002_1\" -fPIC "-I/usr/local/lib/perl5/5.8.5/sun4-solaris/CORE" dbdimp.c
/usr/local/bin/perl -p -e "s/~DRIVER~/mysql/g" /usr/local/lib/perl5/site_perl/5.8.5/sun4-solaris/auto/DBI//Driver.xst > mysql.xsi
/usr/local/bin/perl /usr/local/lib/perl5/5.8.5/ExtUtils/xsubpp -typemap /usr/local/lib/perl5/5.8.5/ExtUtils/typemap mysql.xs > mysql.xsc && mv mysql.xsc mysql.c
Warning: duplicate function definition 'do' detected in mysql.xs, line 224
Warning: duplicate function definition 'rows' detected in mysql.xs, line 557
................
................
................
ld: fatal: relocation error: R_SPARC_32: file dbdimp.o: symbol <unknown>: offset 0xef17a60b is non-aligned

ld: fatal: relocation error: R_SPARC_32: file mysql.o: symbol <unknown>: offset 0xef17a62b is non-aligned

collect2: ld returned 1 exit status
make: *** [blib/arch/auto/DBD/mysql/mysql.so] Error 1

:slight_smile:

Also I want to mention that, I searched for libmysqlclient libraries, and I found something in :

# ls -l /usr/local/mysql/lib/mysql/
total 3284
-rw-r--r-- 1 root other 19704 Aug 3 09:21 libdbug.a
-rw-r--r-- 1 root other 34416 Aug 3 09:23 libheap.a
-rw-r--r-- 1 root other 12972 Aug 3 09:22 libmerge.a
-rw-r--r-- 1 root other 302668 Aug 3 09:22 libmyisam.a
-rw-r--r-- 1 root other 22900 Aug 3 09:23 libmyisammrg.a
-rwxr-xr-x 1 root other 811 Aug 3 09:20 libmysqlclient.la
-rw-r--r-- 1 root other 344780 Aug 8 14:46 libmysqlclient.old
-rw-r--r-- 1 root other 353096 Aug 3 09:20 libmysqlclient_r.a
-rwxr-xr-x 1 root other 855 Aug 3 09:20 libmysqlclient_r.la
-rw-r--r-- 1 root other 123876 Aug 3 09:21 libmystrings.a
-rw-r--r-- 1 root other 256980 Aug 3 09:21 libmysys.a
-rw-r--r-- 1 root other 116508 Aug 3 09:22 libnisam.a
-rw-r--r-- 1 root other 5212 Aug 3 09:23 libvio.a

Happiness :slight_smile:

Thanks again.

Do you really need so many options? Most of the time, compiling without any option should be fine (you may need a few in case you would like to run the test suite before installing, but I will usually skip it), because the parameters are provided by mysql_config, which gives all the values needed.

May be we get back to the basics. Post what you see with

perl Makefile.PL

and the results of "make".

Hello cbkihong .

I followed your advice.

But.

It provides me the same error as above.

Now I'm thinking if the specific destribution of DBD::mysql module, is really compatible with mysql-4.0.21, DBI-1.48, and general with Solaris 7, sparc 5.

I don't know. I'm trying several distributions of DBD, like DBD-mysql-2.1012,
DBD-mysql-2.1018, DBD-mysql-2.1021, DBD-mysql-2.9008, and DBD-mysql-3.0002_1.

Some of them, like DBD-mysql-3.0002_1, provides me different errors. For instance it cant recognize e specific string (I'm sorry, I dont remeber now).
Another distribution makes the makefile, with some warnings, but when I execute 'make test' (after 'make'), it provides many failures.

Failed Test Stat Wstat Total Fail Failed List of Failed
-------------------------------------------------------------------------------
t/00base.t 255 65280 5 4 80.00% 4-5
t/10dsnlist.t 255 65280 9 18 200.00% 1-9
t/20createdrop.t 255 65280 5 10 200.00% 1-5
t/30insertfetch.t 255 65280 11 22 200.00% 1-11
t/40bindparam.t 255 65280 28 56 200.00% 1-28
t/40blobs.t 255 65280 11 22 200.00% 1-11
t/40listfields.t 255 65280 16 32 200.00% 1-16
t/40nulls.t 255 65280 11 22 200.00% 1-11
t/40numrows.t 255 65280 25 50 200.00% 1-25
t/50chopblanks.t 255 65280 35 70 200.00% 1-35
t/50commit.t 255 65280 30 60 200.00% 1-30
t/ak-dbd.t 255 65280 90 180 200.00% 1-90
t/akmisc.t 255 65280 351 702 200.00% 1-351
t/dbdadmin.t 255 65280 20 40 200.00% 1-20
t/insertid.t 255 65280 12 24 200.00% 1-12
t/mysql.t 255 65280 68 136 200.00% 1-68
t/mysql2.t 255 65280 ?? ?? % ??

Your directory listing of /usr/local/mysql/lib/mysql/ shows the problem. There is no libmysqlclient.a or libmysqlclient.so DBD::mysql is looking for one of these 2 files.

I'm searching for a package which installs those files.
Because those files don't exist in my system.

I found in google for mysql-shares-comet package, but I cannot find a link tou download it.
An remember. I cannot use rpm's.

Hmm ... can you download the sources of mysql from dev.mysql.com and compile it yourself? If you cannot find a binary distribution of mysql then this is probably the only way left. Yes, I'm also thinking about some compatibility problems between your MySQL installation and the module.

An update.

mysql is up. apache is up. php (I think is up :slight_smile: ).

I can see the site from an internet explorer. but only the index.php.

Because index.php is a login page.

Unfortynately I cannot loggin, because mysql cannot see the tables which contain the user names and the passwords.
And of cource I cannot see directly a specific page inside the site.
It redirects me to login page.

So, I will start searching about mysql.
But I will mention a fact that I noticed.

from my pc (windows xp) I'm using a mysql client and I can administrate the database in production server.
The database that is copy/pasted in Solaris, is taken from production server.
So, from that tool I can see that almost the half tables are MyISAM-type,
and the others are ISAM-type.

In Solaris, mysql cannot see ISAM tables (the tables are there, I can see them, but when I'm clicking on each of them, ite provides me an error like:
[intranet] ERROR 1016: Can't open file: 'Calendar.ISM'. (errno: 138),
and of cource I cannot see the data.).

So, thank you for your help, and your usefull advices. They saved me from a lot of trouble.

I'm starting my search.

p.s. all the DBD::mysql module stuff didn't complete. I don't know why.
DBD resisted hardly to be installed.
I installed an rpm package which plays well in Solaris 8.
Of cource I have Solaris 7, but I tried to see if it works. But.... :slight_smile: