RHEL 7 安装 ngnix
安装ngnix
yum install -y make apr* autoconf automake curl curl-devel gcc gcc-c++ gtk+-devel zlib-devel pcre-devel
wget http://nginx.org/download/nginx-1.7.2.tar.gz
cd nginx-1.7.2
./configure --prefix=/usr/local/nginx
make && make install
启动 /usr/local/nginx/sbin/nginx
停止 /usr/local/nginx/sbin/nginx -s stop
记得开防火墙80。
出问题看下面内容:
./configure: error: the HTTP rewrite module requires the PCRE library解决
有时候,我们需要单独安装nginx,来处理大量的下载请求。
安装nginx遇到的rewrite和HTTP cache错误解决办法:
./configure --prefix=/usr/local/nginx
安装Nginx时报错
./configure: error: the HTTP rewrite module requires the PCRE library.
安装pcre-devel解决问题
yum -y install pcre-devel
错误提示:./configure: error: the HTTP cache module requires md5 functions
from OpenSSL library. You can either disable the module by using
--without-http-cache option, or install the OpenSSL library into the system,
or build the OpenSSL library statically from the source with nginx by using
--with-http_ssl_module --with-openssl= options.
解决办法:
yum -y install openssl openssl-devel
总结:
yum -y install pcre-devel openssl openssl-devel
./configure --prefix=/usr/local/nginx
make
make install
配置PHP-FPM/fast-cgi
yum -y install libxml2-devel openssl-devel curl-devel libjpeg-devel libpng-devel freetype-devel openldap-devel mysql-devel libtool-ltdl-devel
wget http://ftp.gnu.org/pub/gnu/libiconv/libiconv-1.13.1.tar.gz
tar zxvf libiconv-1.13.1.tar.gz
cd libiconv-1.13.1
./configure
make && make install
wget http://nchc.dl.sourceforge.net/project/mcrypt/Libmcrypt/2.5.8/libmcrypt-2.5.8.tar.gz
tar zxvf libmcrypt-2.5.8.tar.gz
cd libmcrypt-2.5.8/
./configure
make && make install
/sbin/ldconfig
wget
http://nchc.dl.sourceforge.net/project/mhash/mhash/0.9.9.9/mhash-0.9.
9.9.tar.gz
tar zxvf mhash-0.9.9.9.tar.gz
cd mhash-0.9.9.9/
./configure
make
make install
cd ../
ln -s /usr/local/lib/libmcrypt.* /usr/lib/ (是否为rpm 包安装)
ln -s /usr/local/lib/libmhash.* /usr/lib/ (是否为rpm 包安装)
http://nchc.dl.sourceforge.net/project/mcrypt/MCrypt/2.6.8/mcrypt-2.6.8.tar.gz
tar zxvf mcrypt-2.6.8.tar.gz
cd mcrypt-2.6.8/
/sbin/ldconfig
./configure
make
make install
cd ../
wget http://cn2.php.net/distributions/php-5.5.13.tar.gz
cd php-5.5.13
./configure --with-mysql --with-mysql-sock=/var/lib/mysql/mysql.sock --with-mysql --with-mysqli=/usr/bin/mysql_config --with-iconv=/usr/local --with-freetype-dir --with-jpeg-dir
--with-png-dir --with-zlib --with-libxml-dir=/usr --enable-xml --disable-rpath --enable-discard-path --enable-safe-mode --enable-bcmath --enable-shmop --enable-sysvsem --
enable-inline-optimization --with-curl --with-curlwrappers --enable-mbregex --enable-mbstring --with-mcrypt --with-gd --enable-gd-native-ttf --with-openssl --with-mhash --
enable-pcntl --enable-sockets --with-xmlrpc --enable-zip --enable-soap --with-pdo-mysql --without-pear --enable-fastcgi --enable-force-cgi-redirect --enable-fpm
make && make install
RHEL 7 安装 ngnix的更多相关文章
- 在CentOS或RHEL上安装Nux Dextop仓库
介绍 Nux Dextop是类似CentOS.RHEL.ScientificLinux的第三方RPM仓库(比如:Ardour,Shutter等等).目前,Nux Dextop对CentOS/RHEL ...
- ubuntu14.04下安装ngnix,mediawiki,nodebb,everything,gitlab
本周折腾了以下几个东西,mediawiki(维基),nodebb(论坛),gitlab(私有git服务器). 本来的目的是搭建一个wiki,选用了mediawiki后,使用apache搭建好了. 搭论 ...
- 在RHEL上安装Thrift(支持C++)的若干问题 » 编码无悔 / Intent & Focused
在RHEL上安装Thrift(支持C++)的若干问题 » 编码无悔 / Intent & Focused [原创]在RHEL上安装Thrift(支持C++)的若干问题 2010年12月1 ...
- Red Hat Enterprise Linux Server(RHEL) yum安装软件时This system is not registered with RHN. RHN support will be disabled. 的解决方法(转)
新安装了redhat6.5.安装后,登录系统,使用yum update 更新系统.提示: This system is not registered to Red Hat Subscription M ...
- RHEL自动安装zookeeper的shell脚本
RHEL自动安装zookeeper的shell脚本 A:本脚本运行的机器,Linux RHEL6 B,C,D,...:待安装zookeeper cluster的机器, Linux RHEL6 首先在脚 ...
- RHEL/CentOS 安装最新版Nginx
本篇简单介绍如何在RHEL/CentOS安装最新版本的Nginx. Step 1:安装yum-utils [root@localhost ~]# cat /etc/redhat-release Cen ...
- Linux(Centos7)安装ngnix服务器
Ngnix服务器是一款优秀的静态页服务器软件和反向代理服务器软件 目前,centos安装ngnix可以yum安装也可以下载安装,我们为了扩展方便,选择下载安装.yum一键安装没什么好说的. 一.安装编 ...
- 理解RHEL上安装oracle的配置参数
无论安装什么版本的oracle,在安装之前,都需要配置 /etc/pam.d/login /etc/profile /etc/security/limits.conf这三个文件 那这三个文件究 ...
- RHEL 5 安装phpqrcode生成二维码
VMWARE中全新安装(默认)RHEL. 之后,yum 安装备apache/php 下载并上传phpqrcode 1.1.4版本,并将其解压至/var/www/html/phpqrcode (去掉ip ...
随机推荐
- Android初体验-D3
1. UI界面布局. (即可用XML控制布局也可采用Java代码布局,不过在实际应用中是两者混合控制UI界面,为什么呢,因为XML适用于固定的不易改变的组件布局,Java程序控制常变的组件...其控制 ...
- MM/PP/SD/FICO 模块常用事物码(T-code)、SAP快捷键
MM/PP/SD/FICO MM常用T-CODE MM01 创建一般物料 Create Material – GeneralMM02 修改一般物料 Change MaterialMM03 显示一般物料 ...
- Android 百度语音合成集成
一.环境配置: 下载资料:http://ai.baidu.com/sdk 官方视频讲解:http://ai.baidu.com/support/video 接入指南:http://ai.baidu.c ...
- 【spring boot logback】spring boot中logback日志乱码问题
在初次使用logback的自定义配置文件完整的控制spring boot日志后,发现了一个无法忍受的问题,就是日志乱码. 控制台看到打印日志乱码如下: 而日志文件打开: 记事本打开 sublime打开 ...
- EasyPlayer-RTSP-Android安卓播放器播放RTSP延迟优化策略,极低延时!
EasyPlayer-RTSP-Android安卓RTSP播放器低延迟播放延时优化策略 EasyPlayer-RTSP-Android播放器是一款专门针对RTSP协议进行过优化的流媒体播放器,其中我们 ...
- xampp怎么操作数据库mysql
1.打开软件的主界面,打开Apache和MySQL,然后点击MySQL后面的admin.且我操作时,Apache,MySQL要启动,才打的开. 2.打开MySQL,报错. 09:00:23 [mysq ...
- 第六课作业——主从复制和sentinel高可用
第六课时作业 静哥 by 2016.3.21~2016.4.3 [作业描述] 1.配置主从复制,截图看日志 2.配置一个哨兵,一主一从结构,并实现主宕机从接管的过程,截图显示 3.总结哨兵的原理 ...
- Time-series Storage Layer Time Series Databases 时间序列
w 关于时间序列数据库的思考-CSDN.NET http://www.csdn.net/article/2015-07-13/2825192 存储和处理时间序列数据(“Time Series Da ...
- unity坑faq
遇到的坑记录下来,大都都是听说,没有实测 1. Graphics.copyTexture,在某些机型上不支持从不同类型拷贝 2. msaa 小米mix2不支持,晓龙845 3. android4.2下 ...
- python多线程与多进程的区别
在UNIX平台上,当某个进程终结之后,该进程需要被其父进程调用wait,否则进程成为僵尸进程(Zombie).所以,有必要对每个Process对象调用join()方法 (实际上等同于wait).对于多 ...