Install Nginx, PHP-FPM & MySQL in Centos

21 April 2011 23:39:28 WIB, under category Technical Stuffs
Warning: This shell script will remove your previous Apache installation.
Update June, 25 2014:
The following script works on CentOS 5 very well. If you’re using CentOS 6, go to this page instead:

After reading a tutorial of how to install Nginx, PHP and MySQL in a difficult way, now I would like to tell ya how to install them in a very easy way.

I found this method was very effective and completed just within few minutes in my Centos VPS.

  1. Download  this shell script to your VPS
    [[email protected] ~]# wget
  2. Run that bash script
    [[email protected] ~]# bash

    then wait..

  3. Voila! Nginx, PHP-FPM and MySQL are installed at glance!

Not only that, this shell script also installed a tool to create virtual host in Nginx named setup-vhost.

When I made virtual host for this blog, I just need to run this command:

[[email protected] ~]# setup-vhost

Then I uploaded all my files at /var/www/ and configure database connection etc.

Thanks to you guys at, installing this stack never been easier than this!

8 Comments so far..

  1. Saigana
    28 April 2011, 17:00:36 WIB

    its woooooooork maaaaaaz, tq 😀

  2. Emelie
    01 June 2011, 18:20:50 WIB

    Did it!! thanks a lot!! 🙂

  3. Install Nginx menggunakan Nginxcp |
    21 June 2011, 21:20:13 WIB

    […] “install nginx vps centos” pada mbah gugle menghasilkan banyak hasil, diantaranya ini, ini, ini dan ini. Karena vps sudah terinstall whm aka cpanel, akhirnya memilih mengikuti cara yang […]

  4. Sid
    23 June 2011, 17:13:09 WIB

    Worked fine.

  5. YeuHost
    31 August 2011, 17:20:52 WIB

    Do it include any ftp server?

  6. sandalian
    03 January 2012, 00:51:28 WIB

    I just test it using Centos 6 and failed to work. So I reinstall my VPS using Centos 5.

  7. Ashique Zakariyya
    16 April 2012, 19:27:07 WIB

    i found a working script from this blog, found great, worked for me, i share it to everybody

  8. nass
    25 April 2012, 19:11:34 WIB

    i found a great article while googling , I recommend the article to everybody

RSS for comments TrackBack URL

Leave a comment or two

Allowed tags: <a href="" title=""> <abbr title=""> <acronym title=""> <b> <blockquote cite=""> <cite> <code> <del datetime=""> <em> <i> <q cite=""> <s> <strike> <strong>