DragonFly kernel List (threaded) for 2003-12
Re: libcaps thread testing code committed
On Tue, Dec 09, 2003 at 10:32:16AM -0800, Matthew Dillon wrote:
> One interesting fallout of using the IPC mechanism is that we no longer
> have to DBM system files. The IPC server's flat file support can load
> the flat file once and hash it in memory, and then simply check to see
> if it has been modified. If kqueue() does not already have the ability
> to detect file modifications we can add that feature (I seem to recall
> that kqueue does have the ability, or is very close to having the ability).
The problem is there are two ways to update the config files in /etc.
For files like master.passwd a copy is edited and then renamed
atomically. That is fine for automatic rebuilding. Others like
/etc/hosts don't have such functionality and rebuilding them as soon
as they change feels wrong.
What I thought about is using internally DBM or the even simpler CDB
files and rebuild them either when the source changes or the user
requests an update. This can happen in a separate daemon. As soon
as the IPC server detects a change in its database directory, it
reopens the DB files and starts using the new versions. One side
effect is that this allows the IPC server to run fully chrooted
when using just DB files or network services as backends.
> Matthew Dillon