Upgrading to MySQL 5.0.36 on RHEL and CentOS

March 6, 2007 by · 9 Comments 

Let me start by saying, "yes, I know that MySQL 5.0.36 isn't on the download page yet". That's because this is an enterprise-only release under the Monthly Rapid Update program. That said, there is absolutely nothing preventing the build of this version as a community release.

As with my prior release of MySQL 5.0.33 for RHEL & CentOS 4, the i386 binary packages and the src.rpm are packaged in the "Red Hat"-style that is used for the RHEL-, CentOS-, and Fedora-distributed packages. That means that the client & shared libraries are packaged as "mysql", that the "mysqld" daemon is packaged as "mysql-server", etc.

There are no significant changes to the src.rpm for this release except the inclusion of two man pages that are either new for this release or were missed by my last package. In either case, they've been included in the "mysql-server" package.

Regarding the changes from the last official src.rpm from MySQL, they're far too numerous to list. If you're interested I'd suggest installing the src.rpm and examining the mysql-5.0.36.spec file, otherwise, just install the binary packages.

NOTE: An update to this article has been created in a new post. I no longer suggest that users use these packages. If you already are, there's no harm, it's just that the new ones in the other post are more like the original RHEL/CentOS build.

Update (9/24/2009): Packages deleted, use the yum repository instead.


9 Responses to “Upgrading to MySQL 5.0.36 on RHEL and CentOS”
  1. Jacek says:

    First of all, many thanks for great tutorials.
    It seems that your specfile is based on SuSE, which uses options significantly different that RedHat line of development, e.g. "--disable-shared" vs. "--enable-shared", "--with-berkeley-db", etc.
    Would it be possible for you to provide the spec.file along the RedHat specifications, please? What's the reason behind using SuSE specs? (I'm afraid to break compatibility with existing RHEL libraries and applications.) Apart from this, I can confirm that it builds without a glitch on the latest RHEL4u4 x86_64.
    Thank you once again.
    Best, Jacek

  2. Jason says:


    The spec file is based on the official MySQL build for RHEL4. Functionally, these packages are identical to the official MySQL.com packages. Structurally, they mimic the RH/Fedora packages.

    The spec file is included in the src.rpm (it should be unpacked in /usr/src/redhat/SPECS). I modified the official MySQL RHEL4 spec file to rearrange their build so that it is packaged and structured as the RedHat/Fedora builds are. I did not change any of the compile options in order to match the original RH packages. If there are SuSE-specific options in that spec file, those changes were made by MySQL, not me.

    That said, I am working on an updated version that will more-closely mimic the RH function as well as structure. If all goes well, it will be up later today.

  3. Jacek says:

    Dear Jason,

    Thanks for your swift reply.

    Through trial and error (using your GREAT tutorials) I managed to build this package on RHEL4u4 x86_64 using the spec file and additional source files from "mysql-5.0.33-1.fc7.src.rpm" with the following changes:

    I had to comment out the following 3 patches:
    #Patch4: mysql-testing.patch
    #Patch10: mysql-ssl-bugs.patch
    #Patch11: mysql-y2007bug.patch

    Patch #11 seems obsolete. Probably because of disabling patches #4 and #10 I have to enter manually my real PEM pass phrase for SSL during the build testing process when it asks for it twice for 'ssl-connect', but then the compilation continues and the RPMs are created successfully.

    I also had to change the man section of the spec file to reflect files actually present in the 'man' directory:


    I really learned HUGE amounts of "RPM building knowledge and magic" following articles on your site. In fact, that was the first successful software package compilation in my life. Thank you very much.

    Best wishes,


  4. Jacek says:

    The only thing that worries me is that the resulting rpms are kind of... BIG in comparison to CentOS builds, e.g. mysql-server-5.0.36-1.x86_64.rpm is 21MB vs. 10.1MB for mysql-server-5.0.27-1.el4.centos.x86_64.rpm. Is it normal?

  5. Jason says:

    Something you said made didn't kick in right away but I checked again later last night and the shared libraries ARE included in the packages I built. They are compiled separately to avoid a dependency on the client itself.

    As to your question about the size of the mysql-server RPM, it seems like it should be more than 20MB for this version. For reference, my package sizes are ~11MB for 5.0.27 and ~23MB for 5.0.33 & 5.0.36.

    Finally, I hadn't noticed that the fc7 devel path had updated to 5.0.33. I may take a look at that and see if I can get that patch working so the build can be automated. If I do, I'll update the post.

  6. SocketCreep says:

    I did the 'yum --enablerepo=centosplus upgrade mysql' method of installing the latest mysql. The result of command 'rpm -q mysql is mysql-5.0.27-1.el4.centos. I am using O'Reilly's book "Web Database Applications with PHP & MySQL" as a guide, but it is based on the then current MySQL 3. I cannot seem to find the path where MySQL was installed. I know this seems like a stupid issue, but I cannot find the path to start the server.

    Also, the book refers to a manual build using some custom options in the configure step. How can a person alter a configuration built by yum?

  7. Jason says:

    You can start and stop the MySQL Daemon with "service mysqld start" and "service mysqld stop".

    As to reconfiguring, I wouldn't recommend it unless you really know what you're doing as you could do some serious damage.

  8. Thanks , my friend's in charge of our programming in our team and he had me search the net and I really hope this is what he wants , I have been scouring for hours so my head is throbbing and I can't think straight anymore.


Check out what others are saying about this post...
  1. [...] Archives « Upgrading to MySQL 5.0.36 on RHEL and CentOS 4 [...]

Speak Your Mind

Tell us what you're thinking...
and oh, if you want a pic to show with your comment, go get a gravatar!


Note: This post is over 5 years old. You may want to check later in this blog to see if there is new information relevant to your comment.

By submitting a comment here you grant this site a perpetual license to reproduce your words and name/web site in attribution. Use of a non-personal web site or blog in the "Web Site" field and/or leaving a comment that is off-topic or inappropriate may result in the comment being edited or removed at the discretion of the site owner.