리눅스 관련 옵션 명령어
CentOS 버전별 명령어(service, chkconfig, 방화벽)
웹하는빡통
2019. 12. 14. 12:20
1 service
기능 CentOS 6 CentOS 7
| 서비스 상태보기 | service 서비스명 status | systemctl status 서비스명 |
| 서비스 시작 | service 서비스명 start | systemctl start 서비스명 |
| 서비스 정지 | service 서비스명 stop | systemctl stop 서비스명 |
| 서비스 재시작 | service 서비스명 restart | systemctl restart 서비스명 |
| 서비스 리로드 | service 서비스명 reload | systemctl reload 서비스명 |
2 chkconfig
기능 CentOS 6 CentOS 7
| 자동시작 확인 | chkconfig 서비스명 | systemctl is-enabled 서비스명 |
| 자동시작 설정 | chkconfig 서비스명 on | systemctl enable 서비스명 |
| 자동시작 해제 | chkconfig 서비스명 off | systemctl disable 서비스명 |
3 방화벽
기능 CentOS 6 CentOS 7
| 방화벽 중지 | service iptables stop | systemctl stop firewalld |
| 방화벽 시작 | service iptables start | systemctl start firewalld |
| 방화벽 자동시작 해제 | chkconfig iptables off | systemctl disable firewalld |
| 방화벽 자동시작 적용 | chkconfig iptables on | systemctl enable firewalld |