Install MySQL client both 32 and 64 bits

Support for the other architectures (X86_64, IA-64, and PowerPC)
Post Reply
mioux
Posts: 9
Joined: 2009/10/13 18:52:30
Contact:

Install MySQL client both 32 and 64 bits

Post by mioux » 2010/04/21 09:19:58

Hello

I want to install (on a server) both 32 and 64 bits versions of the "mysql" package.

I have installed the 64 bits version from remi collet (http://rpms.famillecollet.com/) for an internal project, but we want to use a third party plugin for another. This plugin is a CGI for apache compiled in 32 bits only. So we started to install 32 bits libraries to make it work.

It requires libmysqlclient.so to work. A "yum provides" gave me my response, I need to install "mysql.i386", which cannot be installed due to conflicts between 32 and 64 bits packages. They use identic files (/etc/my.cnf and all /usr/share/mysql/* files)

To solve this, I have downloaded the i386 package with yumdownloader, unpacked it, and copied all files from ./usr/lib/mysql to /usr/lib/mysql, added a "/etc/ld.so.conf.d/mysql-i386.conf" file containing "/usr/lib/mysql", launched ldconfig, and the plugin works.

My solution is working, but I would prefer to install this library via yum, to have a "proper" installation, not a homemade patch.

Is there a way to install both packages ? Or is my solution a better solution ?

Thanks in advance

pschaff
Retired Moderator
Posts: 18276
Joined: 2006/12/13 20:15:34
Location: Tidewater, Virginia, North America
Contact:

Install MySQL client both 32 and 64 bits

Post by pschaff » 2010/04/21 19:25:07

[quote]
mioux wrote:
...
Is there a way to install both packages ? Or is my solution a better solution ?
[/quote]
No, and no. Multi-arch packages which have both ix86 and x86_64 versions in the x86_64 repos do not conflict. If the packages do conflict, they are not meant to be installed together. What you have done is very likely to break things. Why do you feel you need both versions?

mioux
Posts: 9
Joined: 2009/10/13 18:52:30
Contact:

Re: Install MySQL client both 32 and 64 bits

Post by mioux » 2010/04/22 12:08:43

I need 32 bit library for the 3rd CGI (as the developers said), and I need 64 bits for php and pdo.

In fact, the server has firstly been configured with centos x86_64 (this is a production server, not a dev one, our dev server is 32 bits). Then, our client wanted us to use this CGI for image creation. It uses X11 and mysql libraries. With 64 bits, the CGI does not run, so we have removed all the unused x86_64 packages, and installed only X11 libs in 32 bits versions.

The last problem was mysql. The CGI needs libmysqlclient.so. When calling "yum provides", I have found that the 32 bits version of the file was in the mysql.i386 package. But we cannot install it, because there is a clonflict between mysql.i386 and mysql.x86_64, this is why I have extracted the i386 package and manually installed the lib files in /usr/lib/mysql.

Thanks for the response indeed

pschaff
Retired Moderator
Posts: 18276
Joined: 2006/12/13 20:15:34
Location: Tidewater, Virginia, North America
Contact:

Re: Install MySQL client both 32 and 64 bits

Post by pschaff » 2010/04/22 12:22:03

[quote]
mioux wrote:
I need 32 bit library for the 3rd CGI (as the developers said), and I need 64 bits for php and pdo.
[/quote]
What do you mean by " 3rd CGI"? What developers said that you needed 32 bit packages, when and where? No reference was provided.

Rather than breaking a 64-bit system by removing the 64-bit libraries and kludging in (or [i]bodging[/i] for my friends across the pond - as [b]TrevorH[/b] has expanded my vocabulary :-) ) 32-bit versions, it would seem to me that the best approach would be to:

1. Use a 64-bit development environment and fix the problem with by creating 64-bit versions of your apps.

OR

2. Install a 32-bit OS on the server to match your development environment.

mioux
Posts: 9
Joined: 2009/10/13 18:52:30
Contact:

Re: Install MySQL client both 32 and 64 bits

Post by mioux » 2010/04/22 13:17:35

3rd CGi is 3rd party CGI :D

It's the developer of this CGI that have said we need to install 32 bit version of libraries. This CGI is not developed by our side, it's a component our client have bought to generate pictures (I even don't know what it does exactly, I'm not supposed to work on this project, I'm working in the windows/.net team, not Linux/php, but considering my colleagues and me, I'm the best Linux user, so when a problem occurs, they call me for assistance :D).

They cannot create a 64 bit version of the CGI (I don't know why exactly), only a 32 bits version. All of our programs are arch independent (it's only php). The server side has been configured in full 64 bits, as we thought we only need php component. This server has been running for a while, we have other applications running on it, which cannot be stopped.

It's an evolution of one of these applications that need this 32 bits CGI (it's not our choice, it's our client that uses it with other web apps).

pschaff
Retired Moderator
Posts: 18276
Joined: 2006/12/13 20:15:34
Location: Tidewater, Virginia, North America
Contact:

Re: Install MySQL client both 32 and 64 bits

Post by pschaff » 2010/04/22 15:05:40

The distro mysql provides both i386 and x86_64 versions, so sounds like a Remi issue, not a CentOS issue.
[code]
# rpm -q mysql
mysql-5.0.77-4.el5_4.2.x86_64
mysql-5.0.77-4.el5_4.2.i386
[/code]

You could remove the 3rd party packages and install the CentOS versions.

mioux
Posts: 9
Joined: 2009/10/13 18:52:30
Contact:

Re: Install MySQL client both 32 and 64 bits

Post by mioux » 2010/04/22 15:35:47

Thanks for the information. We can't use mysql from centos, there is too many dependencies from remi's depots that will break our apps (we use php 5.3php-pdo, pdo-mysql from his repo, these need mysql from his repo as dependencies). I should tell him for this issue with mysql package.

As the application works as is, it will remain until he changes something (or we move the app on another server)

Post Reply

Return to “CentOS 5 - X86_64,s390(x) and PowerPC Support”