HRCE简单实验

1.实验要求

www.xixi.com web服务器

curl ww.xixi.com

welcome to xixi

要求 web服务器的ip地址必须是 11.11.11.11

2.实验过程

nmcli connection modify ens160 +ipv4.addresses 11.11.11.11/24

nmcli connection up ens160

cd /etc/nginx/conf.d/

vim xixi.conf

server {

listen 11.11.11.11:80;

server_name www.xixi.com;

root /var/www/xixi;

access_log /var/log/nginx/xixi/access.log;

error_log /var/log/nginx/xixi/error.log;

location / {

index index.html index.htm;

}

}

mkdir -p /var/www/xixi

echo "welcome to xixi " > /var/www/xixi/index.html

mkdir -p /var/log/nginx/xixi

echo "11.11.11.11 www.xixi.com" >> /etc/hosts

mkdir -p /var/log/nginx/https

chown -R nginx:nginx /var/log/nginx/https

chmod -R 755 /var/log/nginx/https

systemctl restart nginx

systemctl status nginx.service

curl www.xixi.com

curl www.xixi.com

ip a

curl www.xixi.com

3.实验结果

相关推荐
ss27310 分钟前
为什么PostgreSQL适合AI场景?
数据库·人工智能·postgresql
瑞克-桑切斯16 分钟前
7、MySQL 慢查询排查与优化实战指南
java·服务器·数据库
z06.1 小时前
MySQL索引
数据库·mysql
考虑考虑1 小时前
Posrgresql恢复.backup文件
数据库·后端·postgresql
云祺vinchin1 小时前
中小企业备份软件选型从恢复需求到总体成本评估
数据库·数据备份·中小企业备份·容灾备份软件
Zenova EdgeOS2 小时前
Go 工业边缘错误处理实战:用 errors 构建可追溯错误链
开发语言·数据库·golang
KKKlucifer2 小时前
国内数据安全服务的产品智能化转型:大模型赋能下的技术能力重构分析
大数据·数据库·重构
vibecode2 小时前
网站服务器失去响应怎么解决?我把连接超时和读超时这两段计时拆开跑了一遍
运维·服务器
字节跳动开源3 小时前
OpenViking 上线原生 3D 内容理解模型
数据库·开源
工业一体机老司机3 小时前
Docker部署工控机采集服务 Compose编排与开机自启
运维·docker·容器