一、设置web服务器
准备使用
起首在正式设置之前必要做以下使用
关闭防火墙
systemctl stop firewalld
永世关闭防火墙
systemctl disable firewalld
关闭selinux
setenforce 0
永世关闭selinux
vim /etc/selinux/config
selinux=permissive
还必要包管可以大概正常ping通www.baidu.com
1.安装nginx
[root@web ~]# yum -y install nginx
检察nginx的安装环境
[root@web ~]# rpm -qa | grep nginx
[root@web ~]# rpm -ql nginx
2.启动nginx
[root@web ~]# nginx
3.编写页面内容
使用echo写入内容
[root@web ~]# echo "I am web server marjor is static file manager" > /usr/share/nginx/html/index.html <
免责声明:如果侵犯了您的权益,请联系站长,我们会及时删除侵权内容,谢谢合作!qidao123.com:ToB企服之家,中国第一个企服评测及软件市场,开放入驻,技术点评得现金 |