Server Infra

Apache 설정

쪽보다푸른 2022. 4. 18. 13:50

[Apache]

1. Apache 설치

$ sudo yum install httpd

 

2. Apache 경로 확인

$ whereis httpd

 

3. Port Open

$ sudo firewall-cmd --zone=public --list-all //열린 포트 확인

$ sudo firewall-cmd --zone=public --permanent --add-port=80/tcp //80포트 개방

$ sudo firewall-cmd --reload // 적용

 

4. Port 확인

$ netstat -an | grep 8080

$ netstat -an | grep 80

 

5. Apache 시작

$ sudo systemctl restart httpd

$ sudo systemctl stop httpd

$ sudo systemctl start httpd