我在我的弹性beanstalk web应用程序中得到504错误后60秒,所以我已经实现了超时扩展更改的配置文件/etc/nginx/nginx.conf,以及设置类型_哈希_最大_大小为1024根据错误日志。是否有任何其他错误日志,我应该检查我的AWS示例或我实现的更改不正确?
下面是我添加的nginx配置:
#Elastic Beanstalk Nginx Configuration File
user nginx;
error_log /var/log/nginx/error.log warn;
pid /var/run/nginx.pid;
worker_processes auto;
worker_rlimit_nofile 200000;
events {
worker_connections 1024;
}
http {
server_tokens off;
include /etc/nginx/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"';
include conf.d/*.conf;
map $http_upgrade $connection_upgrade {
default "upgrade";
}
server {
listen 80 default_server;
access_log /var/log/nginx/access.log main;
client_header_timeout 90;
client_body_timeout 90;
keepalive_timeout 90;
proxy_connect_timeout 90;
proxy_send_timeout 90;
proxy_read_timeout 90;
send_timeout 90;
types_hash_max_size 1024;
gzip off;
gzip_comp_level 4;
gzip_types text/plain text/css application/json application/javascript application/x-javascript text/xml application/xml application/xml+rss text/javascript;
# Include the Elastic Beanstalk generated locations
include conf.d/elasticbeanstalk/*.conf;
}
}
字符串
这是日志中出现的错误
[warn] 13416#13416: could not build optimal types_hash, you should increase either types_hash_max_size: 1024 or types_hash_bucket_size: 64; ignoring types_hash_bucket_size
型
1条答案
按热度按时间hfwmuf9z1#
基于你的错误,我会努力改变
字符串
试试看吧,晚了我知道你还是犯了错误。