| From | Sent On | Attachments |
|---|---|---|
| Jérôme Bolliet | Jan 8, 2003 4:19 am | |
| Roland Schneider | Jan 8, 2003 6:05 am | |
| Jérôme Bolliet | Jan 9, 2003 3:51 am | |
| Xavier Beaudouin | Jan 9, 2003 4:28 am | |
| Roland Schneider | Jan 9, 2003 5:09 am | |
| Sam Varshavchik | Jan 9, 2003 5:11 am | |
| Xavier Beaudouin | Jan 9, 2003 5:54 am | |
| Jérôme Bolliet | Jan 9, 2003 6:37 am | |
| Brian Candler | Jan 9, 2003 7:00 am | |
| Jérôme Bolliet | Jan 9, 2003 7:46 am | |
| Brian Candler | Jan 9, 2003 7:59 am | |
| Xavier Beaudouin | Jan 9, 2003 8:04 am | |
| bi...@mics.org.uk | Jan 9, 2003 8:15 am | |
| Jérôme Bolliet | Jan 9, 2003 8:43 am | |
| Matt Pavlovich | Jan 9, 2003 8:56 am | |
| Brian Candler | Jan 9, 2003 9:06 am | |
| Xavier Beaudouin | Jan 9, 2003 9:46 am | |
| Gordon Messmer | Jan 9, 2003 2:22 pm | |
| Gordon Messmer | Jan 9, 2003 2:23 pm | |
| Sam Varshavchik | Jan 9, 2003 2:56 pm | |
| Sam Varshavchik | Jan 9, 2003 2:56 pm | |
| Xavier Beaudouin | Jan 9, 2003 3:49 pm | |
| Xavier Beaudouin | Jan 9, 2003 4:03 pm | |
| Jérôme Bolliet | Jan 9, 2003 11:43 pm |
| Subject: | Re: [courier-users] Re: problem courier pop3d & load average | |
|---|---|---|
| From: | Xavier Beaudouin (ki...@oav.net) | |
| Date: | Jan 9, 2003 8:04:41 am | |
| List: | net.sourceforge.lists.courier-users | |
[... snip ...]
solaris... With about > 600 000 users, so I may be don't know what I am talking about...
Look at the code for handling the cache file. 1. It opens and reads the courierpop3dsizelist file (if any) 2. For all files which are in the mailbox but not in the cache, it works out the size as before. For all files which are in the cache but not in the directory listing, they are forgotten about. 3. It then writes the updated cache to a temporary file and then does an atomic rename to 'courierpop3dsizelist'. At all instants the file is complete and valid. There is no need to lock the file. There is no race condition.
To move the temporary file, you need to delete the current courierpop3dsizelist before. In this case, what is happen if another pop3d process try to access between the delete and the move.
Good question... For me this case, this is what I can call race.
On some NFS client (not server) : rename is atomic, but remove (delete) can be atomic or not, appending gets the same problems as well.
Yeah I agree that *some* opensource NFS client (Linux, FreeBSD for example) gets such call as atomic, but on Solaris, for example, _only_ rename is atomic, because OS cache read / append into its local VFS cache before commiting on the NFS server...
That's why I say that rely on some cache files on a maildir loose all the advantages off maildir on a distributed environment.
Caching in files maybe a good idea, we have moved the cache from NFS to local cache on disk, this give us same functionality and avoid some race conditions.
Except theses parts I think that courier-imap is a neat work and a good piece of software...
/Xavier
-- Xavier Beaudouin - Unix System Administrator & Projects Leader. For mail address, please check header of this mail. Spams are not accepted. Caudium: http://caudium.net/ Making friends with FreeBSD: Just because the system has panicked doesn't mean that you should panic too





