解决wsl无法使用systemctl的问题

解决wsl出现Failed to get D-Bus connection的问题

运行命令

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

如果出现connection refused需要在hosts中添加raw.githubusercontent.com的真实ip

你可能感兴趣的:(wsl,docker,linux,centos,shell)