Re: Auto-deletion of messages in Junk-folder after a certain time

2008-07-15 Thread Bron Gondwana
On Mon, Jul 14, 2008 at 01:54:01PM +0200, Marten Lehmann wrote:
 Hello,
 
 we have a virtual domain configuration and I want to remove all messages 
 within the folder
 
 user/any-userpart@any-domain/Junk/*

Being the filty perl programmer that I am, I would just make an admin
IMAP connection to the server, LIST all mailboxes, regex match the ones
I wanted, select them and process them.

 I don't want to mark old messages as deleted and expunge them, because 
 then maybe I'm expunging messages, that haven't been flagged as deleted 
 by me but the owner of the mailbox and aren't ment to be expunged at 
 this moment.

We do this by setting our own special flag (in addition to the regular
\Deleted flag) and then SEARCH for those messages only and UIDEXPUNGE
them.

But if you're deleting ALL messages, then it doesn't really matter does
it?  Unless you're doing some sort of age based thing, in which case
like I said - UIDEXPUNGE.  The flag just lets us persist the action
across dropped connections.

Bron.

Cyrus Home Page: http://cyrusimap.web.cmu.edu/
Cyrus Wiki/FAQ: http://cyrusimap.web.cmu.edu/twiki
List Archives/Info: http://asg.web.cmu.edu/cyrus/mailing-list.html


Re: Auto-deletion of messages in Junk-folder after a certain time

2008-07-15 Thread ram

On Tue, 2008-07-15 at 19:50 +1000, Bron Gondwana wrote:
 On Mon, Jul 14, 2008 at 01:54:01PM +0200, Marten Lehmann wrote:
  Hello,
  
  we have a virtual domain configuration and I want to remove all messages 
  within the folder
  
  user/any-userpart@any-domain/Junk/*
 
 Being the filty perl programmer that I am, I would just make an admin
 IMAP connection to the server, LIST all mailboxes, regex match the ones
 I wanted, select them and process them.

I used to do the same , But I found a client connection script too slow
 too heavy for my server with 40k mailboxes 


I use ipurge now , but ipurge seems to have some bug. If I dont use -f
the mailbox under sub domains using realm is not matched

(So just hacked into ipurge.c to do my job  ) 



Thanks
Ram









Cyrus Home Page: http://cyrusimap.web.cmu.edu/
Cyrus Wiki/FAQ: http://cyrusimap.web.cmu.edu/twiki
List Archives/Info: http://asg.web.cmu.edu/cyrus/mailing-list.html


Re: Auto-deletion of messages in Junk-folder after a certain time

2008-07-15 Thread Wesley Craig
On 15 Jul 2008, at 08:16, ram wrote:
 I use ipurge now , but ipurge seems to have some bug. If I dont use  
 -f
 the mailbox under sub domains using realm is not matched

ipurge just uses findall.  The -f flag allows ipurge to examine user  
mailboxes.  Bug fixes are (of course) welcome.

:wes

Cyrus Home Page: http://cyrusimap.web.cmu.edu/
Cyrus Wiki/FAQ: http://cyrusimap.web.cmu.edu/twiki
List Archives/Info: http://asg.web.cmu.edu/cyrus/mailing-list.html


Re: Auto-deletion of messages in Junk-folder after a certain time

2008-07-15 Thread Marten Lehmann
Hi,


 Being the filty perl programmer that I am, I would just make an admin
 IMAP connection to the server, LIST all mailboxes, regex match the ones
 I wanted, select them and process them.
 
 I used to do the same , But I found a client connection script too slow
  too heavy for my server with 40k mailboxes 

we have more than 40.000 mailboxes, too. But I'm not very enthusiastic
to use ipurge. I'm afraid ipurge does something wrong (due to bugs or
misconfiguration) and some unexpected messages are deleted. I wouldn't
have a good feeling to tell customers ipurge is always right without
having logs.

My preferred solution would be to log each mailbox I'm deleting messages
from and the From, Date and Subject-header of each, so in case of
accidents, the customers could restore the messages somehow.

I wouldn't mind a slow perl script that does its job one by one as long
as I get logs.

@Bron: I don't want to delete all messages, but all messages older than
60 days. Instead of flagging messages, I thing UIDEXPUNGE might be an
option.

Kind regards
Marten Lehmann


Cyrus Home Page: http://cyrusimap.web.cmu.edu/
Cyrus Wiki/FAQ: http://cyrusimap.web.cmu.edu/twiki
List Archives/Info: http://asg.web.cmu.edu/cyrus/mailing-list.html


standard murder configuration problem

2008-07-15 Thread Maurizio Lo Bosco
Hi All,
I'm going crazy configuring a standard murder architecture with 3 different 
servers
 1 frontend (mx1)
 1 mupdate master (mupdate)
 1 backend (ariel)
the OS is debian etch.
the imap/pop3 and lmtp connections are not working from the frontend to the 
backend


--- MX1 mail.log
Jul 15 15:23:27 mx1 cyrus/lmtpunix[8197]: couldn't authenticate to backend 
server: no mechanism available

Jul 15 15:26:05 mx1 cyrus/imap[8236]: couldn't authenticate to backend server: 
no mechanism available
---
I can connect directly to the backend with a client and I have succesfull 
result with imtest and lmtptest from the frontend to the backend.

[EMAIL PROTECTED]:/etc# imtest -a helpdesk -u helpdesk ariel
S: * OK ariel Cyrus IMAP4 v2.2.13-Debian-2.2.13-10 server ready
C: C01 CAPABILITY
S: * CAPABILITY IMAP4 IMAP4rev1 ACL QUOTA LITERAL+ MAILBOX-REFERRALS NAMESPACE 
UIDPLUS ID NO_ATOMIC_RENAME UNSELECT CHILDREN MULTIAPPEND BINARY SORT 
THREAD=ORDEREDSUBJECT THREAD=REFERENCES ANNOTATEMORE IDLE 
MUPDATE=mupdate://mupdate/
S: C01 OK Completed
Please enter your password:
C: L01 LOGIN helpdesk {8}
S: + go ahead
C: omitted
S: L01 OK User logged in
Authenticated.
Security strength factor: 0
C: Q01 LOGOUT
Connection closed.

[EMAIL PROTECTED]:/etc# lmtptest -a murder -u murder ariel
S: 220 ariel LMTP Cyrus v2.2.13-Debian-2.2.13-10 ready
C: LHLO example.com
S: 250-ariel
S: 250-8BITMIME
S: 250-ENHANCEDSTATUSCODES
S: 250-PIPELINING
S: 250-SIZE
S: 250-AUTH PLAIN
S: 250 IGNOREQUOTA
Please enter your password:
C: AUTH PLAIN bXVyZGVyAG11cmRlcgBzM3JnMTA=
S: 235 Authenticated!
Authenticated.
Security strength factor: 0
C: QUIT
Connection closed.

What's wrong with my config?

mx1 cyrus.conf
---
START {
recover cmd=/usr/sbin/ctl_cyrusdb -r

delprunecmd=/usr/sbin/cyr_expire -E 3
tlsprunecmd=/usr/sbin/tls_prune
}
SERVICES {
sieve   cmd=timsieved listen=localhost:sieve prefork=0 
maxchild=100
notify  cmd=notifyd listen=/var/run/cyrus/socket/notify 
proto=udp prefork=1
mupdate   cmd=mupdate listen=3905 prefork=1
imapcmd=proxyd listen=imap prefork=0 maxchild=100
pop3cmd=pop3proxyd listen=pop3 prefork=0 maxchild=50
lmtpunixcmd=lmtpproxyd 
listen=/var/run/cyrus/socket/lmtp prefork=1 maxchild=20
}
EVENTS {
checkpoint  cmd=/usr/sbin/ctl_cyrusdb -c period=30
delprunecmd=/usr/sbin/cyr_expire -E 3 at=0401
tlsprunecmd=/usr/sbin/tls_prune at=0401

}
-
mx1 imapd.conf
-
configdirectory: /var/lib/cyrus
defaultpartition: default
partition-default: /var/spool/cyrus/mail
altnamespace: no
unixhierarchysep: no
lmtp_downcase_rcpt: yes
admins: cyrus murder
lmtp_admins: murder
mupdate_server: mupdate
mupdate_port: 3905
mupdate_authname: murder
mupdate_username: murder
mupdate_password: 
mupdate_retry_delay: 10
proxy_authname: murder
ariel_password: 
allowanonymouslogin: no
popminpoll: 1
autocreatequota: 0
umask: 077
sieveusehomedir: false
sievedir: /var/spool/sieve
hashimapspool: true
allowplaintext: yes
sasl_pwcheck_method: saslauthd
sasl_mech_list: PLAIN
sasl_minimum_layer: 0
sasl_auto_transition: no
tls_ca_path: /etc/ssl/certs
tls_session_timeout: 1440
tls_cipher_list: TLSv1+HIGH:!aNULL:@STRENGTH
lmtpsocket: /var/run/cyrus/socket/lmtp
idlemethod: poll
idlesocket: /var/run/cyrus/socket/idle
notifysocket: /var/run/cyrus/socket/notify
syslog_prefix: cyrus
--
Hope you can point me in the right way.
Regards
  Maurizio

Cyrus Home Page: http://cyrusimap.web.cmu.edu/
Cyrus Wiki/FAQ: http://cyrusimap.web.cmu.edu/twiki
List Archives/Info: http://asg.web.cmu.edu/cyrus/mailing-list.html