1.首先安裝編譯用到的包 yum-yinstallgccgcc-c++ yum-yinstallzlibzlib-developensslo">

手机看片精品高清国产日韩,色先锋资源综合网,国产哺乳奶水91在线播放,乱伦小说亚洲色图欧洲电影

如何源碼安裝nginx

2016-03-17 17:24:36 10770

1.首先安裝編譯用到的包

yum -y install gcc gcc-c++

yum -y install zlib zlib-devel openssl openssl-devel pcre-devel

2.建立用戶和組 

groupadd -r nginx

useradd -s /sbin/nologin -g nginx -r nginx

id nginx

     

3.下載解壓nginx.org

4.設(shè)置參數(shù)

./configure --prefix=/usr/local/nginx --pid-path=/var/run/nginx/nginx.pid --lock-path=/var/lock/nginx.lock --user=nginx --group=nginx --with-http_ssl_module --with-http_flv_module --with-http_stub_status_module --with-http_gzip_static_module --http-client-body-temp-path=/var/tmp/nginx/client/ --http-proxy-temp-path=/var/tmp/nginx/proxy/ --http-fastcgi-temp-path=/var/tmp/nginx/fcgi/ --http-uwsgi-temp-path=/var/tmp/nginx/uwsgi --http-scgi-temp-path=/var/tmp/nginx/scgi --with-pcre

5.編譯和安裝:make && make install

多線程編譯安裝:make -j `cat /proc/cpuinfo | grep processor| wc -l` && make install

提交成功!非常感謝您的反饋,我們會繼續(xù)努力做到更好!

這條文檔是否有幫助解決問題?

非常抱歉未能幫助到您。為了給您提供更好的服務(wù),我們很需要您進一步的反饋信息:

在文檔使用中是否遇到以下問題: