install nginx on centos6.X
Posted whysz
tags:
篇首语:本文由小常识网(cha138.com)小编为大家整理,主要介绍了install nginx on centos6.X相关的知识,希望对你有一定的参考价值。
确认网络
ping baidu.com
关闭防火墙
service iptables stop
chkconfig iptables off
临时关闭selinux
setenforce 0
基本安装包
yum install -y gcc gcc-c++ autoconf pcre pcre-devel make automake wget httpd-tools vim tree
配置 Nginx 官方 yum 源
[nginx-stable]
name=nginx stable repo
baseurl=http://nginx.org/packages/centos/6/$basearch/
gpgcheck=1
enabled=1
gpgkey=https://nginx.org/keys/nginx_signing.key
安装 Nginx
yum install nginx (查看仓库、查看仓库、查看仓库是否官方 yum,是否时最新稳定版本)
查看 Nginx 当前版本
nginx -v
查看编译参数
nginx -V
查看
rpm -q nginx
rpm -ql nginx
rpm -qc nginx
以上是关于install nginx on centos6.X的主要内容,如果未能解决你的问题,请参考以下文章
How To Install Nginx on CentOS 7(转)
How to Install Nginx with PHP + MySQL (LEMP) on Debian 9
How to install LEMP on centos 6 ( Nginx, PHP, Mysql )
Installing Nginx with PHP (as PHP-FPM) and MariaDB (LEMP) on Debian 8