Linux 源码安装nginx
编译参数详解:https://www.cnblogs.com/houyongchong/p/compileArgs.html
配置参数详解:https://www.cnblogs.com/houyongchong/p/configureArgs.html
安装扩展、依赖包
tar -zxf LuaJIT-2.0..tar.gz -C /usr/local/src/
cd LuaJIT-2.0./
make
make install
export LUAJIT_LIB=/usr/local/lib
export LUAJIT_INC=/usr/local/include/luajit-2.0 tar -zxf nginx-sticky-module-1.1.tar.gz -C /usr/local/src/ tar -zxf ngx_cache_purge-2.3.tar.gz -C /usr/local/src/ tar xf pcre-8.40.tar.gz -C /usr/local/src/ tar -zxf lua-nginx-module-0.10..tar.gz -C /usr/local/src/ tar -zxf nginx_upstream_check_module-0.3..tar.gz -C /usr/local/src/ tar -zxf ngx_devel_kit-0.3..tar.gz -C /usr/local/src/ tar -zxf set-misc-nginx-module-0.31.tar.gz -C /usr/local/src/ tar -zxf openssl-1.0.2l.tar.gz -C /usr/local/src/ tar -zxf zlib-1.2..tar.gz -C /usr/local/src/ unzip nginx-upstream-fair-master.zip
mv nginx-upstream-fair-master /usr/local/src/ chown -R root.root /local/src/
安装nginx
useradd -M -s /sbin/nologin nginx
tar -zxf nginx-1.10..tar.gz
chown -R root.root ./nginx-1.10.
cd nginx-1.10.
./configure \
--prefix=/app/nginx \
--conf-path=/app/nginx/conf/nginx.conf \
--sbin-path=/app/nginx/sbin/nginx \
--http-log-path=/app/nginx/logs/access.log \
--error-log-path=/app/nginx/logs/error.log \
--pid-path=/app/nginx/logs/nginx.pid \
--lock-path=/app/nginx/logs/nginx.lock \
--with-ld-opt=-Wl,-rpath,/usr/local/lib \
--with-pcre=/usr/local/src/pcre-8.42 \
--with-zlib=/usr/local/src/zlib-1.2. \
--with-openssl=/usr/local/src/openssl-1.0.2n \
--add-module=/usr/local/src/nginx_upstream_check_module-0.3. \
--add-module=/usr/local/src/nginx-sticky-module \
--add-module=/usr/local/src/nginx-upstream-fair-master \
--add-module=/usr/local/src/ngx_cache_purge-2.3 \
--add-module=/usr/local/src/lua-nginx-module-0.10. \
--add-module=/usr/local/src/ngx_devel_kit-0.3. \
--add-module=/usr/local/src/set-misc-nginx-module-0.32 \
--with-http_addition_module \
--with-http_dav_module \
--with-http_flv_module \
--with-http_gzip_static_module \
--with-http_realip_module \
--with-http_stub_status_module \
--with-http_ssl_module \
--user=nginx \
--group=nginx
make
make install
chown -R nginx.nginx /app/nginx
Linux 源码安装nginx的更多相关文章
- linux源码安装nginx
任务目标:源码安装nginx,作为web服务修改配置文件,让配置生效,验证配置 首先要去官网nginx.org下载一个tar包: tar xvf 解包 进入到解包出来的目录,对configure进行配 ...
- 1.linux源码安装nginx
从官网下载nginx.tar.gz源码包 拷贝至Linux系统下进行解压 tar -zxvf nginx.tar.gz 进入解压后的目录,需要./configure,此步骤会报多个错,比如没有安装gc ...
- linux 源码安装 Nginx
1.安装前环境准备安装make:# yum -y install gcc automake autoconf libtool make安装g++:# yum install gcc gcc-c++ 2 ...
- Linux之源码安装nginx,并按照作业一描述的那样去测试使用
作业五:源码安装nginx,并按照作业一描述的那样去测试使用 [root@localhost nginx]# yum install gcc-* glibc-* openssl openssl-dev ...
- 源码安装nginx以及平滑升级
源码安装nginx以及平滑升级 ...
- Linux源码安装JDK1.8
Linux源码安装Java 1.到官网下载 jdk-8u131-linux-x64.tar.gz 官网地址:http://www.oracle.com/technetwork/java/javase/ ...
- 源码安装Nginx以及用systemctl管理
一.源码安装Nginx: 先安装gcc编译器(安装过的可以忽略) [root@localhost ~]# yum -y install gcc gcc-c++ wget 进入src目录 [root@l ...
- mysql-5.5 for linux源码安装
mysql-5.5 for linux源码安装 1.使用Yum安装依赖软件包 # yum install -y gcc gcc-c++ gcc-g77 autoconf automake bison ...
- 工作笔记-- 源码安装nginx
源码安装nginx 1.安装nginx的依赖包 [root@localhost ~]# yum -y install gcc gcc-c++ openssl openssl-devel pcre pc ...
随机推荐
- YII2-按需加载并管理静态资源(CSS,JS)
参考博客: https://segmentfault.com/a/1190000003742452#articleHeader5
- Docker容器入门篇
第1章 Docker简介 1.1 Docker容器介绍 Docker官网:https://www.docker.com/ 什么是docker? Docker 最初是 dotCloud 公司创始人 So ...
- 移动端css适配
/* iphoneX.iphoneXs */ @media only screen and (device-width: 375px) and (device-height: 812px) and ( ...
- 查看 SharePoint Server 中的所有网站集
网站集是具有同一所有者并共享管理设置(例如权限和配额)的一组网站.网站集是在 Web 应用程序中创建的.创建网站集时,将自动在网站集中创建一个首要网站.然后,可以在首要网站下创建一个或多个子网站.首要 ...
- grub命令行和配置文件配置配置信息
一.grub简介 GNU GRUB(简称“GRUB”)是一个来自GNU项目的启动引导程序.GRUB是多启动规范的实现,它允许用户可以在计算机内同时拥有多个操作系统,并在计算机启动时选择希望运行的操作系 ...
- sysbench0.4.12测试query_cache_size和query_cache_type
建议: query_cache_size和query_cache_type生产环境中关闭. (1)软件包下载地址: https://dev.mysql.com/downloads/benchmarks ...
- maven项目pom.xml中parent标签的使用(转)
原文地址:https://blog.csdn.net/qq_41254677/article/details/81011681 使用maven是为了更好的帮项目管理包依赖,maven的核心就是pom. ...
- Codeforces Round #451 (Div. 2) [ D. Alarm Clock ] [ E. Squares and not squares ] [ F. Restoring the Expression ]
PROBLEM D. Alarm Clock 题 OvO http://codeforces.com/contest/898/problem/D codeforces 898d 解 从前往后枚举,放进 ...
- hdu 6078 Wavel Sequence
题 OvO http://acm.hdu.edu.cn/showproblem.php?pid=6078 (2017 Multi-University Training Contest - Team ...
- Tiling_easy version
Tiling_easy version 思路:关于dp这种东西,有一点必须要想明白,就是状态与状态之间的转换关系,就比如说要求5个骨牌的方案数,因为有两种骨牌,那么可以用dp[3]+两个横着的骨牌或者 ...