cyrus-2.2-cvs: virtualdomains and sendmail virtusertable (cyrusv2as local mailer)

2002-12-16 Thread Christian Schulte
Hi,

after changing the local mailer in my sendmail.mc from cyrus to cyrusv2 
I cannot get sendmail to correctly deliver the domain-part of 
local-adresses to cyrusv2-lmtpd! Before, I had the cyrusv2-mailer set in 
/etc/mail/mailertable but that way , I was not able to route my email as 
I need to and as I do in /etc/mail/virtusertable. Ecspacially 
catchall-accounts for domains which have more than one email-account in 
cyrus are not possible with the mailertable approach.

I have all my local domains in /etc/mail/local-host-names and do (want 
to do) all email routing in /etc/mail/virtusertable like before.

If I specify a final recipient (cyrus-account) in virtusertable as:

@virtualdomain.it	[EMAIL PROTECTED]

where an account like [EMAIL PROTECTED] exists, sendmail 
recognizes virtualdomain.it in /etc/mail/local-host-names as a local 
domain and will strip the original virtualdomain.it from the recipient 
replacing it with the localhost hostname. All domains defined in 
/etc/mail/local-host-names will be recognized in virtusertable but the 
local delivery will only go to the user@localhostname!

Where can I change sendmail to not do that ? How do I tell sendmail to 
never change the local-domain to the local hostname on succesfully 
recognized /etc/mail/local-host-names domains ?

--Christian--



Re: cyrus-2.2-cvs: virtualdomains and sendmail virtusertable (cyrusv2as local mailer)

2002-12-16 Thread Jonathan Marsden
On 16 Dec 2002, Christian Schulte writes:

 If I specify a final recipient (cyrus-account) in virtusertable as:

 @virtualdomain.it [EMAIL PROTECTED]

 where an account like [EMAIL PROTECTED] exists, sendmail
 recognizes virtualdomain.it in /etc/mail/local-host-names as a local
 domain and will strip the original virtualdomain.it from the
 recipient replacing it with the localhost hostname. All domains
 defined in /etc/mail/local-host-names will be recognized in
 virtusertable but the local delivery will only go to the
 user@localhostname!

 Where can I change sendmail to not do that ? How do I tell sendmail
 to never change the local-domain to the local hostname on
 succesfully recognized /etc/mail/local-host-names domains ?

There are almost certainly neater ways, but I just patched
sendmail.cf/m4/proto.m4 to do that.

--- proto.m4.20020613   Thu Jun 13 11:53:24 2002
+++ proto.m4Thu Dec 12 01:54:08 2002
@@ -1092,8 +1092,8 @@
 dnl $H empty (but @$=w.)
 R  $+ + $*  $+ $#_LOCAL_ $: $1 + $2plussed name?
 R  $+  $+  $#_LOCAL_ $: @ $1   nope, local address',
-`R$=L  @ $=w .   $#_LOCAL_ $: @ $1   special local names
-R$+  @ $=w . $#_LOCAL_ $: $1 regular local name')
+`R$=L  @ $=w .   $#_LOCAL_ $: @ $1`@'$2  special local names
+R$+  @ $=w . $#_LOCAL_ $: $1`@'$2regular local 
+name')
 
 ifdef(`_MAILER_TABLE_', `dnl
 # not local -- try mailer table lookup

Jonathan
--
Jonathan Marsden| Internet: [EMAIL PROTECTED] | Making electronic 
1252 Judson Street  | Phone: +1 (909) 795-3877  | communications work 
Redlands, CA 92374  | Fax:   +1 (909) 795-0327  | reliably for Christian 
USA | http://www.xc.org/jonathan| missions worldwide 



Cyrus Startup-Check

2002-12-16 Thread Christian Bomhardt
Hallo,

I run cyrus with fetchmail. Every night, a cron script stopps cyrus and
fetchmail, tars the mail folders and restarts cyrus and fetchmail. My
problem is, that fetchmail is too fast and tries to deliver mail via lmtp,
before cyrus is ready - so the mail is moved to the local root mail account
and not into the cyrus mail spool.

Has anybody any Idea how to check if cyrus is ready to receive mail before
restarting fetchmail from within a cron script?

Second: the syslog is flooded with imapd[xx]: startttls: ... login: ...
-messages. How can this be stopped?

Thanks,
Christian Bomhardt




Re: cyrus-2.2-cvs: virtualdomains and sendmail virtusertable (cyrusv2as local mailer)

2002-12-16 Thread Christian Schulte
Jonathan Marsden schrieb:


There are almost certainly neater ways, but I just patched
sendmail.cf/m4/proto.m4 to do that.

--- proto.m4.20020613   Thu Jun 13 11:53:24 2002
+++ proto.m4Thu Dec 12 01:54:08 2002
@@ -1092,8 +1092,8 @@
dnl $H empty (but @$=w.)
R  $+ + $*  $+ $#_LOCAL_ $: $1 + $2plussed name?
R  $+  $+  $#_LOCAL_ $: @ $1   nope, local address',
-`R$=L  @ $=w .   $#_LOCAL_ $: @ $1   special local names
-R$+  @ $=w . $#_LOCAL_ $: $1 regular local name')
+`R$=L  @ $=w .   $#_LOCAL_ $: @ $1`@'$2  special local names
+R$+  @ $=w . $#_LOCAL_ $: $1`@'$2regular local name')

ifdef(`_MAILER_TABLE_', `dnl
# not local -- try mailer table lookup

Jonathan



Thanks for your answer! If I see it right, the only things which are 
changed in proto.m4 are the two lines

`R$=L  @ $=w .   $#_LOCAL_ $: @ $1`@'$2  special local names
R$+  @ $=w . $#_LOCAL_ $: $1`@'$2regular local name')

replacing the existing two ones, right ?

If I do these two changes, I get the following error when delivering to a local domain:




553 5.1.3 [EMAIL PROTECTED]... Invalid route addressU:error5.1.3553 Invalid route address@E:
500 5.0.0 Command line usage error

and at the bottom of the error-message there is:



Final-Recipient: RFC822; [EMAIL PROTECTED]@mail.schulte.it

So what sendmail now does is, it rewrites the address nearly correctly but adds the localhostname at the end of the address!
Any idea what I can do to prevent sendmail from ever apending the locahostname on an address ?

--Christian--








Re: cyrus-2.2-cvs: virtualdomains and sendmail virtusertable (cyrusv2as local mailer)

2002-12-16 Thread Christian Schulte
Jonathan Marsden schrieb:


There are almost certainly neater ways, but I just patched
sendmail.cf/m4/proto.m4 to do that.

--- proto.m4.20020613   Thu Jun 13 11:53:24 2002
+++ proto.m4Thu Dec 12 01:54:08 2002
@@ -1092,8 +1092,8 @@
dnl $H empty (but @$=w.)
R  $+ + $*  $+ $#_LOCAL_ $: $1 + $2plussed name?
R  $+  $+  $#_LOCAL_ $: @ $1   nope, local address',
-`R$=L  @ $=w .   $#_LOCAL_ $: @ $1   special local names
-R$+  @ $=w . $#_LOCAL_ $: $1 regular local name')
+`R$=L  @ $=w .   $#_LOCAL_ $: @ $1`@'$2  special local names
+R$+  @ $=w . $#_LOCAL_ $: $1`@'$2regular local name')




By the way:

+`R$=L  @ $=w .   $#_LOCAL_ $: @ $1`@'$2  special local names

What defines class L ? It seems like I do not have a so called class L!
And what does the first @ character in  $#_LOCAL_ $: @ $1`@'$2 stand for ?
^



--Christian--








Re: cyrus-2.2-cvs: virtualdomains and sendmail virtusertable (cyrusv2as local mailer)

2002-12-16 Thread Christian Schulte
Christian Schulte schrieb:


Jonathan Marsden schrieb:


There are almost certainly neater ways, but I just patched
sendmail.cf/m4/proto.m4 to do that.

--- proto.m4.20020613   Thu Jun 13 11:53:24 2002
+++ proto.m4Thu Dec 12 01:54:08 2002
@@ -1092,8 +1092,8 @@
dnl $H empty (but @$=w.)
R  $+ + $*  $+ $#_LOCAL_ $: $1 + $2plussed name?
R  $+  $+  $#_LOCAL_ $: @ $1   nope, 
local address',
-`R$=L  @ $=w .   $#_LOCAL_ $: @ $1   
special local names
-R$+  @ $=w . $#_LOCAL_ $: $1 
regular local name')
+`R$=L  @ $=w .   $#_LOCAL_ $: @ $1`@'$2  
special local names
+R$+  @ $=w . $#_LOCAL_ $: 
$1`@'$2regular local name')

I think the two lines you added should look like

`R$=L  @ $=w .$#_LOCAL_ $: @ $1  @ $2   special local names
R$+  @ $=w .  $#_LOCAL_ $: $1  @ $2 regular local name')

don't they ? For me thinks work after chaning them this way !





ctl_cyrusdb gives DBERROR when executed by master

2002-12-16 Thread Piet Ruyssinck


When I execute
$ /usr/cyrus/bin/ctl_cyrusdb -c
from the command line, as the user cyrus, everything works as expected :

Dec 16 14:49:55 vorota ctl_cyrusdb[25014]: [ID 702911 local6.notice] checkpointing 
cyrus databases
Dec 16 14:49:55 vorota ctl_cyrusdb[25014]: [ID 578205 local6.debug] archiving database 
file: /var/imap/mailboxes.db
Dec 16 14:49:55 vorota ctl_cyrusdb[25014]: [ID 448116 local6.debug] archiving log 
file: /var/imap/db/log.01
Dec 16 14:49:56 vorota last message repeated 1 time
Dec 16 14:49:56 vorota ctl_cyrusdb[25014]: [ID 127214 local6.notice] done 
checkpointing cyrus databases


whereas, when the same command is being executed from master, I get this :

Dec 16 14:43:34 vorota ctl_cyrusdb[24994]: [ID 702911 local6.notice] checkpointing 
cyrus databases
Dec 16 14:43:35 vorota ctl_cyrusdb[24994]: [ID 854764 local6.error] DBERROR: error 
listing log files: No such file or directory
Dec 16 14:43:35 vorota ctl_cyrusdb[24994]: [ID 686478 local6.error] DBERROR: archive 
/var/imap/db: cyrusdb error
Dec 16 14:43:35 vorota ctl_cyrusdb[24994]: [ID 854764 local6.error] DBERROR: error 
listing log files: No such file or directory
Dec 16 14:43:35 vorota ctl_cyrusdb[24994]: [ID 686478 local6.error] DBERROR: archive 
/var/imap/db: cyrusdb error
Dec 16 14:43:35 vorota ctl_cyrusdb[24994]: [ID 127214 local6.notice] done 
checkpointing cyrus databases


The relevant lines of /etc/cyrus.conf look like this :

EVENTS {
  checkpointcmd=ctl_cyrusdb -c period=30
  delprune  cmd=ctl_deliver -E 3 at=0400
  tlsprune  cmd=tls_prune at=0400
}


Any ideas ?

___
Piet RUYSSINCK e-mail: [EMAIL PROTECTED]
Unix Systeem Administratie  tel: +32 9 264 4733 
Directie Informatie- en Communicatietechnologie (ICT)   fax: +32 9 264 4994
Universiteit Gent (RUG)   Krijgslaan 281, gebouw S9 - 9000 Gent, Belgie




Re: Cyrus Startup-Check

2002-12-16 Thread Patrick Boutilier
A sleep command in your script will probably do the job in the meantime.

sleep 60

before you start fetchmail will wait 60 seconds for cyrus to be up and 
running for example.



Christian Bomhardt wrote:
Hallo,

I run cyrus with fetchmail. Every night, a cron script stopps cyrus and
fetchmail, tars the mail folders and restarts cyrus and fetchmail. My
problem is, that fetchmail is too fast and tries to deliver mail via lmtp,
before cyrus is ready - so the mail is moved to the local root mail account
and not into the cyrus mail spool.

Has anybody any Idea how to check if cyrus is ready to receive mail before
restarting fetchmail from within a cron script?

Second: the syslog is flooded with imapd[xx]: startttls: ... login: ...
-messages. How can this be stopped?

Thanks,
Christian Bomhardt






Re: [CVS] pidfile support

2002-12-16 Thread Rob Siemborski
On Sun, 15 Dec 2002, Henrique de Moraes Holschuh wrote:

 1. There is no support for updating the pidfile. Thus, the lock is acquired
 only after forking, which means we lost the controlling terminal by the time
 we can complain about not being able to acquire a lock, and that we have
 already tried to go daemon and thus whatever is trying to start master is
 NOT told that we failed.

I don't think you can fix this in a perfect way, giving unix locking
semantics (well, atleast fcntl).

This is using the code from the original patch:

http://bugzilla.andrew.cmu.edu/attachment.cgi?id=93action=view

[A] lock and write pidfile
[A] fork and create [B] (which doesn't hold a lock on the file)
[B] attempt to reacquire lock on pidfile, FAIL since A doesn't have it
[A] exit(success)
[B] exit(failure)

The parent to A thinks we successfully finished, when in reality we've
stepped on our own feet.

I've experementally verified that this is actually a problem in theory
(if not in practice).

I don't think the BSD flock() semantics even help us here (hold lock
across fork() but any close() will get rid of the lock), since then we
have:

[A] lock and write the pidfile
[A] fork and create [B] (which shares the lock with [A])
[A] exit(success), which closes the file descriptor and releases the lock
[C] start a master process, lock and write the pidfile
[B] attempt to reacquire lock, and fail because [C] has the lock

(I'll note that I haven't experementally verified this sequence)

Now we've exited in failure, and not reported so to our parent.

But, I think this might be less of an issue than the first, since master
still starts successfully in the end (though, perhaps with a different
config file?)

I'm willing to listen to suggestions.

 2. Close on exec is not being set on the pidfile.  Right now, this is not
 a bug.  However, should we forget a close(pidfile) anywhere, it could
 somehow be the part of a bigger security hole...

This is doable I suppose.

-Rob

-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-
Rob Siemborski * Andrew Systems Group * Cyert Hall 207 * 412-268-7456
Research Systems Programmer * /usr/contributed Gatekeeper




sendmail+procmail+cyrus, return-path, sieve

2002-12-16 Thread Will Partain
This scenario, and ones like it, has been discussed here
before.  I've got something working, so am posting details
{in case it's useful, so you can tell me I'm an idiot:-)}.

The 'vacation' bit of sieve wasn't working, because it kept
seeing a useless 'deliver'-created Return-Path: header.

I was starting procmail from sendmail, with a procmail
recipe something like this:

   # *OLD*
   CYUSER=$1

   # Run spamassassin:
   :0fw
   | /our/bin/spamassassin -x -p /etc/mail/spamassassin.config

   # All the mail that falls through to this point
   # will be delivered into the user's INBOX 
   :0w:$CYUSER.lock
   | $DELIVER -a $CYUSER $CYUSER

   # If that fails, report back whatever $DELIVER said:
   EXITCODE=$?
   :0
   /dev/null
   # end *OLD*

This worked fine, except for sieve vacation.  Why?
'deliver' would run and insist on tossing in a Return-Path:
[EMAIL PROTECTED], even though there was a perfectly
good Return-Path: already in the message.  (Result: two
Return-Path:s) Of course, then sieve would send all vacation
messages to '[EMAIL PROTECTED]', who didn't appreciate
them.

I couldn't see a way 'round it except to fish out the
pre-existing Return-Path: and force 'deliver's hand (with
-r).  So I now have:

   # *NEW*
   CYUSER=$1

   # snag the existing Return-Path:
   RPTMP=`/usr/bin/formail -xReturn-Path: | /bin/sed -e 's/^ *//' -e 's/$//'`
   RETPATH=${RPTMP:-badbadbad}

   # Run spamassassin:
   :0fw
   | /our/bin/spamassassin -P -x -F 0 -p /etc/mail/spamassassin.config

   # All the mail that falls through to this point
   # will be delivered into the user's INBOX 
   :0w:$CYUSER.lock
   * ! RETPATH ?? badbadbad
   | $DELIVER -a $CYUSER -r $RETPATH $CYUSER

   # if we get here, something bad happened re the Return-Path:
   :0w:$CYUSER.lock
   | $DELIVER -a $CYUSER $CYUSER

   # If that fails, report back whatever $DELIVER said:
   EXITCODE=$?
   :0
   /dev/null
   # end *NEW*

As best I can tell, this is vacation'ing happily.  I would
be grateful for any improvements that you may suggest.
Regards,

Will





Re: sendmail+procmail+cyrus, return-path, sieve

2002-12-16 Thread Oleg Derevenetz
Will Partain wrote:


This scenario, and ones like it, has been discussed here
before.  I've got something working, so am posting details
{in case it's useful, so you can tell me I'm an idiot:-)}.

The 'vacation' bit of sieve wasn't working, because it kept
seeing a useless 'deliver'-created Return-Path: header.


I wrote a small patch, and it works for me. Code is self-explanatory :-) 
Also I slightly modified deliver.c to realize some sort of DSN and to 
prevent losing of mail messages due to errors.
*** lmtpengine.c.orig   Sun Nov  3 17:20:10 2002
--- lmtpengine.cFri Dec  6 21:53:49 2002
***
*** 1059,1067 
m-id = NULL;   /* no message-id */
  }
  
! if (!m-return_path 
(body = msg_getheader(m, return-path))) {
/* let's grab return_path */
m-return_path = xstrdup(body[0]);
clean822space(m-return_path);
clean_retpath(m-return_path);
--- 1059,1070 
m-id = NULL;   /* no message-id */
  }
  
! if (!(func-addretpath) 
(body = msg_getheader(m, return-path))) {
/* let's grab return_path */
+   if (m-return_path) {
+   free(m-return_path);
+   }
m-return_path = xstrdup(body[0]);
clean822space(m-return_path);
clean_retpath(m-return_path);

*** deliver.c.orig  Fri Aug  2 20:54:48 2002
--- deliver.c   Thu Dec  5 15:05:45 2002
***
*** 58,63 
--- 58,64 
  #include syslog.h
  #include com_err.h
  #include errno.h
+ #include sysexits.h
  #include pwd.h
  #include sys/types.h
  
***
*** 101,109 
421-4.3.0 usage: deliver [-C alt_config ] [-m mailbox]
 [-a auth] [-r return_path] [-l] [-D]\r\n);
  fprintf(stderr, 421 4.3.0 %s\n, CYRUS_VERSION);
! exit(EC_USAGE);
  }
  
  void fatal(const char* s, int code)
  {
  prot_printf(deliver_out,421 4.3.0 deliver: %s\r\n, s);
--- 102,183 
421-4.3.0 usage: deliver [-C alt_config ] [-m mailbox]
 [-a auth] [-r return_path] [-l] [-D]\r\n);
  fprintf(stderr, 421 4.3.0 %s\n, CYRUS_VERSION);
! exit(EX_TEMPFAIL);
  }
  
+ char *convert_lmtp(int r)
+ {
+ switch (r) {
+ case 0:
+   return 250 2.1.5 Ok;
+   
+ case IMAP_IOERROR:
+   return 451 4.3.0 System I/O error;
+ 
+ case IMAP_SERVER_UNAVAILABLE:
+   return 451 4.4.0 Remote server unavailable;
+ 
+ case IMAP_NOSPACE:
+   return 451 4.3.1 cannot create file: out of space;
+ 
+ case IMAP_AGAIN:
+   return 451 4.3.0 transient system error;
+   
+ case IMAP_PERMISSION_DENIED:
+   return 550 5.7.1 Permission denied;
+ 
+ case IMAP_QUOTA_EXCEEDED:
+   return 552 5.2.2 Over quota;
+ 
+ case IMAP_MAILBOX_BADFORMAT:
+ case IMAP_MAILBOX_NOTSUPPORTED:
+   return 451 4.2.0 Mailbox has an invalid format;
+ 
+ case IMAP_MESSAGE_CONTAINSNULL:
+   return 554 5.6.0 Message contains NUL characters;
+   
+ case IMAP_MESSAGE_CONTAINSNL:
+   return 554 5.6.0 Message contains bare newlines;
+ 
+ case IMAP_MESSAGE_CONTAINS8BIT:
+   return 554 5.6.0 Message contains non-ASCII characters in headers;
+ 
+ case IMAP_MESSAGE_BADHEADER:
+   return 554 5.6.0 Message contains invalid header;
+ 
+ case IMAP_MESSAGE_NOBLANKLINE:
+   return 554 5.6.0 Message has no header/body separator;
+ 
+ case IMAP_MAILBOX_NONEXISTENT:
+   /* XXX Might have been moved to other server */
+   return 550 5.1.1 User unknown;
+ }
+ 
+ /* Some error we're not expecting. */
+ return 554 5.0.0 Unexpected internal error;
+ }
+ 
+ /* This will always return fatal error codes due to call in RCPT_PERMFAIL state */
+ static int convert_sysexit_fatal (int r)
+ {
+ switch (r) {
+   case IMAP_MESSAGE_CONTAINSNULL:
+   case IMAP_MESSAGE_CONTAINSNL:
+   case IMAP_MESSAGE_CONTAINS8BIT:
+   case IMAP_MESSAGE_BADHEADER:
+   case IMAP_MESSAGE_NOBLANKLINE:
+   return EX_DATAERR;
+   
+   case IMAP_QUOTA_EXCEEDED:
+   return EX_UNAVAILABLE;
+   
+   case IMAP_MAILBOX_NONEXISTENT:
+   return EX_NOUSER;
+ }
+ 
+ return EX_UNAVAILABLE;
+ }
+ 
  void fatal(const char* s, int code)
  {
  prot_printf(deliver_out,421 4.3.0 deliver: %s\r\n, s);
***
*** 120,126 
  
  len = read(in, buf, sizeof(buf)-1);
  if (len == -1) {
!   exit(EC_IOERR);
  }
  if (len == 0) {
exit(0);
--- 194,200 
  
  len = read(in, buf, sizeof(buf)-1);
  if (len == -1) {
!   exit(EX_TEMPFAIL);
  }
  if (len == 0) {
exit(0);
***
*** 130,136 
 xxx can cause deadlock??? */
  do {
cnt = write(out, buf+amnt,len-amnt);
!   if (cnt == -1) exit(EC_IOERR);
amnt += cnt;
  } while (amntlen);
  
--- 204,210 
 xxx can cause deadlock??? */
  do {
cnt = write(out, buf+amnt,len-amnt);
!   if 

Re: ctl_cyrusdb -r takes too long

2002-12-16 Thread John Havard

You wouldn't happen to have have /var/imap on a logging or journaling 
filesystem by any chance?  A while back I noticed this under Solaris.  The 
fix was to mount /var without UFS logging. IIRC, the db code does its own 
journaling/logging, so the only thing you'll be missing by turning it off 
in the FS is the long start times.

Regards,
John Havard
Systems Administrator
Internet Doorway, Inc.

Internet Doorway, Inc. (NETDOOR) - Mississippi's ISP
601.969.1434 | 800.952.1570 | http://www.netdoor.com/



--On Saturday, December 14, 2002 05:50:33 PM +0530 Jatin Nansi 
[EMAIL PROTECTED] wrote:

Hi,

This is for cyrus gurus and for record:

---
Dec 13 20:10:21 mail3 master[4574]: process started
Dec 13 20:10:21 mail3 master[4575]: about to exec
/usr/cyrus/bin/ctl_cyrusdb Dec 13 20:10:21 mail3 ctl_cyrusdb[4575]:
recovering cyrus databases Dec 14 06:15:11 mail3 ctl_cyrusdb[4575]: done
recovering cyrus databases Dec 14 06:15:11 mail3 master[4574]: ready for
work
Dec 14 06:15:11 mail3 master[4979]: about to exec
/usr/cyrus/bin/ctl_cyrusdb Dec 14 06:15:11 mail3 master[4982]: about to
exec /usr/cyrus/bin/imapd Dec 14 06:15:11 mail3 master[4983]: about to
exec /usr/cyrus/bin/imapd Dec 14 06:15:11 mail3 master[4984]: about to
exec /usr/cyrus/bin/lmtpd Dec 14 06:15:11 mail3 master[4985]: about to
exec /usr/cyrus/bin/lmtpd Dec 14 06:15:11 mail3 master[4981]: about to
exec /usr/cyrus/bin/tls_prune Dec 14 06:15:11 mail3 master[4980]: about
to exec /usr/cyrus/bin/ctl_deliver Dec 14 06:15:11 mail3
ctl_cyrusdb[4979]: checkpointing cyrus databases Dec 14 06:15:11 mail3
lmtpunix[4985]: executed
Dec 14 06:15:11 mail3 lmtp[4984]: executed
Dec 14 06:15:11 mail3 tls_prune[4981]: mydelete: starting txn 2147483653
---

Will ctl_cyrusdb -r take 10 hours ? I dread the day when the system will
need downtime again.

This is on a decent 2 x P3 1 GHz with 100 GB scsi raid and 1 GB RAM,
about 2000 users, 50 MB per user.

I really need reboot times to be between 5 to 10 minutes, as against 10
hours. I will set the checkpoint period to 5 minutes as per the FAQ, but
are there any other pointers ?

Jatin




Jatin Nansi wrote:


Hi,

I have a cyrus IMAP system here which is taking way too long to start
up, stopping just at ctl_cyrusdb -r. There does not seem to be any
activity going on, but ctl_cyrusdb just doesnot exit.

I am running cyrus-imapd-2.1.8 on a redhat 7.3 system. The backend
database is DB3.

I need some directions on what could be wrong and where ? Is it normal
for ctl_cyrusdb -r to take as much as 1 hr (and still running) to
finish ?

Jatin










Re: Slow LIST command

2002-12-16 Thread Richard Gilbert
On Wed, 11 Dec 2002, Rob Siemborski wrote:

  Having watched the activity, the thing which seems to consume most of the
  resources are the LIST  * and LIST  % commands.  These return with a
  response like OK Completed (1.480 secs 28 calls) but can take a very
  long real time.  Is there anything which can be done to speed up the
  performance of the LIST command?  My imapd.conf is appended.

 Are you using the skiplist backend for your mboxlist?

 If not, that should tremendously increase LIST performance.

Thank you very much for this priceless piece of information.  Before
switching to skiplists, our IMAP server was completely swamped at busy
times making the IMP Webmail service almost unusable.  It is now mostly
idling!

The LIST command mentioned above was obviously load dependent because the
same thing took 0.58 seconds when it was quiet just before I did the
upgrade.  However, after the upgrade it took just 0.05 seconds!

Thank you again.

Richard
--
Richard Gilbert
Corporate Information and Computing Services
University of Sheffield, Sheffield, S10 2TN, UK
Phone: +44 114 222 3028   Fax: +44 114 222 3040




Install

2002-12-16 Thread Nuno Miguel Pais Fernandes
Hello

I'm having problems installing Cyrus imap.
I have a Redhat 7.3 and i'm trying to install it from source.
Can anyone point me to some howto because the tldp's one is very old.
After installing i'm planning to use vpopmail's authentication.
Can anyone help me in one of these steps..

Thanks

Nuno Fernandes

-- 
Nuno Miguel Pais Fernandes [EMAIL PROTECTED]
Eurotux S.A.



signature.asc
Description: This is a digitally signed message part


Re: Slow LIST command

2002-12-16 Thread John Alton Tamplin


On Wed, 11 Dec 2002, Rob Siemborski wrote:


Having watched the activity, the thing which seems to consume most of the
resources are the LIST  * and LIST  % commands.  These return with a
response like OK Completed (1.480 secs 28 calls) but can take a very
long real time.  Is there anything which can be done to speed up the
performance of the LIST command?  My imapd.conf is appended.
 

Are you using the skiplist backend for your mboxlist?

If not, that should tremendously increase LIST performance.
   

Is the recommendation for skiplist compared just to flat or to db3 as 
well?  If the latter, how is reliability compared to db3, and does that 
extend to the other uses besides mboxlist?

--
John A. Tamplin   Unix System Administrator
Emory University, School of Public Health +1 404/727-9931





Re: Install (use RPMs on Red Hat 7.3 from http://home.teleport.ch/simix/ )

2002-12-16 Thread Jonathan Marsden
On 16 Dec 2002, Nuno Miguel Pais Fernandes writes:

 I'm having problems installing Cyrus imap.
 I have a Redhat 7.3 and i'm trying to install it from source.

You will save yourself a *lot* ot time and trouble by using Simon
Matter's RPMs (compile from his SRPMs if you do not trust his
binaries for some reason).

If you absolutely *must* install from the source manually, then read
the .spec file from his RPMs and use its approach as a basis for your
own.

  http://home.teleport.ch/simix/

Jonathan
--
Jonathan Marsden| Internet: [EMAIL PROTECTED] | Making electronic 
1252 Judson Street  | Phone: +1 (909) 795-3877  | communications work 
Redlands, CA 92374  | Fax:   +1 (909) 795-0327  | reliably for Christian 
USA | http://www.xc.org/jonathan| missions worldwide 




Re: Install

2002-12-16 Thread Yann Debonne
Nuno,

I don't know a thing about vpopmail, but I can tell you this.  I too 
have RH-v7.3 and  hands-down the best HOW-TO that I've seen for Cyrus 
install (w/postfix) is Luc de Louw's document 
(http://www.delouw.ch/linux/).  After fumbling unsuccessfully with 
Cyrus for two years (I'm a total newbie/hobbyist), I found his document 
and followed it line-by-line and was successful due to it's clarity and 
flow.

However, with this being said, his document does not cover Red Hat 
specifically, so you'll have to do quite a few mods and create some 
symbolic links here and there.  If you got this route, here are some 
tips.  By the way, my total install was:
(Apache 1.3.26 w/php support + MySQL-Max + SASL + Cyrus + Postfix + 
Squirrelmail + Cyrus-Web-cyradm)

* Do NOT use rpms.  Only install from binaries.
* Remove ALL relevant rpms FIRST, from your RH installation.
* DO NOT use Luc's instructions for MySQL.  Follow their install notes 
instead.
* Test it out on your own account alone for a couple solid weeks as all 
sorts of small nit-picky things pop up.

Yann

On Monday, December 16, 2002, at 09:37  AM, Nuno Miguel Pais Fernandes 
wrote:

Hello

I'm having problems installing Cyrus imap.
I have a Redhat 7.3 and i'm trying to install it from source.
Can anyone point me to some howto because the tldp's one is very old.
After installing i'm planning to use vpopmail's authentication.
Can anyone help me in one of these steps..

Thanks

Nuno Fernandes

--
Nuno Miguel Pais Fernandes [EMAIL PROTECTED]
Eurotux S.A.
signature.asc





Re: Install

2002-12-16 Thread Brian

Yann Debonne said:

 * Do NOT use rpms.  Only install from binaries.

RPMS are binaries ;-)

Seriously, Simon has done a great job with his RPMS.  Jonathan hit it on
the head.  Grab Simon's SRPMS (*source* RPMS for the uninitiated ... just
a tarball and a spec file, folks), install them, and the look at his spec
file to see what options he used to build it.  You'll be up and running in
no time *AND* see which options will get you going.

Don't reinvent the wheel,

-- 
Brian





deliver fails to deliver this message

2002-12-16 Thread pilsl
I've a very interesting email:

while the deliver-script and lmtp-deliver fails to deliver the email,
the cyrus-mailer coming with sendmail does not. Emails like this come
to our server one or two times a week.

I'd like to know whats actually wrong with the email (deliver
complains Message contains invalid header) and if there is a way to
run lmtp-deliver in a more tolerant way like the
sendmail-cyrus-mailer seems to do ...

thnx a lot,
peter

the mail (per-user information replaced with xxx without changing
length of text)

--
Return-Path: [EMAIL PROTECTED]
Received: from MAILWARDEN (mail.scfuk.org.uk [194.129.49.212])
by alpha.ihf-hr.org (8.12.1/8.12.1) with ESMTP id gBGFXOJK017043
for [EMAIL PROTECTED]; Mon, 16 Dec 2002 16:33:25 +0100
Received: by MAILWARDEN from localhost
(router,slmail V5.1); Mon, 16 Dec 2002 15:30:57 +
for [EMAIL PROTECTED]
Received: from uk_camb_ws01.scfuk.org.uk [10.1.3.29]
 by MAILWARDEN [192.168.200.20]  (MailWarden 5.1.0.4411) with SMTP
 id 9DF043192CC44900BB4B9200DE0C1E1C
 for [EMAIL PROTECTED]; Mon, 16 Dec 2002 15:30:56 
Received: FROM uk_camb_er01.SCFUK.ORG.UK BY uk_camb_ws01.scfuk.org.uk ; Mon Dec 16 
15:20:28 2002 
Received: by UK_CAMB_ER01 with Internet Mail Service (5.5.2653.19)
id YDN108NS; Mon, 16 Dec 2002 15:31:34 -
Message-ID: 79DEBC5639ECD211A4760090274068C7038281A9@UK_VAUX_E01
From: x  [EMAIL PROTECTED]
To: xx xx (IHF) [EMAIL PROTECTED]
Subject: Out of Office AutoReply: hi
Date: Mon, 16 Dec 2002 15:31:23 -
MIME-Version: 1.0
X-Mailer: Internet Mail Service (5.5.2653.19)
Content-Type: text/plain
X-SLUIDL: C2491A27-E96343C9-89786B43-52415DF7
 
I will be away from the office until  Wednesday 18 December.  Please contact
  (x) or xx xxx (x) in my absence. Many thanks,
 
- xx
---


-- 
mag. peter pilsl
IT-Consulting
tel: +43-699-1-3574035
fax: +43-699-4-3574035
[EMAIL PROTECTED]
http://www.goldfisch.at



Sieve Server-Wide

2002-12-16 Thread Lee
Hey All,
I've setup spamassassin / amavisd-new  to tag spam with an X-Spam 
header. I want to now tell cyrus to filter those emails into the users 
spam folder. I found a sieve script that does this, but I'm wondering 
if there is a way to apply the script to all users on the server. Is 
there some sort of shared or default sieve user/directory that 
affects all users or some way to have all users' sieve dir simply be a 
single directory?

Thanks,
Lee