pcre

nginx 1源包安装

蓝咒 提交于 2020-01-16 18:09:38
nginx 源包下载网站 http://nginx.org 安装前要检查并卸载HTTPD服务,以防端口冲突 检查HTTPD是否安装 rpm -q httpd 卸载yum -y remove httpd 安装支持软件如下 pcre-devel zlib-devel openssl-devel.x86_64 gcc gcc-c++ make(可以用rpm -q 查看是否安装一下软件) 1建立nginx用户 useradd -M -s /sbin/nologin nginx (-M不建立用户家目录 -s更改登陆的shell) 2解压源码包 tar -xf nginx-1.16.1.tar.gz -C /usr/src 3进入源码包 cd /usr/src/nginx-1.16.1/ 4编译安装ngix ./configure --prefix=/usr/local/nginx --user=nginx --group=nginx --with-http_stub_status_module && make && make install (--with-http_stub_status_module为日志统计模块) 5建立软连接 ln -s /usr/local/nginx/sbin/nginx /usr/local/sbin/ 5查看软连接 ll /usr/local/sbin

## nginx 使用

余生颓废 提交于 2020-01-15 20:34:27
nginx 使用 一、概述 有一个域名,有一台服务器,有多个服务。 为了可以通过域名来访问 服务器上的不同服务,而不将端口 对外 暴露。 采用 nginx 来进行 转发。 二、nginx 安装 不同的操作系统上,需要安装不同的包。 这里以在 centos6.5 上安装为例。 在 官网下载 最新的稳定包。 官网提供的包 需要自行进行 编译。 我想要将第三方包放在 当前我指定的目录下,比如 ~/share Nginx 安装步骤 系统平台:CentOS release 6.6 (Final) 64位。 1 安装编译工具及库文件 yum -y install make zlib zlib-devel gcc-c++ libtool openssl openssl-devel 2 要安装 PCRE PCRE 作用是让 Nginx 支持 Rewrite 功能。 # 1、下载 PCRE 安装包 [root@master ~]# cd ~/share $ wget http://downloads.sourceforge.net/project/pcre/pcre/8.35/pcre-8.35.tar.gz # 2、解压安装包: [root@master share]# tar zxvf pcre-8.35.tar.gz # 3、进入安装包目录 [root@master share]# cd

How do I install pcre with homebrew?

拟墨画扇 提交于 2020-01-15 11:11:55
问题 Background I have a regex I want to run across multiple lines. My understanding is that OSX's grep can't handle this (please correct me if I'm wrong!). So after some Googling I found that PCRE would do what I want. I tried to install it with brew install pcre as a few sites suggested. It seems to have worked. If I run brew install pcre again I get this error Warning: pcre-8.40 already installed and I have a /usr/local/Cellar/pcre/8.40/ directory. Problem After installing PCRE via homebrew I

How do I install pcre with homebrew?

假如想象 提交于 2020-01-15 11:10:20
问题 Background I have a regex I want to run across multiple lines. My understanding is that OSX's grep can't handle this (please correct me if I'm wrong!). So after some Googling I found that PCRE would do what I want. I tried to install it with brew install pcre as a few sites suggested. It seems to have worked. If I run brew install pcre again I get this error Warning: pcre-8.40 already installed and I have a /usr/local/Cellar/pcre/8.40/ directory. Problem After installing PCRE via homebrew I

Regex - Extracting volume and chapter numbers from book titles

六眼飞鱼酱① 提交于 2020-01-15 06:33:10
问题 Hey, I'm trying to import some legacy data into a brand new system, it's almost done, but there's a huge problem! Assuming these kinda data: Blabla Vol.1 chapter 2 ABCD in the era of XYZ volume 2 First Chapter A really useless book Eighth vol Blala Sixth Vol Chapter 5 Lablah V6C7 2002 FooBar Vol6 C3 by Dr. Foo Bar Regex: A tool in Hell V1 Eleventh Chapter Confused!! I tried to write that regex to extract volume and chapter numbers but you know it's REGEX! Can anyone please guide me through

RegEx to validate a comma separated list of options

守給你的承諾、 提交于 2020-01-15 04:22:10
问题 I'm using PHP's Filter Functions (FILTER_VALIDATE_REGEXP specifically) to validate the input data. I have a list of options and the $input variable can specify a number of options from the list. The options are (case-insensitive): all rewards join promotions stream checkin verified_checkin The $input variable can have almost any combination of the values. The possible success cases are: all (value can either be all or a comma separated list of other values but not both) rewards,stream,join (a

RegEx to validate a comma separated list of options

五迷三道 提交于 2020-01-15 04:21:25
问题 I'm using PHP's Filter Functions (FILTER_VALIDATE_REGEXP specifically) to validate the input data. I have a list of options and the $input variable can specify a number of options from the list. The options are (case-insensitive): all rewards join promotions stream checkin verified_checkin The $input variable can have almost any combination of the values. The possible success cases are: all (value can either be all or a comma separated list of other values but not both) rewards,stream,join (a

Nginx 安装配置

♀尐吖头ヾ 提交于 2020-01-14 22:00:00
Nginx 安装配置 Nginx("engine x")是一款是由俄罗斯的程序设计师Igor Sysoev所开发高性能的 Web和 反向代理 服务器,也是一个 IMAP/POP3/SMTP 代理服务器。 在高连接并发的情况下,Nginx是Apache服务器不错的替代品。 Nginx 安装 系统平台:CentOS release 6.6 (Final) 64位。 一、安装编译工具及库文件 yum -y install make zlib zlib-devel gcc-c++ libtool openssl openssl-devel 二、首先要安装 PCRE PCRE 作用是让 Nginx 支持 Rewrite 功能。 1、下载 PCRE 安装包,下载地址: http://downloads.sourceforge.net/project/pcre/pcre/8.35/pcre-8.35.tar.gz [root@bogon src]# cd /usr/local/src/ [root@bogon src]# wget http://downloads.sourceforge.net/project/pcre/pcre/8.35/pcre-8.35.tar.gz 2、解压安装包: [root@bogon src]# tar zxvf pcre-8.35.tar.gz 3

centos上普通用户安装nginx过程

落爺英雄遲暮 提交于 2020-01-13 14:10:47
[dongzw@localhost nginx-1.4.7]$ ./configure --prefix=/home/dongzw/nginx checking for OS + Linux 2.6.32-754.el6.x86_64 x86_64 checking for C compiler ... not found ./configure: error: C compiler cc is not found root用户安装: yum -y install gcc gcc-c++ autoconf automake make ./configure: error: the HTTP rewrite module requires the PCRE library. You can either disable the module by using --without-http_rewrite_module option, or install the PCRE library into the system, or build the PCRE library statically from the source with nginx by using --with-pcre=<path> option. root用户安装: yum -y install zlib

nginx(一)安装并启动服务

一个人想着一个人 提交于 2020-01-12 15:09:59
一、centos安装 1.安装需要的编译工具及库文件 yum -y install make zlib zlib-devel gcc-c++ libtool openssl openssl-devel 2.选择自己项目的路径安装pcre,支持rewrite功能 [root@hmq opt]# wget http://downloads.sourceforge.net/project/pcre/pcre/8.35/pcre-8.35.tar.gz 3.解压并编译pcre [root@hmq opt]# tar zxvf pcre-8.35.tar.gz [root@hmq opt]# cd pcre-8.35 [root@hmq pcre-8.35]# ./configure [root@hmq pcre-8.35]# make && make install 4.查看pcre版本,打印版本则安装成功 [root@hmq pcre-8.35]# pcre-config --version 5.下载nginx安装包,此处版本为1.6.2 [root@hmq opt]# wget http://nginx.org/download/nginx-1.6.2.tar.gz 6.解压及编译,下方配置时 --with 表示安装第三方模块, --prefix 表示编译后的nginx的路径