nginx应用编译安装:

  • 安装编译所需依赖包:
# apt-get install make gcc g++ libcurl3-openssl-dev libfreetype6-dev libmcrypt-dev
# apt-get install libpcre3 libpcre3-dev zlib1g-dev libssl-dev build-essential
# apt-get install openssl libssl-dev
  • 编译nginx:(无用户)
# cd /usr/local/src
# wget http://nginx.org/download/nginx-1.8.0.tar.gz
# tar -zxvf nginx-1.8.0.tar.gz
# cd nginx-1.8.0/
# ./configure --prefix=/Sioeye/SioApps/Environment/nginx --with-http_ssl_module --with-http_realip_module --with-http_stub_status_module --with-http_gzip_static_module --with-pcre
# make && make install
# ln -sv /Sioeye/SioApps/Environment/nginx/sbin/nginx /etc/init.d/nginx
# mv /home/pengchuan/nginx /etc/init.d/ ### /home/pengchuan/nginx为上传的nginx启动文件
# chmod a+x /etc/init.d/nginx
# update-rc.d nginx defaults
# vim /etc/rc.local
/etc/init.d/nginx
exit 0
# chmod a+x /etc/rc.local
  • 编译nginx:(有用户)
# useradd -s /usr/sbin/nologin -r nginx
# cd /usr/local/src
# wget http://nginx.org/download/nginx-1.8.0.tar.gz
# tar -zxvf nginx-1.8.0.tar.gz
# cd nginx-1.8.0/
# ./configure --prefix=/Sioeye/SioApps/Environment/nginx --with-http_ssl_module --user=nginx --group=nginx --with-http_realip_module --with-http_stub_status_module --with-http_gzip_static_module --with-pcre
# make && make install
# ln -sv /Sioeye/SioApps/Environment/nginx/sbin/nginx /etc/init.d/nginx
# update-rc.d nginx defaults 99
  • 修改配置文件
# vi nginx.conf

nginx应用编译安装的更多相关文章

  1. Nginx 的编译安装和URL地址重写

    本文转自:http://www.178linux.com/14119#rd?sukey=ecafc0a7cc4a741b573a095a3eb78af6b4c9116b74d0bbc9844d8fc5 ...

  2. nginx的编译安装以及启动脚本编写

    Nginx的编译安装和启动脚本的编写 Nginxd的功能强大,可以实现代理.负载均衡等企业常用的功能.下面介绍一下nginx的编译安装方法: 1. 下载 官方下载地址:http://nginx.org ...

  3. 初识Nginx及编译安装Nginx

    初识Nginx及编译安装Nginx 环境说明: 系统版本    CentOS 6.9 x86_64 软件版本    nginx-1.12.2 1.什么是Nginx? 如果你听说或使用过Apache软件 ...

  4. 【01】Nginx:编译安装/动态添加模块

    写在前面的话 说起 Nginx,别说运维,就是很多开发人员也很熟悉,毕竟如今已经 2019 年了,Apache 更多的要么成为了历史,要么成为了历史残留. 我们在提及 Nginx 的时候,一直在强调他 ...

  5. 【nginx运维基础(1)】Nginx的编译安装与使用

    nginx的官方手册: http://nginx.org/en/docs/ 编译安装 下载地址: http://nginx.org/en/download.html # 为了支持rewrite功能,我 ...

  6. Nginx服务编译安装、日志功能、状态模块及访问认证模式实操

    系统环境 [root@web ~]# cat /etc/redhat-release CentOS release 6.9 (Final) [root@web ~]# uname -a Linux d ...

  7. Nginx的编译安装及选项

    编译安装Nginx1.安装常见的工具和库(GCC.PCRE.zlib.OpenSSL) Nginx是一个由C语言编写的,所以需要一个编译工具如GNU的GCC[root@www ~]# yum inst ...

  8. Nginx之编译安装的nginx加入systemctl

    编译安装的nginx需要添加rc.local 编译安装后设置 /usr/lib/systemd/system/nginx.service [Unit] Description=nginx After= ...

  9. nginx之编译安装

    一.认识nginx 常用的web服务有Apache.IIS(windows系统).Lighttpd.Tomcat.Nginx等.Nginx是一个开源的,支持高性能.高并发的www服务和代理服务软件.它 ...

随机推荐

  1. spoj-ASSIGN-bitDP

    ASSIGN - Assignments #dynamic-programming Problem Your task will be to calculate number of different ...

  2. 4666 Hyperspace stl

    当时自己做的时候没有这么想,想的是每个象限去找一个无穷值来作为比较点.但是很麻烦 代码: #include <stdio.h> #include <string.h> #inc ...

  3. day31 堡垒机尾声 + Python与金融量化分析(一)

    堡垒机尾声: 代码案例:https://github.com/liyongsan/git_class/tree/master/day31 课堂笔记:file send: 1.选择本地文件 2.远程路径 ...

  4. Apache编译安装

    1.准备好源码包并配置好yum源,需要的源码包包括:httpd-2.4.18.apr-1.5.2.tar.gz.apr-util-1.5.4.tar.gz 2.准备用户 groupadd -r apa ...

  5. 高射炮打蚊子丨用Visual Studio 2017写最初级的C语言程序

    众所周知,Visual Studio号称全宇宙最强的IDE(集成开发环境),简直可以“秒天秒地秒空气”.我们看着各种技术大会上,大神们在台上用VS演示Demo溜得飞起,然而对于一些非技术专业同学或者是 ...

  6. hdu 6113 度度熊的01世界(结构体的赋值问题)

    题目大意: 输入n*m的字符串矩形,判断里面的图形是1还是0,还是什么都不是 注意:结构体中放赋值函数,结构体仍旧能定义的写法 #include <iostream> #include&l ...

  7. python3 快速排序

    思路 第一步:找到一个随机的数,一般都是第一个数,也就是left,递归中也用left,放到缓存中,专业叫 基准值,基准值是要放在中间的. 第二步:最左边空出一个位置就是索引left的位置,所以从右向左 ...

  8. LeetCode OJ:Merge Intervals(合并区间)

    Given a collection of intervals, merge all overlapping intervals. For example,Given  [1,3],[2,6],[8, ...

  9. djagno重写authenticate实现帐号和邮箱的多方式登录。

    1.在users应用的view中重写authenticate: from django.contrib.auth.backends import ModelBackend from django.db ...

  10. qml 知识积累

    本文仅仅只是记录,怕日后遗忘. ListView相关应用 https://www.cnblogs.com/SaveDictator/p/8192391.html ListView 清空操作 https ...