Gentoo Archives: gentoo-dev

From: Tobias Klausmann <klausman@g.o>
To: gentoo-dev@l.g.o
Subject: Re: [gentoo-dev] Lib_users, a post-upgrade helper
Date: Wed, 28 Jul 2010 15:55:36
Message-Id: 20100728155522.GA9874@kaini.schwarzvogel.de
In Reply to: Re: [gentoo-dev] Lib_users, a post-upgrade helper by Jeroen Roovers
1 Hi!
2
3 On Wed, 28 Jul 2010, Jeroen Roovers wrote:
4 > > While that approach has the advantage of not only catching mapped
5 > > files but every open FD, I am thinking about implementing something
6 > > similar with lib_users (but using /proc/<pid>/fd/).
7 >
8 > The great advantage would be that it also discovers changed runtime
9 > configuration files. Not that it would also disregard "trivial"
10 > updates, of course, but by pointing out the filenames, an admin having
11 > just run etc-update could easily figure that out.
12
13 I suspect that wouldn't work in most cases since programs
14 typically close FDs after reading the config file(s)*. The one
15 program I know of that doesn't, uses the FD to find out the file
16 changed and does file-was-deleted handling internally.
17
18 Still, if config files aren't the only useful case for checking
19 the FDs, it might be worthwhile to implement.
20
21 Regards,
22 Tobias
23
24 * This is a /good/ thing.