At 13:55 -0500 03/20/2005, Theo Van Dinter wrote: >Well, that's not sendmail rereading the config. "newaliases" generates >a new DBM/hash file from a flat text file. Sendmail then realizes the >file (that it has open) has changed and reopens the new file for access. >The DB is a lookup table, not a "config" (ala sendmail.cf).
Duh. >Sendmail then realizes the >file (that it has open) has changed and reopens the new file for access. This is what we programmers call an "implementation detail". if spamd/spamc already _had_ the code to do what I want I wouldn't be asking for it, now would I? At 11:24 +0900 03/21/2005, alan premselaar wrote: >For clarity's sake, sendmail has real-time access to certain db files >(like aliases.db which is generated by 'newaliases'). since sendmail has >real-time access to these files, re-creating the .db file from the text >version is all that is necessary. Uhuh. >in order to read the config file in >only when it has been changed< you >need to store state information somewhere uhuh. > >when fine-tuning for performance, even a call to stat() on a file or >group of files can introduce performance hits. This is because it >effectively still has to open and close the file-handle. "options". Recall that I did say "an option to...'. I will accept the hit (which I personally think wouldn't be big enough to notice). Theo Van Dinter >This is a very standard method of having a daemon notice a config change. But this is a daemon that notices changes in user prefs files in real time so the performance issue is spurious. It's _already_ taking a performances hit _every single time_ for every single user. -- Vicki Brown ZZZ Journeyman Sourceror: zz |\ _,,,---,,_ Code, Docs, Process, Scripts & Philtres zz /,`.-'`' -. ;-;;,_ Perl, WWW, Mac OS X http://cfcl.com/vlb |,4- ) )-,_. ,\ ( `'-' SF Bay Area, CA USA _______________________ '---''(_/--' `-'\_) ___________________________