
服务器
1.打开终端并以root身份登录系统。
2.更新系统软件包:
yum-yupdate
3.安装ApacheWeb服务器:
yum-yinstallhttpd
4.启动Apache服务并在开机时自动启动:
systemctlstarthttpd
systemctlenablehttpd
5.配置防火墙以允许HTTP访问:
firewall-cmd--permanent--add-service=http
firewall-cmd--reload
6.访问安装的Apache服务器:
在Web浏览器中输入服务器的IP地址或域名,如http://localhost或http://192.168.1.100,如果看到“ApacheWeb服务器默认页面”的消息,则说明Apache已正常安装。
Copyright © 2025 IZhiDa.com All Rights Reserved.
知答 版权所有 粤ICP备2023042255号