Simple deployment of RockMongo and centerosrockmongo in CenterOS

Source: Internet
Author: User
Tags php mongodb

Simple deployment of RockMongo and centerosrockmongo in CenterOS

Using Mongodb makes it very convenient to debug Query, View Collection, and other States with Rockmongo.

The deployment of Rockmongo is studied, mainly for web servers dependent on the PHP environment. Currently, there are two types of servers: httpd and nginx,

Both servers need to be deployed in the PHP environment. One is to compile and deploy the PHP environment through the source code. Various dependencies are complex, and various pecl phpize methods are used, one is to use yum for deployment, which is relatively simple and not prone to errors.

The procedure is as follows:

1. Related Basic compilation Dependencies

yum -y install gcc automake autoconf libtool makeyum -y install gcc gcc-c++ glibcyum -y install libmcrypt-devel mhash-devel libxslt-devel \libjpeg libjpeg-devel libpng libpng-devel freetype freetype-devel libxml2 libxml2-devel \zlib zlib-devel glibc glibc-devel glib2 glib2-devel bzip2 bzip2-devel \ncurses ncurses-devel curl curl-devel e2fsprogs e2fsprogs-devel \krb5 krb5-devel libidn libidn-devel openssl openssl-devel

2. Compile the PHP environment and fpm (FastCGI Process Management)

yum -y install phpyum -y install php-fpm

Verify

php -v php -i |grep exten

Start fpm FastCGI Process Management

php-fpm -D

3. Configure nginx

location ~ \.php$ {            fastcgi_pass   127.0.0.1:9000;            fastcgi_index  index.php;            fastcgi_param  SCRIPT_FILENAME  $document_root$fastcgi_script_name;            include        fastcgi_params;        }

In this case, you can add index. php to test whether php fastcgi is successful.

Create the index. php file in/usr/local/nginx/html and enter the following content:

<?php    echo phpinfo?>

You can see the address of the php. ini file. If you cannot see the address, place the php. ini file to the directory specified on the page.

4. Add the php_mongo driver

yum install php-pecl-mongo

Add/etc/php. ini

extension=mongo.so

5. Move rockmongo to the nginx web directory and install it.

 

References:

Install and configure nginx php-fpm

Http://www.nginx.cn/231.html

Configure 6.5 yum source for CentOS 163

Http://maitianli.blog.51cto.com/8538087/1357070

Install PHP MongoDB (mongo) Driver on Linux, Mac OS X, Windows, UNIX, BSD

Http://www.if-not-true-then-false.com/2010/install-php-mongodb-mongo-driver-on-linux-mac-os-x-windows-unix-bsd/

-Bash: phpize: command not found on Centos 6

Http://unix.stackexchange.com/questions/117966/bash-phpize-command-not-found-on-centos-6

How to forcibly uninstall PHP and customize PHP installation in centOS

Http://blog.csdn.net/21aspnet/article/details/6581618

 




Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.