我将cloudfront连接到使用ubuntu服务器14.04 ec2实例的负载均衡器。有时当我浏览我的wordpress网站上的控制面板时,我只会得到一个空白页面,我必须按下输入并等待大约30秒才能进入下一页。这通常发生在“发布”请求之后。
有人有什么想法吗?我已经让这个设置正常工作了一段时间没有问题但是在ubuntu更新后我的服务器爆炸了。我不得不将一些apache worker线程设置为较低的数字,设置mysql交换,删除apport使我的服务器崩溃。然后就像这个空白页面的事情也发生在我身上。
我也改变了我的域名,所以基本上我必须在亚马逊上重新创建我的所有东西,但是我对它进行了双重/三重检查,这一切似乎都是正确的值,就像以前一样。
这是我的云端设置,其长
cloudfront settings general
Distribution ID E11KP67NC8KZHO
Log Prefix -
Delivery Method Web
Cookie Logging Off
Distribution Status Deployed
Comment -
Price Class Use All Edge Locations (Best Performance)
AWS WAF Web ACL -
State Enabled
Alternate Domain Names (CNAMEs)
techstory2.com
SSL Certificate techstory2.com (1f411465-1b8d-42a5-93f4-9cd663330e46)
Domain Name d1cqn6ev1d7d25.cloudfront.net
Custom SSL Client Support Only Clients that Support Server Name Indication (SNI)
Default Root Object -
Last Modified 2016-07-22 18:20 UTC-4
Log Bucket
Origins
techstory2balan-595918364.us-east-1.elb.amazonaws.com
ELB-techstory2balan-595918364
Origin SSL Protocols
TLSv1.2 enabled
TLSv1.1 enabled
TLSv1 enabled
SSLv3 diabled
Origin Protocol Policy
HTTPS Only selected
HTTP Port
80
HTTPS Port
443
Behaviours
Path PatternDefault (*)
Origin
ELB-techstory2balan-595918364
Viewer Protocol Policy
Redirect HTTP to HTTPS
Allowed HTTP Methods
GET, HEAD, OPTIONS, PUT, POST, PATCH, DELETE
Cached HTTP Methods
GET, HEAD (Cached by default)
OPTIONS
Forward Headers
All
Minimum TTL
0
Maximum TTL
31536000
Default TTL
86400
Forward Cookies
All
Forward Query Strings
Yes
Smooth Streaming
No
Restrict Viewer Access
No
Compress Objects Automatically
Yes
答案 0 :(得分:1)
您似乎只配置了原始协议策略HTTPS。这意味着当用户通过HTTPS访问CloudFront时,CloudFront将通过HTTPS与您的源联系。我建议从ELB级别重新检查SSL。
它运行一段时间的原因是您的发行版未配置为根据协议而变化,因此如果用户通过HTTP发出请求,则所述对象将位于CloudFront缓存中,并且还将通过HTTPS提供。
答案 1 :(得分:0)
事实证明负载均衡器正在敲击我自己的ec2实例,每秒大约有20个command.php请求,如我的apache2 / access.log中所示,
72.31.7.71 - - [25/Jul/2016:17:21:17 +0000] "POST /remote50/command.php?uid=12926 HTTP/1.1" 500 780 "-" "-"
172.31.7.71 - - [25/Jul/2016:17:21:18 +0000] "POST /remote50/command.php?uid=7668 HTTP/1.1" 500 780 "-" "-"
172.31.7.71 - - [25/Jul/2016:17:21:18 +0000] "POST /remote50/command.php?uid=7471 HTTP/1.1" 500 780 "-" "-"
172.31.7.71 - - [25/Jul/2016:17:21:18 +0000] "POST /remote50/command.php?uid=9595 HTTP/1.1" 500 780 "-" "-"
172.31.7.71 - - [25/Jul/2016:17:21:18 +0000] "POST /remote50/command.php?uid=7700 HTTP/1.1" 500 780 "-" "-"
172.31.7.71 - - [25/Jul/2016:17:21:18 +0000] "POST /remote50/command.php?uid=7356 HTTP/1.1" 500 780 "-" "-"
172.31.7.71 - - [25/Jul/2016:17:21:18 +0000] "POST /remote50/command.php?uid=7337 HTTP/1.1" 500 780 "-" "-"
172.31.7.71 - - [25/Jul/2016:17:21:18 +0000] "POST /remote50/command.php?uid=8858 HTTP/1.1" 500 780 "-" "-"
172.31.7.71 - - [25/Jul/2016:17:21:18 +0000] "POST /remote50/command.php?uid=6744 HTTP/1.1" 500 780 "-" "-"
172.31.7.71 - - [25/Jul/2016:17:21:18 +0000] "POST /remote50/command.php?uid=7757 HTTP/1.1" 500 780 "-" "-"
::1 - - [25/Jul/2016:17:21:18 +0000] "OPTIONS * HTTP/1.0" 200 125 "-" "Apache/2.4.7 (Ubuntu) PHP/5.5.9-1ubuntu4.17 OpenSSL/1.0.1f (internal dummy connection)"
172.31.7.71 - - [25/Jul/2016:17:21:18 +0000] "POST /remote50/command.php?uid=7305 HTTP/1.1" 500 780 "-" "-"
172.31.7.71 - - [25/Jul/2016:17:21:18 +0000] "POST /remote50/command.php?uid=7892 HTTP/1.1" 500 780 "-" "-"
172.31.7.71 - - [25/Jul/2016:17:21:18 +0000] "POST /remote50/command.php?uid=7214 HTTP/1.1" 500 780 "-" "-"
172.31.7.71 - - [25/Jul/2016:17:21:18 +0000] "POST /remote50/command.php?uid=7669 HTTP/1.1" 500 780 "-" "-"
172.31.7.71 - - [25/Jul/2016:17:21:18 +0000] "POST /remote50/command.php?uid=6415 HTTP/1.1" 500 780 "-" "-"
172.31.7.71 - - [25/Jul/2016:17:21:18 +0000] "POST /remote50/command.php?uid=8637 HTTP/1.1" 500 780 "-" "-"
172.31.7.71 - - [25/Jul/2016:17:21:18 +0000] "POST /remote50/command.php?uid=12586 HTTP/1.1" 500 780 "-" "-"
172.31.7.71 - - [25/Jul/2016:17:21:18 +0000] "POST /remote50/command.php?uid=8546 HTTP/1.1" 500 780 "-" "-"
172.31.7.71 - - [25/Jul/2016:17:21:18 +0000] "POST /remote50/command.php?uid=6124 HTTP/1.1" 500 780 "-" "-"
172.31.7.71 - - [25/Jul/2016:17:21:18 +0000] "POST /remote50/command.php?uid=7005 HTTP/1.1" 500 780 "-" "-"
172.31.7.71 - - [25/Jul/2016:17:21:18 +0000] "POST /remote50/command.php?uid=13623 HTTP/1.1" 500 780 "-" "-"
172.31.7.71 - - [25/Jul/2016:17:21:18 +0000] "POST /remote50/command.php?uid=8515 HTTP/1.1" 500 780 "-" "-"
172.31.7.71 - - [25/Jul/2016:17:21:18 +0000] "POST /remote50/command.php?uid=12445 HTTP/1.1" 500 780 "-" "-"
172.31.7.71 - - [25/Jul/2016:17:21:18 +0000] "POST /remote50/command.php?uid=9376 HTTP/1.1" 500 780 "-" "-"
172.31.7.71 - - [25/Jul/2016:17:21:18 +0000] "POST /remote50/command.php?uid=5569 HTTP/1.1" 500 780 "-" "-"
172.31.7.71 - - [25/Jul/2016:17:21:18 +0000] "POST /remote50/command.php?uid=13800 HTTP/1.1" 500 780 "-" "-"
172.31.7.71 - - [25/Jul/2016:17:21:19 +0000] "POST /remote50/command.php?uid=7296 HTTP/1.1" 500 780 "-" "-"
172.31.7.71 - - [25/Jul/2016:17:21:19 +0000] "POST /remote50/command.php?uid=8520 HTTP/1.1" 500 780 "-" "-"
为什么这样做,我不知道。我所知道的是我关闭负载均衡器和云端,现在我的ec2实例正常工作。我稍后会尝试删除并重新创建负载均衡器和云端,并希望下次不会使用我自己的服务器。
答案 2 :(得分:0)
运行cloudfront缓存无效。那是我的解决办法。