Nginx: Nginx下设置伪静态方法与Apache差不多,直接在nginx.conf (或者在对应的*.conf) 中找到需设置伪静态规则的服务器对应字段,在server{ location/{ } }中添加以下代码: server { listen 80 default_server; server_name _; location / { root /usr/share/nginx/html; index index.html index.htm; rewrite ^(.*)list-([0-9]+)-([0-9]+).html$ $1list.php?page=$2&id=$3; …
2016-04-27 13:30
一、配置防火墙,开启80端口、3306端口 CentOS 7.0默认使用的是firewall作为防火墙,这里改为iptables防火墙。 1、关闭firewall: #停止firewall服务 systemctl stop firewalld.service #禁止firewall开机启动 systemctl disable firewalld.service 2、安装iptables防火墙 #安装 yum install iptables-services #编辑防火墙配置文件 vi /etc/sysconfig/iptables Firewall configuration writte…
2016-02-23 16:39