chroot后systemctl无法使用,是否有替代方案

操作系统版本:2203SP1-LTS
问题描述:choot到新的根目录下,使用systemctl 命令报错
image
所以请教是否有可替代的方案便于在新的根目录中管理系统服务,
例如github中有自己实现的systemctl脚本,但是由于centos和openeuler service文件编写有差异,所以不适用,链接如下 GitHub - gdraheim/docker-systemctl-replacement: docker systemctl replacement - allows to deploy to systemd-controlled containers without starting an actual systemd daemon (e.g. centos7, ubuntu16)

1 个赞