Author: Tamas TEVESZ Date: To: Richard Gilbert CC: exim-users Subject: Re: [Exim] Persistent DB connections to MySQL database
On Thu, 16 May 2002, Richard Gilbert wrote:
> I was going to use MySQL but I have realised that I don't need the power
> of MySQL because I still only need to make single key look ups. I was
> thinking I could instead go back to Exim using NDBM and update that on the
> fly. What I would like to know is whether it would be safe to update the
> NDBM database used by Exim directly or whether I would need to lock it.
i would not do that. rebuild it into a different file, then use either
soft or hardlinks. at least one of these operations are atomic in most
kernels (to the best of my knowledge; check your os and the archives,
we had a discussion about that some time ago), so this approach will
give you an always-consistent state (while things like building the
new database over the existing one, or removing then copyong, or just
moving won't neccessarily.)