A common question that comes up fairly often, is which Linux distribution is best to use for deploying the LAMP software bundle? Quick reminder, the acronym LAMP refers to the first letters of Linux (operating system), Apache HTTP Server, MySQL (database software), and PHP, Perl or Python, principal components to build a viable general purpose web server. Since the question is phrased as which “Linux distro” is best to use — let’s exclude FreeBSD and other UNIX variants.
This article will attempt to explain in general terms the pros and cons of using a specific flavor of Linux. Currently there are three commercially viable Linux vendors: Red Hat, SUSE and Canonical. Ubuntu from Canonical is distributed as free and open source software, and there are open source variants of the other two Linux distros. CentOS (Community ENTerprise Operating System) is the open source version of RedHat Enterprise Linux (RHEL) with all Red Hat branding and utilities removed. openSUSE is open source distro of SUSE Linux Enterprise.
Now using the process of elimination lets attempt to select the best Linux distro for LAMP deployment. First we eliminate SUSE Linux/openSUSE from the competition. The main reason behind this is that SUSE is owned by Novell, which is in turn owned by Attachmate. This seems like a questionable combination from the start, so quality and support of future releases of this distro are unknown. It’s no surprise that Novell have been shopping around for a buyer for SUSE for a few years now. It has been rumored that VMware was interested in buying SUSE, but so far they haven’t. This means only two contenders are left: Red Hat/CentOS and Ubuntu.
For the purposes of this competition we will consider free open source distributions only (see my previous post for more reasons why). After all LAMP is supposed to be a combination of free, open source software. This leaves us with CentOS and Ubuntu. Since CentOS is RedHat Enterprise Linux based it is probably one of the most widely used Linux distros out there. That does not mean that it’s perfect. It has its share of issues and occasional bugs arising from the upstream RHEL releases. Ubuntu seems to have much wider hardware support, but since the main purpose of this competition is finding the best distro to deploy LAMP, we are going to discount Ubuntu Desktop and focus on Server only. Hardware support in CentOS is basically comparable to that of Ubuntu Server.
The two distros are not identical by any means. CentOS is RHEL based, uses Yum (PackageKit) update method, and RPM package manager. Ubuntu is Debian based, uses APT / Software Updater update method, and dpkg package manager. Working with either one will require specific knowledge, thus at this point you may have a preference for one or the other based on your past experiences. Now there are two good reasons why I believe that in the end Ubuntu comes out on top. First of all you can easily obtain commercial support for it from Canonical. This point might be important to some users. CentOS is community support only. Also, Canonical’s team seems to have the release process down to a science, with its bi-annual releases along with long-term support (LTS) releases that are maintained for five years.
The second reason why Ubuntu seems to be the winner here, is Ubuntu Cloud and OpenStack. Ubuntu Server is now widely available in the public cloud (Amazon Web Services, Rackspace, and Windows Azure), both as underlying infrastructure and as a guest operating system. With Ubuntu Cloud Guest, you can install Ubuntu Server instances on any of the leading public clouds. Canonical claims that Ubuntu is now the most heavily used guest OS on both Amazon Web Services (AWS) and Rackspace. That means you can easily move your systems between on/off-premise and between different public cloud providers. Based on the reasons described above, my prediction is that over the next few years we will see Ubuntu grow exponentially to become one of the dominant server platforms on the Internet. If you don’t believe me, just look at where Android was five years ago and where it is today.