第2集 RPM Apache安装与调试

发布于 2020-02-19  862 次阅读


1.Apache安装
yum -y install httpd*

2.httpd服务管理
systemctl enable httpd.service
systemctl start httpd.service
systemctl stop httpd.service
systemctl restart httpd.service
systemctl reload httpd.service

3.查看状态
systemctl status httpd.service

4.查看进程
pstree |grep httpd

5.查看端口
netstat -tunpl |grep httpd

6.测试Web功能
http://192.168.2.1

7.网站根目录
/var/www/html/index.html

8.修改配置文件
vi /etc/http.d/conf/httpd.conf
Listen 8000