호랑이한테물릴래

System has not been booted with systemd as init system (PID 1). Can't operate. / WSL Ubuntu 에러 해결방법 본문

DevOps/OS

System has not been booted with systemd as init system (PID 1). Can't operate. / WSL Ubuntu 에러 해결방법

호랑이한테물릴래 2022. 6. 30. 13:58
반응형

sudo systemctl daemon-reload 명령어 실행할 때 아래와 같은 에러가 발생한다.

System has not been booted with systemd as init system (PID 1). Can't operate. Failed to connect to bus: Host is down

그럼 아래 명령어로 해결하면 된다.

sudo apt-get update && sudo apt-get install -yqq daemonize dbus-user-session fontconfig

sudo daemonize /usr/bin/unshare --fork --pid --mount-proc /lib/systemd/systemd --system-unit=basic.target

exec sudo nsenter -t $(pidof systemd) -a su - $LOGNAME

snap version

https://gist.github.com/alyleite/ca8b10581dbecd722d9dcc35b50d9b2b

반응형
0 Comments
댓글쓰기 폼