Re: Cyrus process model...
It is always a big pain to update code that was never written to be threaded, to be thread-safe. Apache2 has a problems with just about every third party module supported under Apache 1.3. I imagine that Cyrus would have all sorts of thread issues. There is no magic solution for that. Besides, if anyone really wants to take Cyrus to the next generation, create a new NG branch in CVS (on your own CVS server if necessary), and start refactoring away. (Of course, refactoring has to be the most overused term in software development at the moment, and is touted as a solution for everything from bad design, to poor management). Tom On Tue, 25 Feb 2003, David Lang wrote: as someone attempting to get apache 2 running (reliably) in a high volume environment I can say the idea is interesting, but I definantly wouldn't rush into useing it. if you have some time and want to get a start on something that may (or may not) be worth doing in the long run you can start on it, but don't stop maintaining the current version, the apache core code may not be the right thing in the long run. David Lang On Wed, 26 Feb 2003, Rob Mueller wrote: Date: Wed, 26 Feb 2003 16:45:00 +1100 From: Rob Mueller [EMAIL PROTECTED] To: Lawrence Greenfield [EMAIL PROTECTED], Rob Siemborski [EMAIL PROTECTED] Cc: Ken Murchison [EMAIL PROTECTED], info-cyrus [EMAIL PROTECTED] Subject: Cyrus process model... [ Continued from an off mailing list conversation about killing cyrus lmtpd processes when they go haywire, and cyrus process accounting ] Surely this is a relatively well solved problem? Just about every unix system uses this master/forked child approach? How does apache do it? Net::Server::PreFork? I can't imagine that there aren't cookbook solutions to this issue since it's what unix has been doing for 30 years? Or is there something I'm missing here? There are many different possibilities. Most other systems limit the number of clients instead of forking new processes on demand without a set limit. Apache also doesn't have differentiated children or substantial shared state. (All children are members of the same service or you don't particularly care how many additional unused children you have...) I was under the impression that Apache 2 was planning on making it's forking/threading model much more generic, and supporting a general 'services' model, including a library to abstract the underlying OS? Hmmm, looking into that, it appears that it's mostly done already. http://apr.apache.org/ http://apr.apache.org/apr2_0intro/apr2_0intro.htm And more: Contains following functionality -Reading and writing of files -Character set conversion -Network communications using sockets -Time management used for Internet type conversions -String management like C++ including natural order management -UNIX Password management routines -Table management routines -UUID Internet generation -Filename canonicalization -Random data generation -Global lock management -Threads and process management -Dynamic library loading routines -Memory mapped and shared memory - http://www.arctic.org/~dean/apache/2.0/process-model.html I think the above is general enough to implement the interesting process models, and to implement optimizations that are available only in some of the multi-threaded models. Note that nothing above is specific to HTTP, and I believe that we should strive to keep the abstraction so that the same libraries can be used to implement other types of servers (i.e. FTP, streaming video/audio, corba). - Would the cyrus team think it worthwhile to consider refactoring to use the new Apache 2 APR modules? I know off hand that it would be a lot of work, but it could be a gradual re-factoring process, and the idea of actually reusing code between projects would be *really* nice. Joel Spolsky is a big proponent of refactoring over time to improve software and you can read some of his thoughts here. http://www.joelonsoftware.com/articles/fog69.html http://www.joelonsoftware.com/news/fog000328.html Ooops, I'm feeling a rant come along... *** RANT MODE *** I know this is a little off topic, but the source for cyrus is really showing it's age a bit. I know that happens with all software, you start with certain assumptions, and the more you go on, the more the original assumptions get blown away, so you hack this in here, and there, and then every now and then, you go on a big cleanup spree! The problem I feel is that the cleanup hasn't been big enough or often enough. Also, over time programming habits change. Many old C idioms are pretty much dead. Most of the C string handling methods are now annoying, or downright dangerous. There are several dozen replacement libraries, including the APR one above, and good
Re: seen flag for multiple users // cyrus and procmail
On Tuesday 25 February 2003 18:02, Kristian Rink wrote: the archive of this list, it is not possible in cyrus (in IMAP?) to have a general seen flag for mails or mailboxes so this way it is impossible for any user who is able to read mail in the shared mailboxes to find out whether or not anyone else already has read I've got a similar solution. So far my solution was to create a special user account which everyone uses in addition to their own. But then there is only one deleted flag; if one user deletes a mail the others don't see it at all. Now I'm looking for a way to have a per-user deleted flag, but keeping the users from expunging that mailbox and do it automatically when everyone has marked a mail as deleted. What I really want is: a global seen, per-user deleted, and automatic only expunge... MfG, Ulrich -- Heinz Ulrich Stille / Tel.: +49-541-9400463 / Fax: +49-541-9400450 design_d gmbh / Lortzingstr. 2 / 49074 Osnabrück / www.design-d.de
Deleting records from db
Hello, I have an annoying problem: my collegue deleted phisically the directories from the user's directory, so the system, while attempting to delivery a message to a mailbox returns a I/O Error. Correct until here. I need to remove the entries from the mailbox database, but I can't find the way. Anybody has an idea? I am using the following configuration: * Cyrus IMAPD 2.1.11 * Cyrus SASL 2.1.9 * Berkeley DB 4.1.24 * Postfix 1.1.12 * Users are authenticated through LDAP (pam_ldap) * Aliases are managed by LDAP * Delivery to mailbox made through LMTP TIA, En3pY -- Sebastian Konstanty Zdrojewski IT Analyst Neticon S.r.l. via Valtellina, 16 - 20159 Milano Tel. +39 02 68.80.731 FAX +39 02.60.85.70.41 Cell. +39 349.33.04.311 ICQ # 97334916 -- Web: http://www.neticon.it/ E-mail: [EMAIL PROTECTED]
Re: cyradm not authenticating
I had a similar problem at the beginning... try to check your imapd.conf file, maybe there is a problem while specifying the uthentication method. Here is a sample I am using for test: sasl_pwcheck_method: saslauthd mech_list: plain It works for me. Check also if the libsasl2 is available in the search path (ldconf and so on...) Hope to be helpful! :) Best Regards En3pY Petre Agenbag wrote: Hi List I downloaded the latest cyrus-imap and cyrus-sasl sources onto my RedHat8.0 system. I built cyrus sasl without any problems and started saslauthd Then I proceeded to built cyrus-imap with the following configure commands: --without-krb --with-auth=unix --with-perl=/usr/bin/perl Afterwards I moved all the perl modules to the correct locations and rebuilt my sendmail.cf as per documentation. MAster starts without any problems. However, when I try to enter cyradm as follow: cyradm --auth login localhost --user cyrus IMAP Password: Login failed: no mechanism available at /usr/lib/perl5/5.8.0/Cyrus/IMAP/Admin.pm line 114 cyradm: cannot authenticate to server with login as cyrus I can however use cyradm to administer a remote server, so it seems cyradm is working, but my local auth is bunged? Any ideas or help? -- Sebastian Konstanty Zdrojewski IT Analyst Neticon S.r.l. via Valtellina, 16 - 20159 Milano Tel. +39 02 68.80.731 FAX +39 02.60.85.70.41 Cell. +39 349.33.04.311 ICQ # 97334916 -- Web: http://www.neticon.it/ E-mail: [EMAIL PROTECTED]
Re: Deleting records from db
Sebastian Konstanty Zdrojewski wrote: Hello, I have an annoying problem: my collegue deleted phisically the directories from the user's directory, so the system, while attempting to delivery a message to a mailbox returns a I/O Error. Correct until here. I need to remove the entries from the mailbox database, but I can't find the way. Anybody has an idea? do reconstruct the mailbox -- Dimitry
Re: Cyrus IMAPd 2.1.12 Released
On Tue, Feb 25, 2003 at 01:32:14PM -0600, Christopher Crowley wrote: ... I applied a patch that I found in the e-mail archives. (http://asg.web.cmu.edu/archive/message.php?mailbox=archive.cyrus-sasl msg=2965) So now lib/Makefile.am is: # diff Makefile.am Makefile.am.orig that was for Makefile.am Ran make clean, make distclean. but you must now regenerate the Makefile from Makefile.am. Simplest might be rm configure; sh SMakefile then, configure and make.. Cheers, Patrick
Re: Deleting records from db
Hi, I tried with this: localhost.localdomain reconstruct user.mailboxname reconstruct: Operating System Error The imapd.log file appended the following line: Feb 26 16:08:48 nexus imapd[30158]: Reconstructing 'user.massimiliano_rovatti' (not recursive) for user 'postmaster' Sorry for boring... I would like to get out of this problem without deleting the entire database... Best regards, En3pY Dmitry Alyabyev wrote: Sebastian Konstanty Zdrojewski wrote: Hello, I have an annoying problem: my collegue deleted phisically the directories from the user's directory, so the system, while attempting to delivery a message to a mailbox returns a I/O Error. Correct until here. I need to remove the entries from the mailbox database, but I can't find the way. Anybody has an idea? do reconstruct the mailbox -- Sebastian Konstanty Zdrojewski IT Analyst Neticon S.r.l. via Valtellina, 16 - 20159 Milano Tel. +39 02 68.80.731 FAX +39 02.60.85.70.41 Cell. +39 349.33.04.311 ICQ # 97334916 -- Web: http://www.neticon.it/ E-mail: [EMAIL PROTECTED]
Cyrus in shared-only setup with no user inboxes?
Hi everyone, I remember reading a message like this back in the 1997 archives, but maybe (hopefully?) something's changed in the newer versions. I'm intending to use Cyrus and shared IMAP folders as a replacement for a currently-running private NNTP server for small-scale discussion groups. No problem, as I know how to do the Cyrus ACLs. My question is if it possible to run Cyrus without individual user inboxes, such that the users exist in the ACL database, but that's it. What functionality is lost by not giving users individual mailboxes? Is it possible to have a single shared user inbox, somehow hidden from the user, just so Cyrus is happy? Basically, I don't want to give people mailboxes in any form. They don't need them, and shouldn't have them at all. I look forward to your responses. Thanks! -- Scott Balmos
Re: Deleting records from db
On Wed, 26 Feb 2003, Sebastian Konstanty Zdrojewski wrote: Hi, I tried with this: localhost.localdomain reconstruct user.mailboxname reconstruct: Operating System Error The imapd.log file appended the following line: Feb 26 16:08:48 nexus imapd[30158]: Reconstructing 'user.massimiliano_rovatti' (not recursive) for user 'postmaster' Sorry for boring... I would like to get out of this problem without deleting the entire database... I encountered this exact situation (directories manually deleted, leading to an unreconstructable mailbox) about a month ago. The solution we chose was to export the mailboxes db (ctl_mboxlist -d), delete the bogus entries from the textfile, then import it back in. However, this may not be the Right Way to fix it. In our case the server was down anyway (the damaged mailbox had killed an overnight quota check and corrupted the quota db), so this brute force and ignorance approach made sense at the time. -- Simon Brady mailto:[EMAIL PROTECTED] ITS Technical Services University of Otago, Dunedin, New Zealand
Re: Deleting records from db
Thank you. I am in a similar situation like yours, because the server is still in test mode, so I can apply this solution. Thanks for help! :) Have a nice day, En3pY Simon Brady wrote: On Wed, 26 Feb 2003, Sebastian Konstanty Zdrojewski wrote: Hi, I tried with this: localhost.localdomain reconstruct user.mailboxname reconstruct: Operating System Error The imapd.log file appended the following line: Feb 26 16:08:48 nexus imapd[30158]: Reconstructing 'user.massimiliano_rovatti' (not recursive) for user 'postmaster' Sorry for boring... I would like to get out of this problem without deleting the entire database... I encountered this exact situation (directories manually deleted, leading to an unreconstructable mailbox) about a month ago. The solution we chose was to export the mailboxes db (ctl_mboxlist -d), delete the bogus entries from the textfile, then import it back in. However, this may not be the Right Way to fix it. In our case the server was down anyway (the damaged mailbox had killed an overnight quota check and corrupted the quota db), so this brute force and ignorance approach made sense at the time. -- Simon Brady mailto:[EMAIL PROTECTED] ITS Technical Services University of Otago, Dunedin, New Zealand -- Sebastian Konstanty Zdrojewski IT Analyst Neticon S.r.l. via Valtellina, 16 - 20159 Milano Tel. +39 02 68.80.731 FAX +39 02.60.85.70.41 Cell. +39 349.33.04.311 ICQ # 97334916 -- Web: http://www.neticon.it/ E-mail: [EMAIL PROTECTED]
Re: Cyrus in shared-only setup with no user inboxes?
Scott Balmos wrote: Hi everyone, I remember reading a message like this back in the 1997 archives, but maybe (hopefully?) something's changed in the newer versions. I'm intending to use Cyrus and shared IMAP folders as a replacement for a currently-running private NNTP server for small-scale discussion FYI. Cyrus 2.2 (not yet released) includes a NNTP daemon. So you can feed via NNTP and read via IMAP or vice versa. groups. No problem, as I know how to do the Cyrus ACLs. My question is if it possible to run Cyrus without individual user inboxes, such that the users exist in the ACL database, but that's it. What functionality AFAIK, Cyrus doesn't care. is lost by not giving users individual mailboxes? Other than the user not having an INBOX, nothing. Your IMAP clients might have an issue however (I've never tried it). -- Kenneth Murchison Oceana Matrix Ltd. Software Engineer 21 Princeton Place 716-662-8973 x26 Orchard Park, NY 14127 --PGP Public Key--http://www.oceana.com/~ken/ksm.pgp
Re: Cyrus in shared-only setup with no user inboxes?
Hello, We are in the process of setting up a machine just to do shared folders. There will be no user accounts on the machine. Their accounts are on other servers. We use kerberos for authentication, so once the ACL for their id is setup all they need to do is create the account in the client that they will use so that it accesses the correct machine, in addition to the machine where there regular inbox is. How you set up authentication may impact your ability to do this. We are using version 2.1.11 of cyrus. Regards, Earl Shannon Scott Balmos wrote: Hi everyone, I remember reading a message like this back in the 1997 archives, but maybe (hopefully?) something's changed in the newer versions. I'm intending to use Cyrus and shared IMAP folders as a replacement for a currently-running private NNTP server for small-scale discussion groups. No problem, as I know how to do the Cyrus ACLs. My question is if it possible to run Cyrus without individual user inboxes, such that the users exist in the ACL database, but that's it. What functionality is lost by not giving users individual mailboxes? Is it possible to have a single shared user inbox, somehow hidden from the user, just so Cyrus is happy? Basically, I don't want to give people mailboxes in any form. They don't need them, and shouldn't have them at all. I look forward to your responses. Thanks! -- Scott Balmos
Re: Cyrus process model...
It is always a big pain to update code that was never written to be threaded, to be thread-safe. Apache2 has a problems with just about every third party module supported under Apache 1.3. I imagine that Cyrus would have all sorts of thread issues. There is no magic solution for that. I'm not convinced that it's necessary to make it thread safe. In many situations I think threads are a step backwards. While it always feels a bit odd to think of it as a positive, the multiple process model introduces an inherent stability, even for non-optimal (buggy) code that can crash a process. In that case, only one connection/instance is lost, and no-one else is affected. In multithreaded code, one bad crashed thread *can* take out the entire process and all connections. Of course, if your code has to share a lot of information between each 'instance', then threads are very useful. In the case of cyrus, I think you can quite happily stick with the multi-process model, I wasn't advocating moving to a threaded model. The discussion started due to an issue with killing child processes. Apparently there are currently race conditions in 'master' that means that a killed child may not be correctly recognised by the 'master' process as a dead child. I commented that I thought a master/forked child idiom had been used in unix for 30 years, and shouldn't there be cookbook solutions for most of these issues? Which started me looking for libraries that might have already done this... Besides, if anyone really wants to take Cyrus to the next generation, create a new NG branch in CVS (on your own CVS server if necessary), and start refactoring away. (Of course, refactoring has to be the most overused term in software development at the moment, and is touted as a solution for everything from bad design, to poor management). The thing is, in my experience, refactoring actually works, regardless of it's buzz word of the week or not. Better yet, *continuous* refactoring seems to work the best! Hmmm, not that I find that easy to define. I guess it's being aware as you work on a project, which parts are clearly beginning to feel 'wrong' (hmmm, more subjective thoughts...), and devoting some time to actually fixing up those problem areas. This is generally a lot easier if you're good at creating interfaces and sticking to them. Of course, being forced to work around an interface is one of the clear signs of something being 'wrong'. Rob
Re: Cyrus process model...
I will also add that on current *nix systems the advantages of threads over processes is a lot less then it used to be. In my case we are running apache2 on AIX and found no noticable difference between the two (so we are useing processes for the stability reasons you note below) David Lang On Thu, 27 Feb 2003, Rob Mueller wrote: It is always a big pain to update code that was never written to be threaded, to be thread-safe. Apache2 has a problems with just about every third party module supported under Apache 1.3. I imagine that Cyrus would have all sorts of thread issues. There is no magic solution for that. I'm not convinced that it's necessary to make it thread safe. In many situations I think threads are a step backwards. While it always feels a bit odd to think of it as a positive, the multiple process model introduces an inherent stability, even for non-optimal (buggy) code that can crash a process. In that case, only one connection/instance is lost, and no-one else is affected. In multithreaded code, one bad crashed thread *can* take out the entire process and all connections. Of course, if your code has to share a lot of information between each 'instance', then threads are very useful. In the case of cyrus, I think you can quite happily stick with the multi-process model, I wasn't advocating moving to a threaded model. The discussion started due to an issue with killing child processes. Apparently there are currently race conditions in 'master' that means that a killed child may not be correctly recognised by the 'master' process as a dead child. I commented that I thought a master/forked child idiom had been used in unix for 30 years, and shouldn't there be cookbook solutions for most of these issues? Which started me looking for libraries that might have already done this... Besides, if anyone really wants to take Cyrus to the next generation, create a new NG branch in CVS (on your own CVS server if necessary), and start refactoring away. (Of course, refactoring has to be the most overused term in software development at the moment, and is touted as a solution for everything from bad design, to poor management). The thing is, in my experience, refactoring actually works, regardless of it's buzz word of the week or not. Better yet, *continuous* refactoring seems to work the best! Hmmm, not that I find that easy to define. I guess it's being aware as you work on a project, which parts are clearly beginning to feel 'wrong' (hmmm, more subjective thoughts...), and devoting some time to actually fixing up those problem areas. This is generally a lot easier if you're good at creating interfaces and sticking to them. Of course, being forced to work around an interface is one of the clear signs of something being 'wrong'. Rob
Re: Cyrus process model...
From: Rob Mueller [EMAIL PROTECTED] Date: Thu, 27 Feb 2003 08:22:09 +1100 [...] In the case of cyrus, I think you can quite happily stick with the multi-process model, I wasn't advocating moving to a threaded model. The discussion started due to an issue with killing child processes. Apparently there are currently race conditions in 'master' that means that a killed child may not be correctly recognised by the 'master' process as a dead child. I commented that I thought a master/forked child idiom had been used in unix for 30 years, and shouldn't there be cookbook solutions for most of these issues? Which started me looking for libraries that might have already done this... Sigh. It is _not_ a race condition in master. Master is working just fine. The services do not always deal correctly with receiving signals. The process accounting patch for master (which works around the services not always doing the right thing) introduces race conditions, which is one of the reasons why it hasn't been applied. Being able to deal with kill -9 processes is definitely _not_ a design goal, since kill -9 can leave the mail spool in an arbitrary corrupted state. Larry
cyradm authentication error
All, I'm hoping someone can help me with this issue. I have a new install with Redhat 8.0. I used the sasl RPM 2.1.7-2. I downloaded and installed cyrus imap version 2.1.12. My imapd.conf file looks as follows: configdirectory: /var/imap partition-default: /var/spool/imap admins: cyrus root sasl_pwcheck_method: saslauthd I can successfully authenticate using the imtest command. When I tried to use cyradm, I originally got a can't locat Cyrus/IMAP/Shell.pm in @INC. I moved all necessary (I think) folders from the folder they were installed in (/user/local/lib instead of /user/lib) to be included in the path. Now when I run cyradm, the program just hangs and I get the following error in my imapd.log file: badlogin: web01[127.0.0.1] DOGEST-MD% [SASL(-13): authentication failure: client response doesn't match what we generated]. When I enter the sasldblistuser2 command, I get the following: [EMAIL PROTECTED]: userPassword. Would someone PLEASE help me with this problem? I noticed a couple other postings with this error message, but no responses. Thank you, Kevin Williams