Running a LAMP: Debian vs. CentOS

One of my clients uses CentOS for the production platform of their (web) application (written in PHP). They’ve asked me to take over the development and maintenance of their web application, so, naturally, I set up a new server with CentOS 5.2, rather than the Debian installation I would normally use.

I like Debian for a lot of reasons: it is generally a stable system that is well-documented, secure and easy to handle. The “easy to handle” part is, of course, because I happen to know my way around a Debian system. When I started out, seven years ago, professionally working on Linux systems, I started out on the then-current RedHat distro.

A lot has changes since then.

Sometimes I feel like a real geezer when I say that, but having memory go back a decade or more in computer science is like having a living memory go back to the middle ages in history: “civilization” started a few thousand years ago in “real” life, while it started only a few decades ago where computers are concerned. The age when computers arrived in the household is recent enough for me to remember it.

Anyway, back to the topic at hand. There are actually very few differences between CentOS and Debian: in many respects, they are very similar. I would argue that the CentOS installation is a bit more user-friendly in the way it set up its interface by default, but Debian has a better installer (apt) that CentOS does (it uses yum), though yum uses the RPM format while apt uses its own format – and RPM is the Linux standard, at least in the Linux Standard Base.

Debian has a lot more packages available, though – but for running a LAMP, that doesn’t change much.

So basically, for running a LAMP, I found them pretty much equivalent – though I will continue to prefer Debian because I know my way around better. Both do the job of running a LAMP just fine, both have a “when it’s ready” approach to releasing and both are well-documented.

About rlc

Software Analyst in embedded systems and C++, C and VHDL developer, I specialize in security, communications protocols and time synchronization, and am interested in concurrency, generic meta-programming and functional programming and their practical applications. I take a pragmatic approach to project management, focusing on the management of risk and scope. I have over two decades of experience as a software professional and a background in science.
This entry was posted in GNU/Linux (OS) and tagged , . Bookmark the permalink.

13 Responses to Running a LAMP: Debian vs. CentOS

  1. Pingback: Running a LAMP: Debian vs. CentOS | - Your one stop for news about Debian

  2. Gladia2r says:

    The question about hosting lamp on centos or debian can be put when it’s about more domains, and you’ll need an interface to manage them. At this point centOS is on top with cPanel support.

    • Hello Gladia2r,

      You have a very valid comment there, thank you.

      I agree that cPanel is a very popular, and therefore very important, solution for managing multiple domains on a single server, especially for situations such as those of hosting service providers. I must admit that I have never been in the business of hosting service providing, nor have any of my clients (so far) been. I was not aware that cPanel was not supported on Debian – though I am hardly surprised if this is the case: browsing their on-line documentation, they seem to be mostly based on RedHat, which CentOS seems to follow very closely, both in its approach and in its documentation, which is partly RedHat documentation.

      I can but agree with you that, if you need cPanel, CentOS is a better option than Debian – but do you really need cPanel? I am no expert in this domain, so I will let others do the comparison in my stead, but there do seem to be alternatives to cPanel on the market.

      Thanks again for your comment.


  3. Steve Parker says:

    CentOS does not just follow RedHat very closely, CentOS5.2 *is* RHEL5.2 without the trademarked logos. CentOS is source and binary compatible with RedHat Enterprise Linux.

  4. Pingback: Installing Git on CentOS 5.2 @ Making Life Easier

  5. Josiah Russell says:

    It is also easy to backup and transfer all your websites from one server to another server if you have cPanel installed:””

  6. Zoey Diaz says:

    if you are going to get a VPS server make sure that it has cPanel coz it makes server maintennance easier.`”

  7. Sphinx Khan says:

    Nice article. So basically one has to make his decision on what he/she is more comfortable with and if he/she needs cpanel? I am sure there has to be more than that.

    What about performance? or Security? or user community?

    • rlc says:

      Hi Sphinx Khan,

      You raise a good point: as both are Linux distros, I don’t think they’ll differ much w.r.t performance if not for their differences in defaults for such things like filesystems etc. I haven’t benchmarked them to compare the two on the same hardware, nor have I found a benchmark that compares the two, so I can’t really say if there’s a difference.

      As for security: the security of any server depends on the services running on the server and how they’re set up. It is possible to set up a very tight server with either distro, just as it is possible to set up a very leaky server with either distro. Personally, I find the Debian documentation for securing a server better w.r.t. accessibility, findability and thoroughness, but that might just be because I have more experience with Debian than I do with CentOS.

      W.r.t. the user community: both have a very wide and very active user community and, as both are Linux distros, there is some overlap between the two communities.

      Thanks for the comment,


  8. Aaron Graves says:

    I typically use FreeBSD on my servers, and with a few custom-written scripts I can manage many domains effortlessly (and without having to install additional software such as cpanel). Granted, I understand not everyone will be able to duplicate this.

    That said, personally if I must use a Linux distro I prefer Debian over CentOS, simply because that’s what I’m most familiar with in the Linux arena. YMMV.

    • rlc says:

      Do you have those scripts published anywhere? I’m thinking of trying FreeBSD for one of my servers..

  9. hotrider says:

    To the poster above who stated “Make sure you have Cpanel installed”, honestly I must disagree at least for myself and my systems . No bloated graphical interface like Cpanel would ever touch one of my personal servers or VPS unless it was an absolute necessity for some obtuse reason and I will tell you why, it’s not just that they are bloated and or have security issues, bugs or don’t interact with the system well etc. Its just to me they offer very little in actual value and that statement increases over time. You see there is a set of tools and skill sets that have been around long before any GUI environment or programs were available and they will still be applicable and ready for use long after every graphical interface you have learned is either completely different, irrelevant or forgotten entirely. And I’m not some old school Unix Guru and I do use graphical interfaces for some purposes, but I can clearly see the value and power in learning the base set of Unix/Linux Utilities and how to interact with a shell and shell scripting, throw in a high level language like Python or Perl and you can pretty much do anything for any system your administrating.

Comments are closed.