gpt4 book ai didi

linux - nginxadmin 1 上游 cpanel 超时

转载 作者:太空宇宙 更新时间:2023-11-04 03:43:45 26 4
gpt4 key购买 nike

我已经在新安装的 cpanel vps 上安装了 nginxadmin。当我尝试登录域时出现 504 超时。这是我的日志和配置。

日志--------------------

2015/03/06 16:58:25 [错误] 31665#0:*1 连接到上游时上游超时(110:连接超时),客户端:151.225.179.242,服务器:lyntouch.com,请求:“GET/HTTP/1.1”,上游:“http://149.210.164.212:8081/”,主机:“lyntouch.com”

配置-------------------------- nginx.conf

user  nobody;
# no need for more workers in the proxy mode
worker_processes auto;
error_log /var/log/nginx/error.log warn;
worker_rlimit_nofile 20480;
events {
worker_connections 5120; # increase for busier servers
use epoll; # you should use epoll here for Linux kernels 2.6.x
}
http {
server_name_in_redirect off;
server_names_hash_max_size 10240;
server_names_hash_bucket_size 1024;
include mime.types;
default_type application/octet-stream;
server_tokens off;
# remove/commentout disable_symlinks if_not_owner;if you get Permission denied error
# disable_symlinks if_not_owner;
sendfile on;
tcp_nopush on;
tcp_nodelay on;
keepalive_timeout 5;
gzip on;
gzip_vary on;
gzip_disable "MSIE [1-6]\.";
gzip_proxied any;
gzip_http_version 1.0;
gzip_min_length 1000;
gzip_comp_level 6;
gzip_buffers 16 8k;
# You can remove image/png image/x-icon image/gif image/jpeg if you have slow CPU
gzip_types text/plain text/xml text/css application/x-javascript application/xml application/javascript application/xml+rss text/javascript application/atom+xml;
ignore_invalid_headers on;
client_header_timeout 3m;
client_body_timeout 3m;
send_timeout 3m;
reset_timedout_connection on;
connection_pool_size 256;
client_header_buffer_size 256k;
large_client_header_buffers 4 256k;
client_max_body_size 200M;
client_body_buffer_size 128k;
request_pool_size 32k;
output_buffers 4 32k;
postpone_output 1460;
proxy_temp_path /tmp/nginx_proxy/;
proxy_cache_path /var/cache/nginx levels=1:2 keys_zone=microcache:15m inactive=24h max_size=500m;
client_body_in_file_only on;
log_format bytes_log "$msec $bytes_sent .";
log_format custom_microcache '$remote_addr - $remote_user [$time_local] '
'"$request" $status $body_bytes_sent '
'"$http_referer" "$http_user_agent" nocache:$no_cache';
include "/etc/nginx/vhosts/*";
}

虚拟主机配置 ----------------------------------

server {
error_log /var/log/nginx/vhost-error_log warn;
listen 149.210.164.212:80;
listen [::]:80;
server_name lyntouch.com www.lyntouch.com;
access_log /usr/local/apache/domlogs/lyntouch.com-bytes_log bytes_log;
access_log /usr/local/apache/domlogs/lyntouch.com combined;
root /home/lyntouch/public_html;
#location / {
location ~*.*\.(3gp|gif|jpg|jpeg|png|ico|wmv|avi|asf|asx|mpg|mpeg|mp4|pls|mp3|mid|wav|swf|flv|html|htm|txt|js|css|exe|zip|tar|rar|gz|tgz|bz2|uha|7z|doc|docx|xls|xlsx|pdf|iso)$ {
expires 1M;
try_files $uri @backend;
}
location / {
error_page 405 = @backend;
add_header X-Cache "HIT from Backend";
proxy_pass http://149.210.164.212:8081;
include proxy.inc;
include microcache.inc;
}
location @backend {
internal;
proxy_pass http://149.210.164.212:8081;
include proxy.inc;
include microcache.inc;
}
location ~ .*\.(php|jsp|cgi|pl|py)?$ {
proxy_pass http://149.210.164.212:8081;
include proxy.inc;
include microcache.inc;
}
location ~ /\.ht {
deny all;
}
}

可能是什么原因造成的?

这里是httpd.conf虚拟主机部分------------------

# DO NOT EDIT. AUTOMATICALLY GENERATED.  IF YOU NEED TO MAKE A CHANGE PLEASE USE THE INCLUDE FILES.

<VirtualHost 149.210.164.212:8081>
ServerName lyntouch.com
ServerAlias www.lyntouch.com
DocumentRoot /home/lyntouch/public_html
ServerAdmin webmaster@lyntouch.com
UseCanonicalName Off

## User lyntouch # Needed for Cpanel::ApacheConf
UserDir enabled lyntouch

# Enable backwards compatible Server Side Include expression parser for Apache versions >= 2.4.
# To selectively use the newer Apache 2.4 expression parser, disable SSILegacyExprParser in
# the user's .htaccess file. For more information, please read:
# http://httpd.apache.org/docs/2.4/mod/mod_include.html#ssilegacyexprparser
<IfModule mod_include.c>
<Directory "/home/lyntouch/public_html">
SSILegacyExprParser On
</Directory>
</IfModule>

<IfModule mod_suphp.c>
suPHP_UserGroup lyntouch lyntouch
</IfModule>
<IfModule !mod_disable_suexec.c>
<IfModule !mod_ruid2.c>
SuexecUserGroup lyntouch lyntouch
</IfModule>
</IfModule>
<IfModule mod_ruid2.c>
RMode config
RUidGid lyntouch lyntouch
</IfModule>
<IfModule itk.c>
# For more information on MPM ITK, please read:
# http://mpm-itk.sesse.net/
AssignUserID lyntouch lyntouch
</IfModule>

ScriptAlias /cgi-bin/ /home/lyntouch/public_html/cgi-bin/




# To customize this VirtualHost use an include file at the following location
# Include "/usr/local/apache/conf/userdata/std/2_4/lyntouch/lyntouch.com/*.conf"
</VirtualHost>

一旦我卸载 nginxadmin,一切就会恢复正常。

最佳答案

您将在配置文件中更新 proxy_read_timeout 值。

关于linux - nginxadmin 1 上游 cpanel 超时,我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/28902732/

26 4 0
Copyright 2021 - 2024 cfsdn All Rights Reserved 蜀ICP备2022000587号
广告合作:1813099741@qq.com 6ren.com