Drupal 7, PHP 5.4 and MySQL via Software Collections
In order to test out the new Red Hat Software Collections (RHSCL, announcement) version of PHP 5.4, I decided to build out a Drupal 7 install using the php54 collection and the mysql55 collection.
Overall, the activity was pretty much like a normal Drupal install. However, to use software collections you have to do a few things differently. Also, if you haven’t used a software collection for a “service” (e.g. MySQL) before, the service setup is also a little different than the native versions.
First and foremost, add the channels for RHSCL either via subscription manager or rhn. The name of the channel (for the beta) is rhel-server-rhscl-6-beta-rpms. After that, you need to install the software collections. So, something like:
#yum install php54 mysql55
You could also just install all the dependencies in the same line, but I wanted to pull them out to be able to comment on them a little bit more. I also tend to install some of the semi-optional components because I think Drupal works better that way.
First off, the easiest thing to install, which is also not really related to software collections, is gd (not called “GIF Draw” 🙂 ). Very simple, just install gd from the normal RHEL repositories.
#yum install gd
Next, we need the “driver” libraries for php to various other things. All the ones we need are included in the “php54 Software Collection” but are not installed by the simple install of the php54 package as they are not required for basic php. php54-php-gd is the connection from php to the gd library. php54-php-mbstring is a library for unicode, technically not a “driver” but an optional library. Finally, we need to connect to mysql so we install php54-php-mysqlnd.
#yum install php54-php-gd php54-php-mbstring php54-php-mysqlnd
Last but not least, we need to install the php “driver” for httpd. Now, I call this one out
Continue reading “Drupal 7, PHP 5.4 and MySQL via Software Collections”