Ok. All I want to do is get the PHP that is currently installed on my Red Hat 7.1 server to connect up to the MySQL server that I got running just fine on the same machine. WHen I try to use a MySQL connect command however it says it doesn't know what I am talking about basically.

I am guessing that means PHP wasn't created with the MySQL support in it. How do I put it in?

Thanks
Mebane2

    If I remember correctly, MySQL is provided with RedHat 7.1 but it isn't one of the basic installation options. You also need to install the client library package.

    Use gnorpm (in an X windows session) to browse the packages on the second RedHat CDROM and I think you'll see a few named mysql{something}. Install those and then test it with the mysql command line to see if it is alive. Then you'll want to make a user for mysql that your PHP sessions can use to access mySQL.

    Given the recent security patches to PHP you might want to start everything off with fresh RPM packages from the PHP and MySQL websites.

      Ya, the MySQL that I have running on it now was a fresh RPM from them. And I downloaded the latest PHP Source Code and tried to follow the directions to install it, but it seems to be having issues when I tell it to configure with MySQL support. I will have to check out that webpage in the first responce and see what I can do.

      I also can't seem to get up2date to work so I might just break down and download the latest ISO images for RedHat and reinstall the server.

      Thanks
      Mebane2

        Redhat might have an FAQ about this on their support section as well. I was able to get this working on RH 7.1 without compiling my own PHP or MySQL.

        Check your /etc/php.ini file
        and ensure the extension for mysql is uncommented. It should show this:

        extension=mysql.so

        Make sure you have the client driver file libmysqlclient.so.10 (the 10 part might vary
        depending on your release/version of this) in /usr/lib/mysql. If it isn't there, you probably don't have the client library package installed.

        RedHat does things very differently from the defaults in the distributions from PHP/MySQL having the source code. If you pick up an RPM for Redhat that is ready to go, that is fine, but the source to compile yourself is done with different paths for everything. It can be done, but you'd spend a full day tracing everything that has a path needing correction. It is far easier to get it working with the RedHat RPMs.

          Ya, I went out durring lunch and bought RedHat 7.3 just so I don't have to spend the time downloading it again and will have some tech support if I need it. Since UP2DATE was not working nicely on 7.1 it's prob the best anyway.

          When I get home and get a chance I am going to install it based on the page I think mmilano mentioned. It is a very nice page and looks like exactly what I want. It's not trying to teach me how rockets work, its just telling me the A to B to get it working and letting me figure things out as I do it.

          But as you know, "The Best Laid Plans of Mice and Men..." <grin> Had not thought about the source version having different paths and such but that does make sence.

          The guide uses only RPMs available on the distribution CDs so that "should" work <crosses fingers> Then I can move on to finally actually learning to code 😃

          Thanks
          Mebane2

            Write a Reply...