aws - ec2 - linux - apache:无法从外部访问 index.html

aws - ec2 - linux - apache:无法从外部访问 index.html

我试图弄清楚为什么 index.html 在 AWS 上的 ec2 实例外部不可见。已验证服务器正在运行 (netstat -lp) 并且 curl 收到 404 错误 (所有血腥细节都在这里

现在日志中,访问只显示 404 错误,很好

/var/log/httpd/elasticbeanstalk-access_log:

[06/Oct/2011:10:30:43 +0000] "GET / HTTP/1.1" 404 - "-" "Mozilla/5.0 (X11; Linux x86_64) AppleWebKit/535.1 (KHTML, like Gecko)

但错误长度却完全是个谜:/var/log/httpd/error_log:

[Thu Oct 06 03:36:08 2011] [notice] caught SIGTERM, shutting down
[Thu Oct 06 10:30:32 2011] [notice] suEXEC mechanism enabled (wrapper: /usr/sbin/suexec)
[Thu Oct 06 10:30:32 2011] [notice] Digest: generating secret for digest authentication ...
[Thu Oct 06 10:30:32 2011] [notice] Digest: done
[Thu Oct 06 10:30:32 2011] [notice] Apache/2.2.16 (Unix) DAV/2 configured -- resuming normal operations

PS:我没有看到 httpd.conf 中配置的任何 vhost,文件底部的整个部分都被注释掉了 :-(

答案1

您的服务器响应 404 Not Found 错误。请检查您的文档根目录已配置,并且有一个包含索引文件在里面。

相关内容