wsl centos7: Failed to get D-Bus connection: Operation not permitted

wsl 運行的 centos 7,使用  service 命令提示 Failed to get D-Bus connection: Operation not permitted 錯誤,無法運行。

目前的解決辦法是更換 systemctl 文件:

mv /usr/bin/systemctl /usr/bin/systemctl.old
curl https://raw.githubusercontent.com/gdraheim/docker-systemctl-replacement/master/files/docker/systemctl.py > /usr/bin/systemctl
chmod +x /usr/bin/systemctl

 

發表評論
所有評論
還沒有人評論,想成為第一個評論的人麼? 請在上方評論欄輸入並且點擊發布.
相關文章