nginx.conf配置
来源:互联网 发布:4g网络哪家强 编辑:程序博客网 时间:2024/06/05 00:10
- 路径:
- yum安装:/etc/nginx/nginx.conf
- 非yum安装:/usr/local/conf/nginx.conf
- nginx.conf配置
#user nobody;
worker_processes 2;
#error_log logs/error.log;
#error_log logs/error.log notice;
error_log logs/error.log info;
#pid logs/nginx.pid;
events {
worker_connections 1024;
}
http {
include mime.types;
default_type application/octet-stream;
#log_format main '$remote_addr - $remote_user [$time_local] "$request" '
# '$status $body_bytes_sent "$http_referer" '
# '"$http_user_agent" "$http_x_forwarded_for"';
#access_log logs/access.log main;
sendfile on;
tcp_nopush on;
#keepalive_timeout 0;
keepalive_timeout 65;
#gzip on;
upstream 192.168.92.131{
#ip_hash;
server 192.168.92.131:8080 weight=1;
server 192.168.92.131:8180 weight=1;
}
server {
listen 80;
server_name 192.168.92.131;
#charset koi8-r;
#access_log logs/host.access.log main;
location / {
root html;
index index.html index.htm;
proxy_pass http://192.168.92.131;
proxy_connect_timeout 10;
proxy_redirect default;
}
}
}
- 在Tomcat的lib中添加Redis的jar包:
tomcat-redis-session-manager1.2.jar
commons-pool2-2.0.jar
jedis-2.5.2.jar
- 在Tomcat的server.xml中配置文件<Context>标签中添加
<Context>
<Valve className="com.orangefunction.tomcat.redissessions.RedisSessionHandlerValve" />
<Manager className="com.orangefunction.tomcat.redissessions.RedisSessionManager"
host="127.0.0.1"
port="6379"
database="0"
maxInactiveInterval="60" />
</Context>
0 0
- Nginx conf/nginx.conf配置
- Nginx-配置-nginx.conf
- nginx nginx.conf 配置
- nginx.conf配置说明
- nginx.conf配置详解
- Nginx配置conf
- Nginx.conf 配置小结
- nginx.conf 配置详解
- nginx配置www.conf
- nginx.conf配置说明
- nginx.conf配置
- nginx.conf配置参考
- nginx.conf的配置
- nginx中conf配置
- nginx.conf配置详解
- nginx conf location 配置
- nginx.conf配置
- nginx.conf配置
- 支持向量机(SVM)必备知识(KKT、slater、对偶)
- 对于设计模式的理解
- Can you answer these queries? hdu 4027
- python爬虫(14)获取淘宝MM个人信息及照片(上)
- android 自定义控件系列之一 圆形图控件
- nginx.conf配置
- NavigationView
- c#编写dll 供其他语言调用问题
- hibernate工作原理及作用
- 测试IE浏览器版本
- 阿里OSS API总结
- Hadoop高可用集群搭建(HA)
- java运行环境的配置以及JAVA运行机制(java虚拟机)
- php curl批处理--可控并发异步