amazon linux 安装nginx,linux – NGINX不显示Amazon EC2实例上的默认页...
我在Fedora上安装了nginx.但我不知道为什么我不能通过浏览器请求服务器IP来获取默认的nginx页面.我的请求因超时而下降.
但是nginx正在运行.
$sudo service nginx status
nginx (pid 20372) is running...
我的默认生成配置是
# For more information on configuration, see:
# * Official English Documentation: http://nginx.org/en/docs/
# * Official Russian Documentation: http://nginx.org/ru/docs/
user nginx;
worker_processes auto;
error_log /var/log/nginx/error.log;
pid /var/run/nginx.pid;
events {
worker_connections 1024;
}
http {
log_format main '$remote_addr - $remote_user [$time_local] "$request" '
'$status $body_bytes_sent "$http_referer" '
'"$http_user_agent" "$http_x_forwarded_for"';
access_log /var/log/nginx/access.log main;
sendfile on;
tcp_nopush on;
tcp_nodelay on;
keepalive_timeout 65;
types_hash_max_size 2048;
include /etc/nginx/mime.types;
default_type application/octet-stream;
# Load modular configuration files from the /etc/nginx/conf.d directory.
# See http://nginx.org/en/docs/ngx_core_module.html#include
# for more information.
include /etc/nginx/conf.d/*.conf;
index index.html index.htm;
server {
listen 80 default_server;
listen [::]:80 default_server;
server_name localhost;
root /usr/share/nginx/html;
# Load configuration files for the default server block.
include /etc/nginx/default.d/*.conf;
location / {
}
# redirect server error pages to the static page /40x.html
#
error_page 404 /404.html;
location = /40x.html {
}
# redirect server error pages to the static page /50x.html
#
error_page 500 502 503 504 /50x.html;
location = /50x.html {
}
# proxy the PHP scripts to Apache listening on 127.0.0.1:80
#
#location ~ \.php${
# proxy_pass http://127.0.0.1;
#}
# pass the PHP scripts to FastCGI server listening on 127.0.0.1:9000
#
#location ~ \.php${
# root html;
# fastcgi_pass 127.0.0.1:9000;
# fastcgi_index index.php;
# fastcgi_param SCRIPT_FILENAME /scripts$fastcgi_script_name;
# include fastcgi_params;
#}
# deny access to .htaccess files, if Apache's document root
# concurs with nginx's one
#
#location ~ /\.ht {
# deny all;
#}
}
# Settings for a TLS enabled server.
#
# server {
# listen 443 ssl;
# listen [::]:443 ssl;
# server_name localhost;
# root /usr/share/nginx/html;
#
# ssl_certificate "/etc/pki/nginx/server.crt";
# ssl_certificate_key "/etc/pki/nginx/private/server.key";
# # It is *strongly* recommended to generate unique DH parameters
# # Generate them with: openssl dhparam -out /etc/pki/nginx/dhparams.pem 2048
# #ssl_dhparam "/etc/pki/nginx/dhparams.pem";
# ssl_session_cache shared:SSL:1m;
# ssl_session_timeout 10m;
# ssl_protocols TLSv1 TLSv1.1 TLSv1.2;
# ssl_ciphers HIGH:SEED:!aNULL:!eNULL:!EXPORT:!DES:!RC4:!MD5:!PSK:!RSAPSK:!aDH:!aECDH:!EDH-DSS-DES-CBC3-SHA:!KRB5-DES-CBC3-SHA:!SRP;
# ssl_prefer_server_ciphers on;
#
# # Load configuration files for the default server block.
# include /etc/nginx/default.d/*.conf;
#
# location / {
# }
#
# error_page 404 /404.html;
# location = /40x.html {
# }
#
# error_page 500 502 503 504 /50x.html;
# location = /50x.html {
# }
# }
}
我不知道发生了什么. /var/log/nginx/access.log和/var/log/nginx/access.log也是空的.请帮忙…
amazon linux 安装nginx,linux – NGINX不显示Amazon EC2实例上的默认页...相关推荐
- Linux 安装、卸载Nginx详细教程
Linux 安装.卸载Nginx详细教程 Linux版本的Nginx推荐使用源代码安装. 1. 环境准备 为了编译Nginx源代码,我们需要标准的GCC编译器.GCC的全称为GNUCompiler C ...
- Linux安装及卸载Nginx
Linux安装及卸载Nginx CentOS7 安装 1)安装所需插件 gcc安装 pcre.pcre-devel安装 zlib安装 openssl安装 2)压缩包安装nginx 下载安装包 解压 编 ...
- amazon ec2 linux yum install,在 Amazon Linux 2 EC2 实例上安装来自 Extras 库的软件
如何在运行 Amazon Linux 2 的 EC2 实例上安装来自 Extras 库的软件包? 上次更新日期:2020 年 10 月 7 日 如何在运行 Amazon Linux 2 的 Amazo ...
- aws ec2 linux 密码,演练:在 EC2 实例上重置密码和 SSH 密钥 - AWS Systems Manager
AWS 文档中描述的 AWS 服务或功能可能因区域而异.要查看适用于中国区域的差异,请参阅中国的 AWS 服务入门. 本文属于机器翻译版本.若本译文内容与英语原文存在差异,则一律以英文原文为准. 演练 ...
- serv-u 数据备份_如何使用用户数据脚本在EC2实例上安装Apache Web Server
serv-u 数据备份 你好朋友, 在本教程中,我们将看到如何使用用户数据脚本在EC2实例上安装Apache Web Server. 在我以前的教程之一中,我已经解释了如何使用AWS控制台启动EC2实 ...
- 如何使用用户数据脚本在EC2实例上安装Apache Web Server
你好朋友, 在本教程中,我们将看到如何使用用户数据脚本在EC2实例上安装Apache Web Server. 在我以前的教程之一中,我已经解释了如何使用AWS控制台启动EC2实例.如果您还没有完成该操 ...
- linux中安装httpd安装错误,linux安装httpd和nginx常见问题及解决办法
1 httpd-2.4.23.tar.gz安装 安装httpd之前,需要安装:gcc.apr.apr-util.pcre.zlib. 文件参考:D:\01soft\02测试\02悬镜管家\web服务\ ...
- linux安装php和nginx,Linux下安装配置Nginx以及安装PHP
1.编译安装Nginx 需要先安装两个库 # yum -y install openssl openssl-devel 然后下载,编译Nginx # wget http://nginx.org/dow ...
- Linux安装redis、nginx
一.安装redis redis简介: Redis是一个开源(BSD许可),内存存储的数据结构服务器,可用作数据库,高速缓存和消息队列代理. 它支持字符串.哈希表.列表.集合.有序集合,位 ...
最新文章
- markdown 图片居中_Markdown更改字体、颜色、大小,插入表格等方法
- 一文看懂CV中的注意力机制
- 一. synchronized 的局限性 与 Lock 的优点
- 用AI变身16岁女孩,抓住40岁违法警察!20岁男大学生钓鱼执法秀翻美国
- 初学python下载哪个版本-学python下载哪个版本
- 链表的代码实现【数据结构F】
- Docker使用小结(一)Docker镜像以及Docker容器
- 帆软FineMobile 自适应
- IDEA格式化SQL代码
- 用数据分析看共享单车
- 世界上最健康的作息时间表健康十不易
- 操作系统—CPU调度与内存管理
- 荧光定量PCR的优点和检测方法盘点
- 一文读懂什么是自由城Free City
- Arduino提高篇23—OLED电子时钟
- 读论文《Recurrent neural network based language model 》
- IT产品是计算机类产品吗,IT产品是什么
- 蓝牙UART和PCM接口传输的信号 硬件接口
- 华为、联想等名企笔试题总汇
- 官宣:深度剖析免费OA系统是如何盈利
热门文章
- eclipse创建springboot项目_idea创建基于gradle构建的spring boot项目
- oracle怎么判断主库还是备库,Oracle查看归档是否被备库应用
- mysql远程服务器返回错误404未找到_远程服务器返回错误: 404错误、远程服务器返回错误:500错误、 HttpWebResponse远程服务器返回错误:(404、500) 错误。...
- [javaweb] servlet-session 会话跟踪技术 与 session保存作用域 (三)
- Python教程:列表推导式和嵌套的列表推导式讲解
- python教程:filter,map,reduce
- Flask学习 黑马程序员-6节课入门Flask框架web开发视频(中途撤退,寻找py3教程)
- linux防火墙操作命令
- java 数组 push pop_JavaScript学习笔记:数组的push()、pop()、shift()和unshift()方法
- linux管道原子性写入,write(2)/ read(2)linux中进程之间的原子性