Amazon ec2 AWS EC2连接错误超时
我的应用程序是在AWS EC2实例中使用redhat下的apache2和tomcat构建的。它在我重新启动EC2实例之前工作,在我重新启动EC2实例之后,它只能访问ssh,但不能在浏览器中连接,并显示“ERR\u CONNECTION\u TIMED\u OUT”。 知道我做错了什么,或者我应该检查哪个日志吗 @在执行sudo systemctl后,httpd状态似乎正常,httpd显示:Amazon ec2 AWS EC2连接错误超时,amazon-ec2,redhat,Amazon Ec2,Redhat,我的应用程序是在AWS EC2实例中使用redhat下的apache2和tomcat构建的。它在我重新启动EC2实例之前工作,在我重新启动EC2实例之后,它只能访问ssh,但不能在浏览器中连接,并显示“ERR\u CONNECTION\u TIMED\u OUT”。 知道我做错了什么,或者我应该检查哪个日志吗 @在执行sudo systemctl后,httpd状态似乎正常,httpd显示: 请检查以下内容: 确保您在浏览器中使用了正确的公共IP地址或公共DNS IPv4 确保您在Apache配置
请检查以下内容: 确保您在浏览器中使用了正确的公共IP地址或公共DNS IPv4 确保您在Apache配置文件中有正确的配置,如Listen IP:80和ServerName domain:80 确保apache正在侦听端口80。
如果您可以访问shell,请尝试sudo systemctl statushttpd@DusanBajic我在问题中附加https状态确保:1您在浏览器中使用的IP地址正确,或者您使用的域名解析为正确的IP地址,2连接到EC2实例的安全组的端口80已打开,3 apache正在侦听端口80 netstat-nap | grep LISTEN | grep httpd,4 OS防火墙已停止,或端口80已打开
● httpd.service - The Apache HTTP Server
Loaded: loaded (/usr/lib/systemd/system/httpd.service; enabled; vendor preset: disabled)
Active: active (running) since Fri 2017-12-29 16:34:06 +08; 2s ago
Docs: man:httpd(8)
man:apachectl(8)
Process: 10891 ExecStop=/bin/kill -WINCH ${MAINPID} (code=exited, status=0/SUCCESS)
Main PID: 10896 (httpd)
Status: "Processing requests..."
CGroup: /system.slice/httpd.service
├─10896 /usr/sbin/httpd -DFOREGROUND
├─10897 /usr/sbin/httpd -DFOREGROUND
├─10898 /usr/sbin/httpd -DFOREGROUND
├─10899 /usr/sbin/httpd -DFOREGROUND
├─10900 /usr/sbin/httpd -DFOREGROUND
└─10901 /usr/sbin/httpd -DFOREGROUND
Dec 29 16:34:06 ip-172-31-21-170.ap-southeast-1.compute.internal systemd[1]: ...
Dec 29 16:34:06 ip-172-31-21-170.ap-southeast-1.compute.internal systemd[1]: ...
Hint: Some lines were ellipsized, use -l to show in full.