Ton of random units "could not be found"

Andrei Borzenkov arvidjaar at gmail.com
Sat Dec 16 07:08:19 UTC 2023


On 16.12.2023 08:17, chandler wrote:
> Hi all,
> 
>      When I run `systemctl status --all` I see a ton of "Unit X could not
> be found" where X = an item from the list below.  How did this mess
> happen and how to clean it up?  None of these units represent things the
> system is using, for the most part.
> 

There is no mess. Units, listed as dependencies in Wants, After, Before, 
do not need to exist. It is pretty common when a project ships units 
listing other well-known units as dependency, so if they are added, your 
program just continues to work without any manual adjustments.

>      Some units appear to be remnants left behind in /etc/systemd, for
> example /etc/systemd/system/ntp.service is a symlink pointing to
> non-existent /lib/systemd/system/ntpsec.service.  I can delete
> /etc/systemd/system/ntp.service and after `systemctl daemon-reload` it's
> now gone from the list below.
> 
>      Other items have different situations, like tmp.mount exists at
> /usr/share/systemd/tmp.mount but isn't an enabled unit or anything, if I
> try to enable or unmask it I'm just told "Unit tmp.mount could not be
> found." or "Unit file tmp.mount does not exist."
> 
> systemd is 252.19-1~deb12u1 from Debian 12 bookworm/main repo
> 
> Thanks
> 
> boot.automount
> home.mount
> tmp.mount
> ntpsec-systemd-netif.path
> auditd.service
> clamav-daemon.service
> connman.service
> console-screen.service
> display-manager.service
> fcoe.service
> greylist.service
> ip6tables.service
> ipset.service
> iptables.service
> iscsi-shutdown.service
> iscsi.service
> iscsid.service
> kbd.service
> mysql.service
> NetworkManager.service
> ntp.service
> ntpsec.service
> plymouth-quit-wait.service
> plymouth-start.service
> postgresql.service
> rbdmap.service
> spamassassin.service
> systemd-hwdb-update.service
> systemd-oomd.service
> systemd-update-done.service
> systemd-vconsole-setup.service
> ntpsec-rotate-stats.timer
> 



More information about the systemd-devel mailing list