개발/Server

[Ubuntu][Error] update-rc.d: error: apache Default-Start contains no runlevels, aborting.

leebera_ 2021. 11. 26. 15:33

Ubuntu 20.04 LTS 사용

 

문제점

/etc/init.d/ 에 있는 apache 서비스 파일에 Default-Start에 관련한 내용이 있지 않아 발생

 

해결방법

# Default-Start:# Default-Start: 2 3 4 5로 변경

 

만약 Default-Start가 없다면 관련된 문장이 없을 것이라 생각되니 아래 내용을 모두 추가하면 됨

### BEGIN INIT INFO
# Provides:          서비스 이름
# Required-Start:    
# Required-Stop:     
# Default-Start:     2 3 4 5
# Default-Stop:      0 1 6
# Short-Description: description
### END INIT INFO

 

 


 

참고

 

Default-Start contains no runlevels, aborting

I'm trying to check if this solution would help me with auto restarting after shutdown. But command sudo systemctl enable haltusbpower.service is followed by error: Synchronizing state of

askubuntu.com