LAMP on Fedora 21/20, CentOS/Red Hat (RHEL) 7/6.6/5.11

LAMP (Linux, Apache, MariaDB/MySQL, PHP) server is very powerful server setup behind any website or web based service. This guide is collection of Fedora/CentOS/Red Hat (RHEL), Apache, MariaDB/MySQL and PHP install guides.

Today the Internet is full of instructions, which promises a LAMP server installation with a “One-Liner”, and so forth. In fact, these “One-Liner” instructions assume that, Linux is already installed and installs just AMP (Apache, MariaDB/MySQL, PHP) pakages, without any configuration. AMP programs can be installed with one command easily, of course, but the correct configuration have to be done anyway, especially if the environment is going to production use.

This guide (more specifically this guide parts) try to explain in more detail LAMP (Linux, Apache, MariaDB/MySQL, PHP) server environment installation. This howto can be used to pre-installed Linux, and instructions can be used for various Fedora and Red Hat based Linux distros with YUM. This guide is also usable with setup where MariaDB/MySQL databases and Apache Web servers are on different server machines.

This guide includes three separated steps/guides

Note: Any step can be omitted if something does not want to install.

1. Install Linux (Fedora 21/20/19, CentOS 6.6/5.11, Red Hat 6.6/5.11)

Currently there are 6 different instructions for installing Linux (Fedora 20/19/18, CentOS 7/6.6/5.11 and Red Hat 6.6).

Install Fedora 21 Linux >>

Install Fedora 20 Linux >>

Install Fedora 19 Linux >>

Install CentOS 7 Linux >>

Install CentOS 6.6 Linux >>

Install CentOS 5.11 Linux >>

Install Red Hat (RHEL) 6 Linux >>

2. Install MariaDB 5.5/10.0 or MySQL 5.6

Install MariaDB 5.5/10.0 database server >>

– OR –

Install MySQL 5.6 database server >>

Note: Open MySQL port only when it’s really needed and otherwise use it only locally (localhost)

3. Install Apache (httpd) 2.4 with PHP 5.6

Install latest PHP 5.6 (currently 5.6.4) version.

Install Apache (httpd) web server with PHP support >>

PHP: APC Configuration and Usage Tips and Tricks >>

Enable Apache Userdir with SELinux on Fedora 20/19/18/17, CentOS 6.5/6.4/6.3/6.2/6.1/6/5.10, Red Hat (RHEL) 6.5/6.4/6.3/6.2/6.1/6/5.10 >>

Finally you are done. Not very hard, but at least the most important configurations and checks have been already completed.

Share this post

16 Comments

  1. Great Post!!! :D

    Reply
  2. Thanks! works perfectly

    Reply
  3. Thanks, sets up properly!

    Reply
  4. Is it necessary to install LAMP when using Webmin?

    Reply
    • Hi Kevin,

      You don’t need full LAMP setup to use webmin.

      Just install rpm package, start webmin and it’s working… :)

      Run following (as root):

      Goto https://localhost.localdomain:10000 with your browser and login…

      Reply
      • Thanks so much for the AWESOME advice and tutorial!

        Reply
        • You are welcome! :)

          Reply
  5. Thanks! Just what I was looking for!

    Reply
  6. Thanks a lot Brother !!!!!!!!!!!!!!!! now, I m installing Drupal on fedora 16 !! ;)

    Reply
  7. Thanks a lot, Pal!!
    This post is extremely useful to the less experienced in Linux, just like me.

    Reply
  8. Great post thanks buddy

    Reply
  9. Awesome article! Very helpful and well written. Thanks!

    Reply
  10. Thank you! With this article I was able to test and learn more, now I got a great job because of this, so big thank you!

    Reply
  11. I’m using XAMPP, so how can I uninstall all of this now?

    Reply
  12. Thanks, worked like a charm.
    Does anyone know of a good tutorial on what to do next? I am trying to learn DBs. I have it all installed so the question is “now what?”
    If anyone knows of a good tutorial that would be great

    Reply
    • Hi Paul,

      Okay, you are trying to learn DBs, could you tell in more detail what you want to learn and do with databases?

      Do you want to learn pure SQL or do you want to learn database designing and theory how all things work?

      Reply

Trackbacks/Pingbacks

  1. Ganalot! » Blog Archive » fedora 8 Linux - [...] LAMP (Linux/Apache/MySQL/PHP) on Fedora 13/CentOS 5.5/RHEL 6 [...]
  2. WAMP: Apache 2.2, PHP5 & MySQL Installation Tutorial Windows XP, Vista, 7 - [...] LAMP (Linux/Apache/MySQL/PHP) on Fedora 13/CentOS 5.5/RHEL 6 [...]
  3. Install Wordpress 3.0.1 on Fedora 13, CentOS 5.5, Red Hat (RHEL) 5.5/6 - [...] Install Needed Web and Database Servers1.1 Install the whole LAMP environment with following guideLAMP (Linux/Apache/MySQL/PHP) on Fedora 13/CentOS 5.5/Red …
  4. Install Zend Framework on Fedora 14/13, CentOS/Red Hat (RHEL) 5.5 - [...] 5.1 on Fedora, CentOS, Red Hat (RHEL)1.3 Install the whole LAMP environment with following guideLAMP (Linux/Apache/MySQL/PHP) on Fedora, CentOS …

Submit a Comment

Your email address will not be published. Required fields are marked *

You may use these HTML tags and attributes: <a href="" title=""> <abbr title=""> <acronym title=""> <b> <blockquote cite=""> <cite> <code class="" title="" data-url=""> <del datetime=""> <em> <i> <q cite=""> <strike> <strong> <pre class="" title="" data-url=""> <span class="" title="" data-url="">