yumyum

[Linux] ACL 본문

# yum -y install httpd -> httpd 깔아주기

 

# rpm -qa | grep httpd ->  httpd 깔아준거 확인

 

# systemctl restart httpd
# systemctl enable httpd

# systemctl status httpd

 

#systemctl stop firewalld

# systemctl disable firewalld

 

#l ls /etc/httpd

 

# ls -l /var/www

 

# lsof -i tcp:80

# httpd -v -> 버전 확인하기

 

# ls /var/log/httpd

access_log  error_log  ssl_access_log  ssl_error_log  ssl_request_log

 

 # vim /etc/httpd/conf/httpd.conf

=> AllowOverride를 All로 바꿔주기

ACL 해주기 -> 192.168.111.120 (록키9 서버) 에서만 접속 안되게 설정

 

나와서 

# systemctl restart httpd 해주기

 

# cd /var/www/html 로 이동

 

 

# vim index.html 로 웹페이지 수정해주기

 

만든대로 보이는 페이지 모습

 

=> 192.168.111.130 ip인 우분투에서는 접속이 됨

=> 192.168.111.120 ip인 rocky9에서는 접속이 안됨

 

________________________________________________________

=>특정 ip만 허용하는 방식