我的手术室是ubuntu 22.04。在进入终端后,将显示以下消息:
ubuntu-advantage-desktop-daemon.service is a disabled or a static unit not running, not starting it.如何解决这个问题?
发布于 2023-02-18 12:58:26
与您一样,我在将XUbuntu升级到jammy (22)后也遇到了相同的错误消息。所以我不习惯这个错误,但是我发现的可能对你有帮助。所有命令都必须以根用户身份执行,或者建议使用sudo前缀执行:
ubuntu-advantage-desktop-daemon和ubuntu-advantage-tools。守护程序包的一个已安装文件是/lib/systemd/system/ubuntu-advantage-desktop-daemon.service,,即所谓的单元文件。试图通过systemctl enable ubuntu-advantage-desktop-daemon.service启用它会导致以下错误消息:
单元文件没有安装配置(WantedBy=、RequiredBy=、Also=、安装部分中的Alias=设置和模板单元的DefaultInstance= )。这意味着不打算使用systemctl启用它们。拥有这类单元的可能原因是:·单元可以通过从另一个单元的.欲望/或. .requires/目录中被符号链接来静态地启用。·一个单位的目的可能是作为另一个对其有需求依赖的单位的帮助者。在需要时可以通过激活(套接字、路径、计时器、D总线、udev、脚本系统call调用、.)启动单元。如果是模板单元,则使用指定的实例名称启用该单元。
我所做的:
systemctl disable ubuntu-advantage.service
systemctl enable ubuntu-advantage.service
systemctl disable ubuntu-advantage-desktop-daemon.service (issues error message)
systemctl start ubuntu-advantage-desktop-daemon.service然后
systemctl -a|grep ubuntu显示
ubuntu- Advantage -cloud-id-shim.service --未找到非活动死Ubuntu -Advantage-id-shim.service Ubuntu -Advantage-桌面-daemon.service加载了Ubuntu Advantage ubuntu-advantage.service非活动Ubuntu Pro后台自动附加服务
在下一次重新启动之后,ubuntu-advantage-desktop-daemon.service既没有运行也没有加载,而是可以由systemctl start ubuntu-advantage-desktop-daemon.service启动。
因为我不想要Ubuntu的商业优势,所以我做了
systemctl disable ubuntu-advantage-desktop-daemon.service和
systemctl disable ubuntu-advantage.service由于您没有详细描述错误信息在您的终端中发生的情况,我无法帮助您更多。
有关服务和单元文件的更多信息,您可以在这里找到:https://linuxhandbook.com/create-systemd-services/
https://askubuntu.com/questions/1455481
复制相似问题