我有两个网站:无限301重定向2点
- http://forkandspoon.pl/ - Worpress
- http://lunch.forkandspoon.pl/ - 自定义代码(旧的Kohana框架)
不知道发生了什么,但一切工作正常直到几天前。这些网站不再可用。有301无限的重定向。
网站1 - 奇怪的是,管理面板是可访问和正在工作,但主网站不是。 WordPress的更新到最新版本,我没有更新插件和主题,但我没有做任何开发。
我禁用了所有插件,切换到不同的主题,删除.htaccess文件(这是标准的,没有怪异的代码在那里)。没什么帮助。
网站2 - 我几个月没有碰过这个网站。
我经历了两个站点的代码,我比较了服务器的代码和本地副本。一切看起来都是按顺序的。
我在该服务器上有Apache和Nginx,并且配置根本没有改变。我有其他网站托管在同一台服务器上,他们不受影响。 Cloudflare处理DNS,我也检查了一切,看起来很好。
这里可能会发生什么?我没有想法。任何线索?
按照要求,这里的Nginx的conf:
server {
listen 80;
root /home/forkandspoon/forkandspoon.pl;
index index.php index.html index.htm;
server_name forkandspoon.pl www.forkandspoon.pl;
location/{
try_files $uri $uri/ /index.php;
}
location ~ \.php$ {
proxy_set_header X-Real-IP $remote_addr;
proxy_set_header X-Forwarded-For $remote_addr;
proxy_set_header Host $host;
proxy_pass http://127.0.0.1:8080;
}
location ~ /\.ht {
deny all;
}
}
server {
listen 80;
root /home/forkandspoon/lunch.forkandspoon.pl;
index index.php index.html index.htm;
server_name lunch.forkandspoon.pl www.lunch.forkandspoon.pl;
location/{
try_files $uri $uri/ /index.php?$args;
}
location ~ \.php$ {
proxy_set_header X-Real-IP $remote_addr;
proxy_set_header X-Forwarded-For $remote_addr;
proxy_set_header Host $host;
proxy_pass http://127.0.0.1:8080;
}
location ~ /\.ht {
deny all;
}
}
和Apache
<VirtualHost *:8080>
ServerAdmin [email protected]
DocumentRoot /home/forkandspoon/forkandspoon.pl/
ServerName forkandspoon.pl
ServerAlias www.forkandspoon.pl
ErrorLog logs/forkandspoon.pl-error_log
CustomLog logs/forkandspoon.pl-access_log common
<Directory /home/forkandspoon/forkandspoon.pl>
Options +Indexes FollowSymLinks +ExecCGI
AllowOverride All
Order Allow,Deny
Allow from all
</Directory>
</VirtualHost>
<VirtualHost *:8080>
ServerAdmin [email protected]
DocumentRoot /home/forkandspoon/lunch.forkandspoon.pl/
ServerName lunch.forkandspoon.pl
ServerAlias www.lunch.forkandspoon.pl
ErrorLog logs/lunch.forkandspoon.pl-error_log
CustomLog logs/lunch.forkandspoon.pl-access_log common
<Directory /home/forkandspoon/lunch.forkandspoon.pl>
Options +Indexes FollowSymLinks +ExecCGI
AllowOverride All
Order Allow,Deny
Allow from all
</Directory>
</VirtualHost>
注意, 我也被禁用的CloudFlare作为代理每一个评论。生效可能需要几分钟时间。
你试图将其关闭并重新开启? –
如果通过这个非常有用的评论你的意思是重新启动Apache和Nginx,那么是的,我做到了。 – 6bytes
它看起来像CloudFlare也代理网站? IP号码“forkandspoon.pl”解析为('104.28.1 {8,9} .34')由CloudFlare拥有。 – robertklep