nginx-log ulimit

worker_processes  auto;
配置error log路径
error_log  /data/nginx_logs/error.log warn;
配置access log路径
    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  /data/nginx_logs/access.log  main;

worker_connections  10240; 需要修改ulimit值,默认1024
vim /etc/security/limits.conf
* soft nofile 65535
* hard nofile 65535
重启生效
posted @ 2020-02-21 11:15  kylingx  阅读(156)  评论(0编辑  收藏  举报