Gentoo Archives: gentoo-user

From: Peter Humphrey <peter@××××××××××××.uk>
To: gentoo-user@l.g.o
Subject: Re: [gentoo-user] Is there a way to list orphaned services?
Date: Fri, 13 Dec 2019 15:25:59
Message-Id: 2824297.nKZxY4O2OR@peak
In Reply to: Re: [gentoo-user] Is there a way to list orphaned services? by Mick
1 On Friday, 13 December 2019 11:17:26 GMT Mick wrote:
2 > On Friday, 13 December 2019 07:47:43 GMT Neil Bothwick wrote:
3 > > On Thu, 12 Dec 2019 16:52:21 -0800, Daniel Frey wrote:
4 > > > I've been merging/unmerging packages for testing and some have to be
5 > > > started via a daemon, so I've had to add them to /etc/runlevels/* via
6 > > > rc-update.
7 > > >
8 > > > The problem is I was removing packages without doing `rc-update del
9 > > > <service> <runlevel>`, leaving them added in the runlevel with no valid
10 > > > script/symlink.
11 > > >
12 > > > Now, I could just do `ls -al /etc/runlevels/*` and search manually for
13 > > > broken symlinks and then manually remove them.
14 > >
15 > > How about:
16 > >
17 > > find -L /etc/runlevels -type l
18
19 That returns a null result here.
20
21 > I seem to also have a few dangling on an old PC here!
22 >
23 > $ find -L /etc/runlevels -type l
24 > /etc/runlevels/boot/tmpfiles.setup
25 > /etc/runlevels/boot/alsasound
26 > /etc/runlevels/boot/swapfiles
27 > /etc/runlevels/default/modules-load
28 > /etc/runlevels/default/vixie-cron
29 >
30 > Is it a matter of just deleting them?
31
32 I think so, as they don't point to anything. I don't have any of them here.
33
34 Here, tmpfiles.setup is opentmpfiles.setup, and swapfiles is swap, so I
35 imagine those can go. If no package owns any of them, I can't imagine any harm
36 coming from deleting them.
37
38 --
39 Regards,
40 Peter.