ubantuSystem has not been booted with systemd as init system (PID 1). Can't operate. Failed to connect to bus: Host is down
时间: 2023-10-28 16:00:20 浏览: 41
在Ubuntu中出现"System has not been booted with systemd as init system (PID 1). Can't operate. Failed to connect to bus: Host is down"错误的原因是Ubuntu使用的是SysV init(sysvinit)系统而不是systemd系统。
解决这个问题的方法是使用SysV init的命令代替systemd的命令。根据你提供的引用内容,你可以尝试使用"sudo service docker start"命令来启动Docker服务。这个命令适用于SysV init系统。这样就能避免出现上述错误信息。
相关问题
WSLSystem has not been booted with systemd as init system (PID 1). Can't operate. Failed to connect to bus: Host is down
WSL是Windows Subsystem for Linux的缩写,是一种在Windows操作系统上运行Linux的兼容层。根据引用、和的内容来看,出现"System has not been booted with systemd as init system (PID 1). Can't operate. Failed to connect to bus: Host is down"这个错误是因为WSL并不支持systemd作为init系统。systemd是一个常用的Linux初始化系统,用于管理和控制进程。而在WSL中,由于与宿主机系统的差异,无法完全支持systemd。
解决这个问题的方法之一是使用其他替代方案来管理和控制进程,比如使用supervisor或者openrc。另外,还可以尝试使用其他的容器化技术,比如Podman或者LXD,它们在WSL上可能更加适用。
总结来说,WSL不支持systemd作为init系统,因此在使用docker或者其他需要systemd支持的命令时,可能会出现"System has not been booted with systemd as init system (PID 1). Can't operate. Failed to connect to bus: Host is down"这个错误提示。为了解决这个问题,可以尝试使用其他替代方案来管理和控制进程,或者考虑使用其他容器化技术。
Rocky 9 System has not been booted with systemd as init system (PID 1). Can t operate. Failed to connect to bus: Host is down
Rocky 9系统启动时出现“System has not been booted with systemd as init system (PID 1). Can't operate. Failed to connect to bus: Host is down”错误提示,这是因为Rocky 9系统默认使用了systemd作为init系统,而Docker容器中并没有systemd,因此无法使用systemctl命令。解决方法是在Docker容器中添加--privileged参数,并在最后加上/usr/sbin/init命令,这样就可以使用systemctl命令了。