Home >Backend Development >PHP Tutorial >Common nginx extension installation

Common nginx extension installation

WBOY
WBOYOriginal
2016-08-08 09:29:211352browse

1. Install drizzle1.0:

wget http://agentzh.org/misc/nginx/drizzle7-2011.07.21.tar.gz
cd drizzle7-2011.07.21/
./configure --without-server 
make libdrizzle-1.0
make install-libdrizzle-1.0
modify /etc/profile, add the following two lines, or directly execute the following two sentences
export LIBDRIZZLE_INC=/usr/local/include/libdrizzle-1.0
export LIBDRIZZLE_LIB=/usr/local/lib

2. Download and unzip rds-json-nginx-module
wget https://github.com/openresty/rds-json-nginx-module/archive/v0.13.tar.gz
tar -zxvf v0.13.tar.gz

3. Download and unzip drizzle-nginx-module
wget https://github.com/openresty/drizzle-nginx-module/archive/master.zip
unzip master.zip
mv master.zip drizzle-nginx-module-master.zip
mv drizzle-nginx-module-master drizzle-nginx-module	

4. Download and unzip redis2-nginx-module
wget https://github.com/openresty/redis2-nginx-module/archive/master.zip
unzip master.zip
mv master.zip redis2-nginx-module-master.zip
mv redis2-nginx-module-master redis2-nginx-module

Download and unzip set-misc-nginx-module (unknown directive "set_unescape_uri")
wget https://github.com/openresty/set-misc-nginx-module/archive/v0.28.tar.gz
tar -zxvf v0.28.tar.gz

Download and Compile lua-cjson (module 'cjson' not found)
wget http://www.kyne.com.au/~mark/software/download/lua-cjson-2.1.0.tar.gz	
tar -zxvf lua-cjson-2.1.0.tar.gz
cd lua-cjson-2.1.0
Modify the Makefile in the current directory and assign the LUA_INCLUDE_DIR value to $(PREFIX)/include/luajit-2.0
make
make install

Download and compile lua-redis-parser-0.10. tar.gz (module 'redis.parser' not found)
wget https://github.com/openresty/lua-redis-parser/archive/master.zip
mv master.zip lua-redis-parser-master.zip
unzip lua-redis-parser-master.zip 
cd lua-redis-parser-master

Modify the Makefile in the current directory and assign the LUA_INCLUDE_DIR value to $(PREFIX)/include/luajit-2.0
make && make install

4. Recompile nginx
<pre name="code" class="html">cd /data0/source_code/nginx-1.4.2  

./configure  --user=www --group=www --prefix=/data0/nginx-1.4.2 --with-http_stub_status_module --with-pcre=/data0/source_code/pcre-8.33/ --add-module=/data0/source_code/ngx_devel_kit-0.2.18  --add-module=/data0/source_code/echo-nginx-module-0.57 --add-module=/data0/source_code/lua-nginx-module-0.8.6  --add-module=/data0/source_code/rds-json-nginx-module-0.13 --add-module=/data0/source_code/drizzle-nginx-module --add-module=/data0/source_code/redis2-nginx-module --add-module=/data0/source_code/set-misc-nginx-module-0.28

make -j2

make install


After completion, you can execute objs/nginx -V in the current directory to see if all the modules that should be installed are installed, as follows:

objs/nginx -V

The above introduces the common nginx extension installation, including the relevant content. I hope it will be helpful to friends who are interested in PHP tutorials.

Statement:
The content of this article is voluntarily contributed by netizens, and the copyright belongs to the original author. This site does not assume corresponding legal responsibility. If you find any content suspected of plagiarism or infringement, please contact admin@php.cn