728x90
[Linux] CentOS systemctl에서 disabled 서비스 enable 처리
출처: https://pncode.tistory.com/79
CentOS에서 서비스를 시작하거나 스탑할 때 다음의 명령어를 이용한다.
httpd.service를 예로 들겠다.
원래는 다음의 형태로 시작하거나 정지했는데.. 명령어가 변경되었다.
service httpd start
service httpd stop
아래와 같이 변경 됨.
위의 명령어를 실행하더라도 redirect 되므로 문제 없다.
systemctl start httpd.service
systemctl stop httpd.service
아래의 명령어를 입력하면 현재 상태를 볼 수 있다.
systemctl status httpd.service
예를 들어, 서비스가 실행되지 않는경우 disabled 되어있는 경우가 있다.
이것을 enable로 변경해주어야 한다.
다음을 입력하여 리스트를 확인하자.
systemctl list-unit-files
확인 후, disable을 enable로 변경한다.
아래의 코드를 입력한다.
systemctl enable httpd.service
728x90
반응형
'컴퓨터 활용(한글, 오피스 등) > 50_2.운영체제_리눅스' 카테고리의 다른 글
systemd(system daemon) 이해 (1) | 2022.12.23 |
---|---|
리눅스에서 OS버전 확인하기 (0) | 2022.12.23 |
가상머신 관리하기(KVM) (0) | 2022.12.21 |
리눅스_유용한 쉘 명령어 (Shell commands) 모음 (0) | 2022.12.07 |
리눅스_CentOS7_Xpress Engine 설치 (0) | 2022.12.07 |