Re: [Dovecot] Missing return-path on vacation messages
On Jul 30, 2009, at 1:59 AM, Stephen Vaughan wrote: Is this ever likely to be fixed in dovecot? .. @domain1.com Stephen On Sun, Dec 14, 2008 at 2:21 AM, Timo Sirainen t...@iki.fi wrote: Yeah, it was fixed a week after my mail: http://hg.dovecot.org/dovecot-sieve-1.1/rev/49537bad6797
Re: [Dovecot] STARTTLS problem
-BEGIN PGP SIGNED MESSAGE- Hash: SHA1 On Thu, 30 Jul 2009, Рачков Сергей wrote: A lot of thanks, Steffen! My problem was a Kaspersky Internet Security. It has a network traffic control function and option check SSL connection, if this option checked - everything work, if not checked - don't work. _Please_ file a bug report with Kaspersky Support. This annoying bug is eons old now. Regards, - -- Steffen Kaiser -BEGIN PGP SIGNATURE- Version: GnuPG v1.4.6 (GNU/Linux) iQEVAwUBSnFLB3WSIuGy1ktrAQLhcwf/UBsTQ4eadnNRohpkzdSQoqvDjYFa7Qpw emPywXgVmjVPq4FMRSdJG4rEoY652XWXBt+R3qz9rB7TQAY2sFZQlEd9G5Ic5E+3 aDocOoORieJpRKeJSBo4XgGq6gMlxrwU/8Rxd2jgRHDM7SNeHGft88xWl54Cs+5g Md3+cog+uC3XpkZDgPAi4sXIOlr5EPLacxHtHHot5KuL8ZXHJisBBQ/LS0gImODV WbRjc3Fl6I73YFUgIhLMONE9YfAcizJAk6DWaK+XAu20l6F3D6SjCWuKkiBOlAMC jn638UEeOIyXGVL6Pv/Pc22Vj4c7dbmIEFXYNP4zTgvSmIdIzTCMew== =FDt4 -END PGP SIGNATURE-
Re: [Dovecot] Some people asked me lately about how professional Dovecot is.
-BEGIN PGP SIGNED MESSAGE- Hash: SHA1 On Wed, 29 Jul 2009, Stewart Dean wrote: Dovecot Works. That's all anyone needs to know. Plus it has a towering wizard of a developer and an avid, engaged and endlessly helpful community. Well, we don't need to argue about that. Bye, - -- Steffen Kaiser -BEGIN PGP SIGNATURE- Version: GnuPG v1.4.6 (GNU/Linux) iQEVAwUBSnFQKHWSIuGy1ktrAQI+XAf/exhCP9eo0pa7glRodo59otRHnOSlnF6e 847nOswzY4ieAEV+a6XkN+ko/meAvrJiIeP9OlPitpAXlfOw+HgtZS/kmBI0ahkm vLx1o353J/xZnfZekhhunjhICvcaadql9WXWFPgzf4rriHssE87E2l1uL1rYngCr SihyMif3TmrcxKVRGmXAvG4vTsFElHIQp+qImmIfWA0oFeyVkA72DZ56uWiPITOt obCFgb9Yi+lZiEoDcUTtVe/cya0XLkNfvs3kV71Y5bpIai3aa+F16KmV0PK7Pur7 1Bz23eT1TdfnFywX8H/HhpWlcKT2I2dXxraFLPmJ2Jft2ptwpnae0A== =g1vl -END PGP SIGNATURE-
Re: [Dovecot] Some people asked me lately about how professional Dovecot is.
* Steffen Kaiser skdove...@smail.inf.fh-brs.de: -BEGIN PGP SIGNED MESSAGE- Hash: SHA1 On Wed, 29 Jul 2009, Stewart Dean wrote: Dovecot Works. That's all anyone needs to know. Plus it has a towering wizard of a developer and an avid, engaged and endlessly helpful community. Well, we don't need to argue about that. Which criteria do you evaluate when you decide on professional or not? p...@rick -- state of mind Digitale Kommunikation http://www.state-of-mind.de Franziskanerstraße 15 Telefon +49 89 3090 4664 81669 München Telefax +49 89 3090 4666 Amtsgericht MünchenPartnerschaftsregister PR 563
Re: [Dovecot] sieve rules processing
Nikita Koshikov schreef: This is my current rule list: require [fileinto,envelope,copy]; # rule:[redirect] if anyof (true) { redirect :copy al...@domain.com; } # rule:[Cron] elsif anyof (header :contains Subject Cron) { fileinto INBOX/Cron; } You are using a if/elseif/else statement. When the if clause (which is always true) is matched, the stuff in the elsif/else clauses is discarded. You'll need to use 2 separate if statements to make this work. -- Regards, Tom signature.asc Description: OpenPGP digital signature
Re: [Dovecot] sieve rules processing
Nikita Koshikov schreef: On Thu, 30 Jul 2009 01:29:26 +0200 Stephan Bosch step...@rename-it.nl wrote: I am not exactly sure what you mean. Why are you providing an explicit keep command when you want to sort the message further? Without keep action - mail just redirected to specified mailbox, but it doesn't stores into my inbox. [..] This is my current rule list: require [fileinto,envelope,copy]; # rule:[redirect] if anyof (true) { redirect :copy al...@domain.com; } # rule:[Cron] elsif anyof (header :contains Subject Cron) { fileinto INBOX/Cron; } [..] But this mail save into INBOX, for user koshiko...@domain.com, (the second rule is not working), in logs I have: Jul 30 10:29:04 deliver(koshiko...@domain.com): Info: sieve: msgid=4a714b09.9030...@domain.com: forwarded to al...@domain.com Jul 30 10:29:04 deliver(koshiko...@domain.com): Info: sieve: msgid=4a714b09.9030...@domain.com: stored mail into mailbox 'INBOX' Jul 30 10:29:04 deliver(al...@domain.com): Info: sieve: msgid=4a714b09.9030...@domain.com: stored mail into mailbox 'INBOX' So :copy acting for me like keep. Do you have any ideas, why this might happen ? Yes, your second rule is an elsif, meaning that it is only executed when the first if-condition is not 'true'. Since that first rule has a forced 'true' result, the second rule is absolutely never executed. You script should be: require [fileinto,copy]; # rule:[redirect] if true { redirect :copy al...@domain.com; } # rule:[Cron] if header :contains Subject Cron { fileinto INBOX/Cron; } Note that the anyof() commands are only necessary when you have multiple tests per if command. Also, I removed the envelope require, since it is not used. Regards, -- Stephan Bosch step...@rename-it.nl
Re: [Dovecot] sieve redirect action
Nikita Koshikov schreef: Hello Stephan, First of all, thank you for dovecot-sieve implementation. I see that you are adding X-Sieve header to all outgoing e-mail in cmd-redirect.c /* Prepend sieve version header (should not affect signatures) */ rfc2822_header_field_write(f, X-Sieve, SIEVE_IMPLEMENTATION); How do you look at adding one more header, for example X-Sieve-Forward-From: Now, when redirect action is in use - mail forwards using sendmail command line interface. The problem that there is no suitable way to know which user's script has generate redirect. Received: header may contain envelope receiver but this is valid if only 1 rcpt to: command was specified on SMTP session. This invokes problem when forwarding mail to non-local domains, breaking such things like SPF. I'd like to setup SRS for fixing this, but I don't know sender(sieve local user) mail. Adding one header with valid local user e-mail address will fix this. Google add 2 headers for this - X-Forwarded-To: and X-Forwarded-For: . What do you think about this ? I have no objection, but then again my experience on this subject is pretty bleak. Does anyone else have comments? Regards, -- Stephan Bosch step...@rename-it.nl
[Dovecot] Filtering with Public Namespaces and Sieve Plugin
Hi, after upgrading to Dovecot 1.2x including the rewritten Sieve plugin replacing 'cmusieve', messages which have formerly been filed to a Public/Mailing-List maildir are no longer filtered correctly. The sieve script itself is included in the user's personal-script. The messages are dropped to the INBOX rather than the Public Namespace Maildir. Log's don't give a hint (at least to me). The documentation says the personal script should automatically fetch the include, and compile it in the users home... Debug log excerpt: - 2009-07-30 10:44:09 deliver(): Info: Namespace: type=public, prefix=Public/, sep=/, inbox=no, hidden=no, list=yes, subscriptions=no 2009-07-30 10:44:09 deliver(): Info: maildir: data=/var/vmail/public:CONTROL=~/maildir/public:INDEX=~/maildir/public 2009-07-30 10:44:09 deliver(): Info: maildir++: root=/var/vmail/public, index=/var/vmail/leuxner.net/tlx/maildir/public, control=/var/vmail/leuxner.net/tlx/maildir/public, inbox= 2009-07-30 10:44:09 deliver(): Info: sieve: using sieve path for user's script: /var/vmail/leuxner.net/tlx/.dovecot.sieve 2009-07-30 10:44:09 deliver(): Info: sieve: opening script /var/vmail/leuxner.net/tlx/.dovecot.sieve 2009-07-30 10:44:09 deliver(): Info: sieve: executing compiled script /var/vmail/leuxner.net/tlx/.dovecot.sieve 2009-07-30 10:44:09 deliver(): Info: Namespace : Using permissions from /var/vmail/leuxner.net/tlx/maildir: mode=0750 gid=-1 2009-07-30 10:44:09 deliver(): Info: sieve: msgid=20090730084326.gp1...@jeeves.jpl.local: stored mail into mailbox 'INBOX' Personal .dovecot.sieve script: -- require [include,copy,fileinto,vacation]; include :global global.sieve; -- snip --- Global script global.sieve excerpt: require [copy,fileinto]; #Newsletters / Mailinglists if allof (address :is [To,CC] dovecot@dovecot.org, header :contains List-Id dovecot.dovecot.org) { fileinto Public/Mailing-Lists.Dovecot; } elsif allof (address :is To dovecot-n...@dovecot.org, header :contains List-Id dovecot-news.dovecot.org) { fileinto :copy Public/Newsletters.Dovecot; } Thanks Thomas $ dovecot -n # 1.2.1: /etc/dovecot/dovecot.conf # OS: Linux 2.6.26-2-amd64 x86_64 Debian 5.0.2 log_path: /var/log/dovecot.log info_log_path: /var/log/dovecot-info.log log_timestamp: %Y-%m-%d %H:%M:%S protocols: imap listen: 188.138.0.199:143 ssl_cert_file: /etc/ssl/certs/spectre_leuxner_net_2009.crt ssl_key_file: /etc/ssl/private/spectre_leuxner_net_2009.key login_dir: /var/run/dovecot/login login_executable: /usr/lib/dovecot/imap-login mail_privileged_group: mail mail_location: maildir:~/maildir mail_debug: yes maildir_copy_preserve_filename: yes mail_plugins: acl quota imap_quota fts fts_squat namespace: type: private separator: / inbox: yes list: yes subscriptions: yes namespace: type: public separator: / prefix: Public/ location: maildir:/var/vmail/public:CONTROL=~/maildir/public:INDEX=~/maildir/public list: yes auth default: passdb: driver: passwd-file args: username_format=%u /var/vmail/%d/etc/passwd userdb: driver: passwd-file args: username_format=%u /var/vmail/%d/etc/passwd socket: type: listen client: path: /var/spool/postfix/private/auth mode: 432 user: postfix group: postfix master: path: /var/run/dovecot/auth-master mode: 384 user: vmail group: vmail plugin: acl: vfile:/var/vmail/%d/etc/acls:cache_secs=300 quota: maildir:User quota quota_rule: *:storage=1GB quota_rule2: Trash:storage=10%% fts: squat fts_squat: partial=4 full=10 sieve_global_dir: /var/vmail/%d/etc/sieve-scripts
Re: [Dovecot] sieve rules processing
On Thu, 30 Jul 2009 10:32:20 +0200 Tom Hendrikx t...@whyscream.net wrote: You are using a if/elseif/else statement. When the if clause (which is always true) is matched, the stuff in the elsif/else clauses is discarded. You'll need to use 2 separate if statements to make this work. Thank you for explanation, Tom. Dividing rule list to two separate statements helped. -- Regards, Tom
Re: [Dovecot] Missing return-path on vacation messages
On 7/30/2009, Stephen Vaughan (stephenvaug...@gmail.com) wrote: Does the fix apply to dovecot 1.1 only? We are running 1.0, should we be upgrading to 1.2? 1.0 is old... so yes, you should upgrade... lots more reasons than this one bugfix, for sure... But... I'm confused about the bug... The mail clients displayed 'From' address was the problem, right? Thats what was fixed... the 'return-path', which is what you were originally complaining about, is still , as it should be for vacation messages. -- Best regards, Charles
Re: [Dovecot] Filtering with Public Namespaces and Sieve Plugin
Thomas Leuxner wrote: Hi, after upgrading to Dovecot 1.2x including the rewritten Sieve plugin replacing 'cmusieve', messages which have formerly been filed to a Public/Mailing-List maildir are no longer filtered correctly. The sieve script itself is included in the user's personal-script. The messages are dropped to the INBOX rather than the Public Namespace Maildir. Log's don't give a hint (at least to me). The documentation says the personal script should automatically fetch the include, and compile it in the users home... I am pretty confident that this is caused by the include bug we found a few days back: http://www.dovecot.org/list/dovecot/2009-July/041608.html That is fixed: http://hg.rename-it.nl/dovecot-1.2-sieve/rev/d989537882d0 To confirm, you could first try to incorporate the mailing-list rules from the global script into the user's personal script to check whether filing into the public namespace works without the include. Then, you could apply the above patch to check whether it solves your problem. I've tested your setup with the latest Mercurial version and I could not find any problems. Regards, Stephan
Re: [Dovecot] Missing return-path on vacation messages
On 7/30/2009, Stephen Vaughan (stephenvaug...@gmail.com) wrote: Jul 30 01:00:48 asura qmail-scanner-queue.pl: qmail-scanner[32365]: Policy:Bad_MIME:RC: If you read the thread where this was declared fixed, it specifically said something about the MIME body being broken... Easiest way to tell if this fixes it is... upgrade... ;) -- Best regards, Charles
Re: [Dovecot] parameter mail_location and variables
thanks... i try to apply them, so i define the following settings: dovecot.conf: mail_location: /export/home/vmail/maximatt.org/ and these configuration on dovecot-ldap.conf where i try to override mail_location setting: user_attrs= mailbox=mailbox, quotaDovecot=quota, mailbox=mail=maildir:/export/home/vmail/%$ but these... not work and i cant understand why (yet)... these are log report: dovecot: Jul 30 09:18:09 Info: IMAP(toto1): maildir: data=/export/home/vmail/dgr.gub.uy/ dovecot: Jul 30 09:18:09 Info: IMAP(toto1): maildir: root=/export/home/vmail/dgr.gub.uy, index=/export/home/vmail/dgr.gub.uy, control=, inbox= can anybody helpme to resolve and undestand them? thanks! 2009/7/29 maximatt aza...@gmail.com hi i have virtual users stored in ldap server and i must to do some modifications that requiere to chage mail_location value... the solution comes to use the uid value stored in ldap server for users on mail_location parameter... i can see in http://wiki.dovecot.org/Variables that i can't do them (i uses sasl authentication) so.. ¿exist any way to get a value from ldap server and use them in mail_location parameter? thanks in advance!!! -- Salu2 ;) -- Salu2 ;)
Re: [Dovecot] expire plugin no delete 1.2.1 / 1.2.2
Robert Schetterer schrieb: Timo Sirainen schrieb: On Thu, 2009-07-23 at 23:42 +0200, Robert Schetterer wrote: Hi Timo, all of my tests fail with expire plugin, mail simply not get deleted i cant find any stuff in the logs why it does not or should not work. Try with 1.2.2 and check the mails' save dates now that you have the FETCH X-SAVEDATE command available. Hi Timo, upgraded last night and tested X-SAVEDATE is now available, before it was not so lets wait and see, if it now works, i will report Hi Timo, still mails get not deleted i just did a new test mysql select mailbox, from_unixtime(expire_stamp), username from expireplugin; +-+-+---+ | mailbox | from_unixtime(expire_stamp) | username | +-+-+---+ | Trash | 2009-07-31 14:18:47 | rob...@schetterer.com | +-+-+---+ 1 row in set (0.00 sec) 2 select Trash * FLAGS (\Answered \Flagged \Deleted \Seen \Draft nonjunk Junk) * OK [PERMANENTFLAGS (\Answered \Flagged \Deleted \Seen \Draft nonjunk Junk \*)] Flags permitted. * 1 EXISTS * 0 RECENT * OK [UIDVALIDITY 1240758078] UIDs valid * OK [UIDNEXT 85] Predicted next UID * OK [HIGHESTMODSEQ 109] 2 OK [READ-WRITE] Select completed. 3 fetch 1:* (internaldate x-savedate) * 1 FETCH (INTERNALDATE 30-Jul-2009 14:18:26 +0200 X-SAVEDATE 30-Jul-2009 14:18:47 +0200) 3 OK Fetch completed. /usr/sbin/dovecot -c /etc/dovecot/dovecot.conf --exec-mail ext /usr/lib/dovecot/expire-tool.sh --test Info: Loading modules from directory: /usr/lib/dovecot/modules/imap Info: Module loaded: /usr/lib/dovecot/modules/imap/lib01_acl_plugin.so Info: Module loaded: /usr/lib/dovecot/modules/imap/lib10_quota_plugin.so Info: Module loaded: /usr/lib/dovecot/modules/imap/lib20_autocreate_plugin.so Info: Module loaded: /usr/lib/dovecot/modules/imap/lib20_expire_plugin.so Info: Module loaded: /usr/lib/dovecot/modules/imap/lib20_fts_plugin.so Info: Module loaded: /usr/lib/dovecot/modules/imap/lib20_virtual_plugin.so Info: Module loaded: /usr/lib/dovecot/modules/imap/lib21_fts_squat_plugin.so Info: Quota root: name= backend=dict args=:proxy::quotadict Info: Quota warning: bytes=0 (95%) messages=0 command=/usr/local/bin/quota-warning.sh 95 Info: Quota warning: bytes=0 (80%) messages=0 command=/usr/local/bin/quota-warning.sh 80 Info: expire: pattern=Trash type=expunge secs=86400 Info: rob...@schetterer.com/Trash: stop, expire time in future: Fri Jul 31 14:18:47 2009 /usr/lib/dovecot/expire-tool.sh #!/bin/bash MAIL_PLUGINS=${MAIL_PLUGINS//imap_quota/} MAIL_PLUGINS=${MAIL_PLUGINS//mail_log/} MAIL_PLUGINS=${MAIL_PLUGINS//imap_acl/} #MAIL_PLUGINS=${MAIL_PLUGINS//virtual/} exec ${0%.sh} $@ i still speculate the problem might be in the virtual plugin but anyway if its load or not by the script mails dont get deleted additional i integrated userdb_home userdb_mail in password_query but this also did not helped ( so perhaps some config stuff helps for debug ) password_query = SELECT username as user, password, \ 1001 as userdb_uid, \ 1001 as userdb_gid, \ /usr/local/virtual/%u/ AS userdb_home, \ maildir:/usr/local/virtual/%u/ AS userdb_mail \ FROM mailbox WHERE username = '%u' AND active = '1' AND (imap_allowed = '1' or '%Ls' = 'pop3') user_query = SELECT concat('/usr/local/virtual/', maildir) AS home, \ concat('*:bytes=', mailbox.quota) AS quota_rule, \ #when saving to Trash mailbox the user gets additional 50MB Trash:storage=50240 AS quota_rule2, \ #when saving to Sent mailbox the user gets additional 50MB Sent:storage=50240 AS quota_rule3, \ #when saving to Drafts mailbox the user gets additional 50MB Drafts:storage=50240 AS quota_rule4, \ #when saving to Templates mailbox the user gets additional 50MB Templates:storage=50240 AS quota_rule5, \ #when saving to Junk mailbox the user gets additional 50MB Junk:storage=50240 AS quota_rule6, \ #ignore quota on shared #shared:ignore AS quota_rule7, \ concat('maildir:/usr/local/virtual/', maildir) AS mail, \ CASE '%s' WHEN 'pop3' THEN NULL ELSE 'yes' END AS namespace_1_inbox, \ CASE '%s' WHEN 'pop3' THEN 'yes' ELSE NULL END AS namespace_2_inbox, \ 1001 AS uid, 1001 AS gid FROM mailbox WHERE username = '%u' AND active = '1' namespace private { separator = / prefix = location = maildir:/usr/local/virtual/%d/%u/:CONTROL=/usr/local/virtual/%d/%u/:INDEX=/usr/local/virtual/%d/%u/:INBOX=/usr/local/virtual/%d/%u/ list = yes hidden = no subscriptions = yes } namespace private { prefix = virtual/ separator = / location = virtual:/etc/dovecot/virtual:LAYOUT=maildir++ hidden = yes list = no subscriptions= no } namespace private { prefix = RealMails/ separator = / list = no hidden = yes location = maildir:/usr/local/virtual/%d/%u/:CONTROL=/usr/local/virtual/%d/%u/:INDEX=/usr/local/virtual/%d/%u/:INBOX=/usr/local/virtual/%d/%u/ } mail_location =
Re: [Dovecot] sieve redirect action
-BEGIN PGP SIGNED MESSAGE- Hash: SHA1 On Thu, 30 Jul 2009, Stephan Bosch wrote: How do you look at adding one more header, for example X-Sieve-Forward-From: Now, when redirect action is in use - mail forwards using sendmail command line interface. The problem that there is no suitable way to know which user's script has generate redirect. Received: header may contain envelope receiver but this is valid if only 1 rcpt to: command was specified on SMTP session. This invokes problem when forwarding mail to non-local domains, breaking such things like SPF. I'd like to setup SRS for fixing this, but I don't know sender(sieve local user) mail. Adding one header with valid local user e-mail address will fix this. Google add 2 headers for this - X-Forwarded-To: and X-Forwarded-For: . What do you think about this ? I have no objection, but then again my experience on this subject is pretty bleak. Does anyone else have comments? Basically I like the idea. I've seen X-Resent-By: Forwarder em...@hoster.example.com X-Resent-For: stef...@example.com X-Resent-To: kai...@example.net inserted by one of my hosters. Pine adds RFC 2822 sec 3.6.6 style headers (RFC 4021 sec 2.1.14 ff.) ReSent-Date: Thu, 30 Jul 2009 14:36:18 +0200 (CEST) ReSent-From: re-sender ReSent-To: new recipients ReSent-Subject: new Subject ReSent-Message-ID: New msgid ReSent-User-Agent: New MUA id string However, the section starts with: Resent fields SHOULD be added to any message that is reintroduced by a user into the transport system. Dunno, if by a user applies to Sieve, too. IMHO, it should be customizable. Bye, - -- Steffen Kaiser -BEGIN PGP SIGNATURE- Version: GnuPG v1.4.6 (GNU/Linux) iQEVAwUBSnGWi3WSIuGy1ktrAQLUYggAw/BXIWXFEPw4pKpKpTbvufnsXLpP4Qew GGo/9URurlk1TXPHywvLpgvRIQsfpe8elfqWmpiwMi56uIdXcDTY0rQ1TQ5HvlP2 3hqTGmKPF9y33HikCTTR9ZxVf9aebHDAkLKWeFyKNR6it4KCc1L9y2b2ebxhmrWj u8vSX2tzeghr5XMHoowz8JMo3VdGnti6SBjeIOVHFeyVZSuNlXitZwLdPmTG7WEz sqkqEvPJv3tXppDOahyayTu4SG9PkfKIv/Oe0Rsl7eQg3Lg5UK+uRmiJlA1KZnt1 SqGoTnqnDs4vBS8x6w70YxL+7rHwtMW9rZv9RBVt8pC8Lr6RkRanEw== =AN8H -END PGP SIGNATURE-
[Dovecot] Managesieve configuration problem
Hello! I'm trying for a lot of time to make managesieve working with dovecot 1.1.17 and virtual users on openSuSE 11.1. I think I'm doing some misconfiguration, but I can't figure it out. Perhaps it's something with the paths to the sieve scripts? In dovecot.conf I find in the comments: ~~ protocol managesieve { #(...) # Specifies the location of the symlink pointing to the active script in # the sieve storage directory. This must match the SIEVE setting used by # deliver (refer to http://wiki.dovecot.org/LDA/Sieve#location for more # info). Variable substitution with % is recognized. # Take care: if a file in a maildir: begins with a '.', it is recognized # as a folder; so, avoid this. #sieve=~/.dovecot.sieve sieve = /drbd/mail/vmail/%d/%n/dovecot.sieve } ~~ This must match the SIEVE setting used by deliver, so I have to take a look to LDA section, no? But there I don't find any hint for sieve settings: ~~ protocol lda { # Address to use when sending rejection mails. postmaster_address = postmas...@mydomain.tld # Hostname to use in various parts of sent mails, eg. in Message-Id. # Default is the system's real hostname. #hostname = # Support for dynamically loadable plugins. mail_plugins is a space separated # list of plugins to load. mail_plugins = cmusieve quota mail_plugin_dir = /usr/lib64/dovecot/modules/lda # If user is over quota, return with temporary failure instead of # bouncing the mail. #quota_full_tempfail = no # Format to use for logging mail deliveries. You can use variables: # %$ - Delivery status message (e.g. saved to INBOX) # %m - Message-ID # %s - Subject # %f - From address #deliver_log_format = msgid=%m: %$ # Binary to use for sending mails. sendmail_path = /usr/lib/sendmail # Human readable error message for rejection mails. Use can use variables: # %n = CRLF, %r = reason, %s = subject, %t = recipient rejection_reason = Your message to %t was automatically rejected:%n%r # UNIX socket path to master authentication server to find users. # auth_socket_path = /drbd/mail/var/run/dovecot/auth-master auth_socket_path = /var/run/dovecot/auth-master } ~~ I tried to log in to managesieve manually with gnutls-cli, and that was successfull. I was able to authenticate. But when I try to put the example script from dovecot wiki (http://wiki.dovecot.org/ManageSieve/Troubleshooting) ~~~ PUTSCRIPT hutsefluts {6+} keep; ~~~ I get no ~ OK Putscript completed. ~ there happens nothing, managesieve seems to wait for something else. When I look now into the directory where the script should be stored (the folder has been created automatically) I don't find any script file but a folder tmp that contains a plaintext file with the script commands inside, eg. ~~~ hutsefluts-12345678.M033562P2271.imap.sieve ~~~ After disconnecting, this file disappears. In the dovecot.info log it looks like this: ~~ dovecot: Jul 30 14:51:56 Info: auth(default): master out: USER 16 t...@mydomain.tld home=/drbd/mail/vmail/mydomain.tld/test mail=maildir:/drbd/mail/vmail/mydomain.tld/test uid=5001gid=5001 quota_rule=*:storage=51200B dovecot: Jul 30 14:51:56 Info: managesieve-login: Login: user=t...@mydomain.tld, method=PLAIN, rip=192.168.200.39, lip=192.168.200.40, TLS dovecot: Jul 30 14:51:56 Info: MANAGESIEVE(t...@mydomain.tld): Effective uid=5001, gid=5001, home=/drbd/mail/vmail/mydomain.tld/test dovecot: Jul 30 14:51:56 Info: MANAGESIEVE(t...@mydomain.tld): sieve-storage: using active sieve script path: /drbd/mail/vmail/mydomain.tld/test/dovecot.sieve dovecot: Jul 30 14:51:56 Info: MANAGESIEVE(t...@mydomain.tld): sieve-storage: using active sieve script path: /drbd/mail/vmail/mydomain.tld/test/dovecot.sieve dovecot: Jul 30 14:51:56 Info: MANAGESIEVE(t...@mydomain.tld): sieve-storage: using sieve script storage directory: /drbd/mail/vmail/mydomain.tld/test/sieve dovecot: Jul 30 14:51:56 Info: MANAGESIEVE(t...@mydomain.tld): sieve-storage: relative path to sieve storage in active link: sieve/ ~~ ../vmail/mydomain.tld/test/dovecot.sieve is missing completely. Perhaps you can give me a small hint? And here is my dovecot -n: ~~ # 1.1.7: /etc/dovecot/dovecot.conf Warning: fd limit 1024 is lower than what Dovecot can
[Dovecot] sieve filtering setup
I'm looking at implementing sieve in my environment. Software is: dovecot-1.2-sieve revision 1022:3c9a22c28156 dovecot-1.2 revision 9269:a303bb82c1c9 AIX 5.3 with sendmail mta using prescribed deliver lda. I have a few questions. I'll have 110k sieve files(1 for each user). Does sieve read the file each time a new message is accepted by sendmail? Are there any measurements on cpu load for sieve filters? Thanks, Jonathan smime.p7s Description: S/MIME cryptographic signature
Re: [Dovecot] parameter mail_location and variables
hi... i can resolve them... but in another way: dovecot.conf: mail_location = maildir:/export/home/vmail/%h dovecot-ldap.conf: quotaDovecot=quota,mailbox=home but.. i still interestig to make work these with mail extra opction.. the last configure that i test i give the followin error: dovecot: Jul 30 09:36:49 Error: IMAP(toto1): mkdir(/HOME_DIRECTORY_USED_BUT_NOT_GIVEN_BY_USERDB/cur) failed: Permission denied thanks for all! 2009/7/30 maximatt aza...@gmail.com thanks... i try to apply them, so i define the following settings: dovecot.conf: mail_location: /export/home/vmail/maximatt.org/ and these configuration on dovecot-ldap.conf where i try to override mail_location setting: user_attrs= mailbox=mailbox, quotaDovecot=quota, mailbox=mail=maildir:/export/home/vmail/%$ but these... not work and i cant understand why (yet)... these are log report: dovecot: Jul 30 09:18:09 Info: IMAP(toto1): maildir: data=/export/home/vmail/dgr.gub.uy/ dovecot: Jul 30 09:18:09 Info: IMAP(toto1): maildir: root=/export/home/vmail/dgr.gub.uy, index=/export/home/vmail/dgr.gub.uy, control=, inbox= can anybody helpme to resolve and undestand them? thanks! 2009/7/29 maximatt aza...@gmail.com hi i have virtual users stored in ldap server and i must to do some modifications that requiere to chage mail_location value... the solution comes to use the uid value stored in ldap server for users on mail_location parameter... i can see in http://wiki.dovecot.org/Variables that i can't do them (i uses sasl authentication) so.. ¿exist any way to get a value from ldap server and use them in mail_location parameter? thanks in advance!!! -- Salu2 ;) -- Salu2 ;) -- Salu2 ;)
Re: [Dovecot] AutoCreate per Domain
Darvin Denmian schrieb: Any idea? On Thu, Jul 30, 2009 at 2:30 AM, Darvin Denmiandarvin.denm...@gmail.com wrote: Hello, is there a way to configure plugin autocreate per domain? Like: For domain xwz.com i want to autocreate folders: Models and Clients For domain yxw.com i want to autocreate folders: Adm and Tech Thanks. i dont think this would be a good idea, cause there are so much layouts and setups thinkable so in fact it might be difficult to implement this for all thinkable cases in the plugin, in my maildrop setup i do some testing about folders exist, and if not create it, but deliver does not exec scripts right now i think but perhaps you can exec test folder scripts at login stage http://wiki.dovecot.org/PostLoginScripting that should do the job -- Best Regards MfG Robert Schetterer Germany/Munich/Bavaria
[Dovecot] sieve delivery to utf folders
Hello list, Today, my users have noticed, that delivery to folders with non-english names is broken. For example, if I create russian directory, it correct encoded and display into mail-client program and my webmail: Encoded:Normal view .INBOX.BEIENQRBBEI-русс This is part of sieve script, which routing delivery to russian folder. elsif allof (header :contains Subject qwe) { fileinto INBOX/BEIENQRBBEI-; } But, when actualy delivery take place, in logs I have Jul 30 17:13:49 deliver(koshiko...@domain.com): Info: sieve: msgid=4a71a9e6.5040...@domain.com: stored mail into mailbox 'INBOX/-BEIENQRBBEI- And folder .INBOX.-BEIENQRBBEI- appears in users maildir. This folder can't be unencoded by mail-client program and user see exactly -BEIENQRBBEI- under INBOX directory(also normaly encoded directory BEIENQRBBEI- -- русс displays correct). Something breaks encoding and adds sing - to all words in utf encoded directory names. I can't tell exactly when this problem appear, but I remember that I have tested delivery to russian directories by sieve scripts and all worked fine. My current dovecot installation is 1.2.2, dovecot-sieve-0.1.9 and managesieve-0.11.7
Re: [Dovecot] AutoCreate per Domain
Darvin Denmian schrieb: Thanks Robert, i will try this solution !!! maybe i can be done via a global sieve rule too ask the sieve gurus if that might work On Thu, Jul 30, 2009 at 11:44 AM, Robert Schettererrob...@schetterer.org wrote: Darvin Denmian schrieb: Any idea? On Thu, Jul 30, 2009 at 2:30 AM, Darvin Denmiandarvin.denm...@gmail.com wrote: Hello, is there a way to configure plugin autocreate per domain? Like: For domain xwz.com i want to autocreate folders: Models and Clients For domain yxw.com i want to autocreate folders: Adm and Tech Thanks. i dont think this would be a good idea, cause there are so much layouts and setups thinkable so in fact it might be difficult to implement this for all thinkable cases in the plugin, in my maildrop setup i do some testing about folders exist, and if not create it, but deliver does not exec scripts right now i think but perhaps you can exec test folder scripts at login stage http://wiki.dovecot.org/PostLoginScripting that should do the job -- Best Regards MfG Robert Schetterer Germany/Munich/Bavaria -- Best Regards MfG Robert Schetterer Germany/Munich/Bavaria
Re: [Dovecot] sieve delivery to utf folders
Nikita Koshikov schreef: Hello list, Today, my users have noticed, that delivery to folders with non-english names is broken. For example, if I create russian directory, it correct encoded and display into mail-client program and my webmail: Encoded:Normal view .INBOX.BEIENQRBBEI-русс This is part of sieve script, which routing delivery to russian folder. elsif allof (header :contains Subject qwe) { fileinto INBOX/BEIENQRBBEI-; } But, when actualy delivery take place, in logs I have Jul 30 17:13:49 deliver(koshiko...@domain.com): Info: sieve: msgid=4a71a9e6.5040...@domain.com: stored mail into mailbox 'INBOX/-BEIENQRBBEI- And folder .INBOX.-BEIENQRBBEI- appears in users maildir. This folder can't be unencoded by mail-client program and user see exactly -BEIENQRBBEI- under INBOX directory(also normaly encoded directory BEIENQRBBEI- -- русс displays correct). Something breaks encoding and adds sing - to all words in utf encoded directory names. I can't tell exactly when this problem appear, but I remember that I have tested delivery to russian directories by sieve scripts and all worked fine. My current dovecot installation is 1.2.2, dovecot-sieve-0.1.9 and managesieve-0.11.7 You are using mUTF-7 in folder names. According to the Sieve specification, you must use the UTF-8 version. The fileinto command internally translates this to the mUTF-7 equivalent, so that the IMAP server sees it as expected. This is a change of about half a year ago: http://hg.rename-it.nl/dovecot-1.2-sieve/rev/fc0395d50d04 Regards, -- Stephan Bosch step...@rename-it.nl
Re: [Dovecot] Filtering with Public Namespaces and Sieve Plugin
On Thu, Jul 30, 2009 at 11:54:25AM +0200, Stephan Bosch wrote: I am pretty confident that this is caused by the include bug we found a few days back: http://www.dovecot.org/list/dovecot/2009-July/041608.html That is fixed: http://hg.rename-it.nl/dovecot-1.2-sieve/rev/d989537882d0 To confirm, you could first try to incorporate the mailing-list rules from the global script into the user's personal script to check whether filing into the public namespace works without the include. Hi Stephan, after including the rules in the personal script, they work with the public namespace. I haven't tried with the patch yet. Thanks Thomas
Re: [Dovecot] sieve filtering setup
On Jul 30, 2009, at 11:12 AM, Stephan Bosch wrote: Jonathan Siegle schreef: I'm looking at implementing sieve in my environment. Software is: dovecot-1.2-sieve revision 1022:3c9a22c28156 dovecot-1.2 revision 9269:a303bb82c1c9 AIX 5.3 with sendmail mta using prescribed deliver lda. I have a few questions. I'll have 110k sieve files(1 for each user). Does sieve read the file each time a new message is accepted by sendmail? Are there any measurements on cpu load for sieve filters? If all is configured correctly, the Sieve scripts are compiled once each time they are changed or created. After that, the deliver LDA only reads the compiled binary from disk for each message. I recently found out about something called memcached. The goal of memcached(server)[1] and libmemcached(client library)[2] is to store maps in memory of tokens. So my key would be jsiegle_sieve and my data would be my sieve file. So instead of the 10-20 million reads to disk, we would just pull from memory. The logic looks like this: On update of sieve file, Do validation of file. Do compilation of file. Delete key if it exists and add new. On new mail, sieve plugin would call memcached_get() and get the token. I could be very wrong, but I think this is a big win. memcached is designed for small files(1MB). So if each of my users has a 2KB file, that would only be 20MB of memory for usage. [1] http://www.danga.com/memcached/ [2] http://tangent.org/552/libmemcached.html -Jonathan smime.p7s Description: S/MIME cryptographic signature
[Dovecot] imap, locks, and dovecot
Let's say I have two computers -- a desktop and a laptop -- setup to check email on my postfix/dovecot/mailscanner box by using imap. Now, both machines use thunderbird and have a filter in that mail client to move emails that have a certain to: address (an alias, like supp...@domain.com) to a mail directory. The desktop is setup to check for mail every minute while the laptop initially is told to do the same. So, I send an email to the said address. dovecot (1.1.7) puts it in the inbox. thunderbird in one of those machines sees it and moves it to the, say, support folder. Then, another copy of the same mail is created and placed in the same folder. I then begin increasing the time the laptop waits before checking mails. Up to 5 minutes I am still having the double email issue, but if I the laptop to wait 10 minutes I only have one copy of the said email. That makes me think both clients are seeing the same email and moving it at the same time. I do not know the imap commands being used but it sure seems that there is not some kind of locking system for the mail files (I use maildir) to make sure only one program is accessing the said email. Am I correct? Is there a way around that?
Re: [Dovecot] Berlin talk - video or audio available?
James Brown schrieb: Thanks Timo for putting up the .pdf and .ppt files for your talk at www.dovecot.org/talks. Is there a video or audio file of it? Thanks, James. Most talks where recorded and according to heinlein support will be put online when they are done editing. http://www.heinlein-support.de/web/akademie/mailserver-konferenz-2009/mk09-downloads/ is probably the URL to monitor.
[Dovecot] virtual plugin - segfault body search
Hello list, During full text search in a virtal folder ( virtual plugin ) the imap crashes with segfault Version:1.2.2 OS: Ubuntu 8.04.3 LTS x86_64 Coredump: GNU gdb 6.8-debian Copyright (C) 2008 Free Software Foundation, Inc. License GPLv3+: GNU GPL version 3 or later http://gnu.org/licenses/gpl.html This is free software: you are free to change and redistribute it. There is NO WARRANTY, to the extent permitted by law. Type show copying and show warranty for details. This GDB was configured as x86_64-linux-gnu... warning: Can't read pathname for load map: Input/output error. Reading symbols from /lib/libdl.so.2...done. Loaded symbols for /lib/libdl.so.2 Reading symbols from /lib/librt.so.1...done. Loaded symbols for /lib/librt.so.1 Reading symbols from /lib/libc.so.6...done. Loaded symbols for /lib/libc.so.6 Reading symbols from /lib/ld-linux-x86-64.so.2...done. Loaded symbols for /lib64/ld-linux-x86-64.so.2 Reading symbols from /lib/libpthread.so.0...done. Loaded symbols for /lib/libpthread.so.0 Reading symbols from /usr/pack/dovecot-1.2.2-mo/amd64-linux-ubuntu8.04/lib/dovecot/imap/lib20_autocreate_plugin.so...done. Loaded symbols for /usr/pack/dovecot-1.2.2-mo/amd64-linux-ubuntu8.04/lib/dovecot/imap/lib20_autocreate_plugin.so Reading symbols from /usr/pack/dovecot-1.2.2-mo/amd64-linux-ubuntu8.04/lib/dovecot/imap/lib20_fts_plugin.so...done. Loaded symbols for /usr/pack/dovecot-1.2.2-mo/amd64-linux-ubuntu8.04/lib/dovecot/imap/lib20_fts_plugin.so Reading symbols from /usr/pack/dovecot-1.2.2-mo/amd64-linux-ubuntu8.04/lib/dovecot/imap/lib20_virtual_plugin.so...done. Loaded symbols for /usr/pack/dovecot-1.2.2-mo/amd64-linux-ubuntu8.04/lib/dovecot/imap/lib20_virtual_plugin.so Reading symbols from /usr/pack/dovecot-1.2.2-mo/amd64-linux-ubuntu8.04/lib/dovecot/imap/lib21_fts_squat_plugin.so...done. Loaded symbols for /usr/pack/dovecot-1.2.2-mo/amd64-linux-ubuntu8.04/lib/dovecot/imap/lib21_fts_squat_plugin.so Reading symbols from /lib/libnss_files.so.2...done. Loaded symbols for /lib/libnss_files.so.2 Core was generated by `imap'. Program terminated with signal 11, Segmentation fault. [New process 10317] #0 0x in ?? () No symbol table info available. #1 0x7faa60c55bc8 in fts_backend_get_all_last_uids (backend=0x12a0be0, pool=0x1925800, last_uids=0x18c5628) at fts-api.c:86 No locals. #2 0x7faa60c57b73 in fts_build_init_virtual (fctx=0x18c5580) at fts-storage.c:416 vctx = (struct fts_search_virtual_context *) 0x18c5608 last_uids = (struct fts_backend_uid_map *) 0x7fff69c06db0 mailboxes = {arr = {buffer = 0x74e350, element_size = 8}, v = 0x74e350, v_modifiable = 0x74e350} boxes = (struct mailbox * const *) 0x74e388 orig_boxes = (struct fts_orig_mailboxes *) 0x1925860 orig_box = {name = 0x13d0678 INBOX, ns = 0x75b320, box = 0x13d0388} i = 7 box_count = 7 last_uid_count = 5 ret = 8 #3 0x7faa60c57d76 in fts_build_init (fctx=0x18c5580) at fts-storage.c:445 status = {messages = 182, recent = 0, unseen = 106, uidvalidity = 1248796777, uidnext = 190, first_unseen_seq = 0, highest_modseq = 0, keywords = 0x0, sync_delayed_expunges = 0, nonpermanent_modseqs = 0} ret = 0 #4 0x7faa60c584fa in fts_try_build_init (ctx=0x1a5bad0, fctx=0x18c5580) at fts-storage.c:580 No locals. #5 0x7faa60c58683 in fts_mailbox_search_init (t=0xea2830, args=0x1dbc518, sort_program=0x0) at fts-storage.c:620 ft = (struct fts_transaction_context *) 0x1d96ef0 fbox = (struct fts_mailbox *) 0x13e38b0 ctx = (struct mail_search_context *) 0x1a5bad0 fctx = (struct fts_search_context *) 0x18c5580 #6 0x004892ff in mailbox_search_init (t=0xea2830, args=0x1dbc518, sort_program=0x0) at mail-storage.c:735 No locals. #7 0x0042e8f5 in imap_search_start (ctx=0x75c7e0, sargs=0x1dbc518, sort_program=0x0) at imap-search.c:546 cmd = (struct client_command_context *) 0x75c6d8 wanted_fields = 0 wanted_headers = (struct mailbox_header_lookup_ctx *) 0x0 #8 0x0042207f in cmd_search (cmd=0x75c6d8) at cmd-search.c:50 ctx = (struct imap_search_context *) 0x75c7e0 sargs = (struct mail_search_args *) 0x1dbc518 args = (const struct imap_arg *) 0x7617d0 charset = 0x4f7bbc UTF-8 ret = 1 #9 0x00426519 in client_command_input (cmd=0x75c6d8) at client.c:611 client = (struct client *) 0x75c280 command = (struct command *) 0x75c6d8 __PRETTY_FUNCTION__ = client_command_input #10 0x00426756 in client_command_input (cmd=0x75c6d8) at client.c:660 client = (struct client *) 0x75c280 command = (struct command *) 0x75aa20 __PRETTY_FUNCTION__ = client_command_input #11 0x00426889 in client_handle_next_command (client=0x75c280, remove_io_r=0x7fff69c0702e) at client.c:701 size = 29 #12 0x0042690c in
Re: [Dovecot] Clients and dovecot-uidlist
On Tue, Jul 28, 2009 at 07:30:27PM +0200, Thomas Hummel wrote: I took for granted that it was that the client would download all messages again since it might be confused by some UID changes. Is it correct ? Timo ? But I don't really see why (on the IMAP protocol level) and I don't know how to reproduce it. -- Thomas Hummel | Institut Pasteur hum...@pasteur.fr | Pôle informatique - systèmes et réseau
Re: [Dovecot] lock files causing time outs with Thunderbird
On Thu, 2009-07-30 at 10:07 -0600, CJ Keist wrote: Okay, I think I got a test that can recreate the .lock file staying around so long. I have trash folder with about 3500 messages in it. I went in and deleted two messages from the Trash folder. How close to the end of the mailbox did you delete the messages from? I then clicked back to my inbox. There was a long pause where Thunderbird was saying Closing folder Then another long pause as it said Opening folder. After about two minutes thunderbird looks to have stopped processing and displayed my inbox. But the Trash.lock file stuck around for about another 5 minutes. Ran ptruss on the pid that still had the Trash folder open. There was no pid for the Trash.lock file during this time. What do you mean by this? Trash.lock didn't have a PID in it, but you found the PID anyway somehow? It looks to be doing seeks, stats, reads and writes over and over again. Attached is a partial listing of the ptruss command till the lock file went away. It looks like you deleted some messages over 4 MB from the end of file, and Dovecot just moves 4 MB data over the deleted one. It looks like it's being done in pretty inefficient way though.. I guess I should some day improve it, but that's probably going to be annoyingly difficult. Anyway, if you look at where most of the time is spent, it's in the pwrite64() calls. Many of them can take almost 0.1 seconds. Have you enabled synchronous writes or something? signature.asc Description: This is a digitally signed message part
Re: [Dovecot] Clients and dovecot-uidlist
On Tue, 2009-07-28 at 19:30 +0200, Thomas Hummel wrote: Hello, I'm trying to figure out what exactly (and why) are the consequences of a lost or removal of the dovecot-uidlist file on an IMAP client (Thunderbird for instance). Just dovecot-uidlist, or also dovecot.index*? If you delete both, UIDVALIDITY is changed. If you delete only dovecot-uidlist, it'll probably preserve UIDVALIDITY and just give new UIDs to messages (because next_uid is also stored in index file). I took for granted that it was that the client would download all messages again since it might be confused by some UID changes. But I don't really see why (on the IMAP protocol level) and I don't know how to reproduce it. My understanding is that . dovecot-uidlist is not recreated until some client selects the mailbox . the client does something like : x UID fetch 1:* (FLAGS) to begin with anyway. So I guess the problem does not occur when no new messages arrive on the mailbox since the same UIDs would be assigned to the same messages ? Well, Dovecot reads the uidlist file lazily. If the index files still exist and you don't try to open any mail or there are no new mails, then uidlist's existence isn't checked and UIDs won't change. But can you show me some IMAP protocol command exchange that would illustrate . when such a problem can occur . how the client would detect that there has been some UID corruption . how it would fix it Either the client notices that UIDVALIDITY changes on SELECT: * OK [UIDVALIDITY 1248669921] UIDs valid Or the UIDs change. signature.asc Description: This is a digitally signed message part
Re: [Dovecot] AutoCreate per Domain
On Thu, 2009-07-30 at 02:30 -0300, Darvin Denmian wrote: Hello, is there a way to configure plugin autocreate per domain? Like: For domain xwz.com i want to autocreate folders: Models and Clients For domain yxw.com i want to autocreate folders: Adm and Tech You can return the autocreate-related settings from your userdb. Userdb extra fields can override any settings. http://wiki.dovecot.org/UserDatabase/ExtraFields signature.asc Description: This is a digitally signed message part
Re: [Dovecot] sieve filtering setup
On Thu, 2009-07-30 at 11:30 -0400, Jonathan Siegle wrote: I recently found out about something called memcached. The goal of memcached(server)[1] and libmemcached(client library)[2] is to store maps in memory of tokens. So my key would be jsiegle_sieve and my data would be my sieve file. So instead of the 10-20 million reads to disk, we would just pull from memory. Then again, if you have enough memory your OS could be doing that automatically already. Or maybe if the Sieve plugin supports giving a separate path to downloaded scripts, the destination could be in a ramdisk or if you're using Linux: http://memcachefs.sourceforge.net/ Also I'm hopefully going to abstracting out filesystem accessing code in Dovecot's index files and dbox code. Sieve could use this same FS API, and you could implement whatever backend to actually perform the FS access, like memcached.. signature.asc Description: This is a digitally signed message part
Re: [Dovecot] Clients and dovecot-uidlist
On Thu, 2009-07-30 at 19:24 +0200, Thomas Hummel wrote: I'm asking this because I'm investigating if CONTROL may be on a local filesystem (for performance reason) instead of an NFS filesystem : I think it's a bad idea. Besides the UID problems causing all kinds of trouble with clients (some clients ignore UIDVALIDITY completely (Apple Mail, at least used to) and the result is that opening a message from list opens a completely different mail) control files also contain dovecot-keywords which provides the maildir filename letter - keyword mapping. signature.asc Description: This is a digitally signed message part
Re: [Dovecot] AIX and posix_fallocate
I bumped into this a while back, and having IBM support for both AIX and the C for AIX V9 compiler, went to the mat on it. What a pointless waste of time; the new IBM increasingly doesn't care about making things right. While IBM has been proclaiming its POSIX compliance, it turned out that AIX and the compiler development have been tasked with its implementation, such as it maybe, only on the JFS2 filesystem. Now they haven't discontinued JFS FS support, but it's a disinterested, neglectful support. Now in the old IBM, everything, but everything, would be tested in n! ways, and everything would work. In the posix_fallocate development, for both AIX and the IBM compiler, apparently nobody did nuffin' with it for the old JFS FS...so until I raised Hell, the call returned a random value error code. Which means that the design team didn't consider JFS at all; not even to the point of documenting non-suppport in JFS. Their charge was JFS2. So they figured out a fix: a patch to return a generic something-wrong errcode. I screamed some more. Their final fix was to return a function not supported errcode. There. Done. It only took 3-4 months. FWIW, the patch will be in the mainline Technical level as follows: This APAR will be available 53V (AIX 53 TL11 ) and 61H (AIX 61 TL4 ). Their POSIX compliance position: we would like to clarify you on below points on posix compliant details in AIX. Your comment: Obviously, if you don't support both of AIX's file systems, you are not totally compliant. Response: Unix standards for posix_fallocate( ) function does not state what all filesystems the implementation need to support. Having said that AIX implementation of posix_fallocate() only supports JFS2. Hence not supporting JFS does not mean that AIX implementation of posix_fallocate() is not posix compliant. However as stated earlier you can open a Design change request for AIX to implement the support of JFS. Regarding the list of non-posix compliant APIs we do not maintain any separate list nor we have any known issues. Developers can get information about APIs from IBM documentation http://publib.boulder.ibm.com/infocenter/pseries/v5r3/index.jsp and also looking through Open Group standards specification http://www.opengroup.org/onlinepubs/009695399/toc.htm Working with the Indian IBM support was intriguing: they were always courteous, but they were only interested in fulfilling checklists, not in making the product right or necessarily making it work. They didn't, as I have seen elsewhere, declare victory by closing out the trouble ticket (PMR in IBMese) without informing you or getting your consentbut they would continue talking and doing not much of anything until you gave up. What I now do is to: 1) run configure 2) edit config.h and put // in front of the HAVE_POSIX_FALLOCATE define, like this: //#define HAVE_POSIX_FALLOCATE 3) then run make as usual I'm sorry; I should have posted this before, but the whole thing left such a bad taste in my mouth all I wanted to do was move on. S. Ralf Becker wrote: Hi, AIX's implementation of posix_fallocate is a little bit, let me say, peculiar. Attached is a patch to fix (=work around) this. Without you'll see this in the logs: Jul 28 01:17:41 trevi mail:err|error dovecot: IMAP(beckerr): posix_fallocate() failed: File exists Jul 28 01:17:41 trevi mail:err|error dovecot: IMAP(beckerr): file_set_size() failed with mbox file /u/f0/rzuser/beckerr/Mail/Ham: File exists Funny, isn't it? This is what it should be: Jul 28 01:17:41 trevi mail:err|error dovecot: IMAP(beckerr): posix_fallocate() failed: Operation not supported on socket Jul 28 01:17:41 trevi mail:err|error dovecot: IMAP(beckerr): file_set_size() failed with mbox file /u/f0/rzuser/beckerr/Mail/Ham: Operation not supported on socket The problem is, that errno is not correcly set, when posix_fallocate returns EOPNOTSUPP (=Operation not supported on socket). In this case the return code has to be checked rather than errno. When patched dovecot handles err==EOPNOTSUPP the same way like errno==EINVAL on Solaris. A note for all AIX Admins: Without APAR IZ48778: POSIX_FALLOCATE() FAILS WITH ERROR-25(ENOTTY) resp. IZ46961: POSIX_FALLOCATE() FAILS WITH ERROR-25(ENOTTY) APPLIES TO AIX 5300-06 you don't even get EOPNOTSUPP: posix_fallocate fails with NOTTY. So you have to install one of this fixes to make the patch work. Ralf -- Once upon a time, the Internet was a friendly, neighbors-helping-neighbors small town, and no one locked their doors. Now it's like an apartment in Bed-Stuy: you need three heavy duty pick-proof locks, one of those braces that goes from the lock to the floor, and bars on the windows Stewart Dean, Unix System Admin, Bard College, New York 12504 sd...@bard.edu voice: 845-758-7475, fax: 845-758-7035
[Dovecot] Dovecot with SSL Client Certification
Hi, i am trying to setup dovecot over ssl in the last couple days unsuccessfully My notes are from here: http://wiki.dovecot.org/SSL My OpenSSL commands are: mkdir -pv /opt/certificates/dovecot/ cd !$ (just to prevent questions about Common Name) [e...@myhome:~]€ hostname myhome openssl req -new -x509 -nodes -out dovecot.crt -keyout dovecot.key -days 1825 # Country Name (2 letter code) [AU]:GR # State or Province Name (full name) [Some-State]:Athens # Locality Name (eg, city) []:Aigaleo # Organization Name (eg, company) [Internet Widgits Pty Ltd]:Ebalaskas.Gr # Organizational Unit Name (eg, section) []:Mail Apps # Common Name (eg, YOUR name) []:myhome # Email Address []:ebalas...@ebalaskas.gr openssl pkcs12 -export -in dovecot.crt -inkey dovecot.key \ -name dovecot Certificate Client -out dovecot.p12 openssl ca -gencrl -keyfile dovecot.key -cert dovecot.crt -out dovecot.crl -selfsign I've imported the dovecot.p12 to thunderbird certificates and dovecot.crt to thunderbird authorities (i've tried claws mail too - same errors) My dovecot.conf is this: [r...@myhome dovecot]# dovecot -n # 1.2.2: /usr/local/etc/dovecot.conf # OS: Linux 2.6.30-ARCH i686 ext4 info_log_path: /var/log/dovecot.log protocols: imaps ssl: required ssl_ca_file: /opt/certificates/dovecot/dovecot.crl ssl_cert_file: /opt/certificates/dovecot/dovecot.crt ssl_key_file: /opt/certificates/dovecot/dovecot.key ssl_cipher_list: ALL:!LOW:!SSLv2 ssl_verify_client_cert: yes verbose_ssl: yes login_dir: /usr/local/var/run/dovecot/login login_executable: /usr/local/libexec/dovecot/imap-login first_valid_uid: 300 mail_location: maildir:/var/spool/mail/%u:INBOX=/var/spool/mail/%u/.INBOX mail_debug: yes lda: postmaster_address: ebalas...@ebalaskas.gr auth default: verbose: yes debug: yes debug_passwords: yes ssl_require_client_cert: yes passdb: driver: pam userdb: driver: passwd My /var/log/dovecot.log: Jul 30 20:14:52 Info: Dovecot v1.2.2 starting up (core dumps disabled) Jul 30 20:14:52 Info: Generating Diffie-Hellman parameters for the first time. This may take a while.. Jul 30 20:14:53 auth(default): Info: new auth connection: pid=5872 Jul 30 20:14:53 auth(default): Info: new auth connection: pid=5873 Jul 30 20:14:53 auth(default): Info: new auth connection: pid=5874 Jul 30 20:15:16 ssl-build-param: Info: SSL parameters regeneration completed Jul 30 20:15:17 auth(default): Info: new auth connection: pid=5898 Jul 30 20:15:18 imap-login: Info: Disconnected (client didn't send a cert): rip=127.0.0.1, lip=127.0.0.1, TLS handshaking: SSL_accept() failed: error:14094419:SSL routines:SSL3_READ_BYTES:tlsv1 alert access denied Any ideas? Evaggelos Balaskas Unix System Engineer - http://ebalaskas.gr/wiki Informatics Engineer Technological Education signature.asc Description: OpenPGP digital signature
Re: [Dovecot] AIX and posix_fallocate
On Thu, 2009-07-30 at 11:24 +0200, Ralf Becker wrote: + if ((err = posix_fallocate(fd, st.st_size, size - st.st_size)) == 0) return 0; + if (err == EOPNOTSUPP /* AIX */ ) { + /* Ignore this error silently. +You have to test err, because errno is not +correcly set on some versions of AIX */ + } else First I thought: Why didn't IBM even fix this properly by setting errno? Then I read posix_fallocate man page: RETURN VALUE posix_fallocate() returns zero on success, or an error number on fail‐ ure. Note that errno is not set. What the hell were POSIX people thinking?? This is the first syscall I've seen that behaves like this, and apparently without any good reason! Wonder how many other new system calls there are like this, that I haven't noticed yet.. signature.asc Description: This is a digitally signed message part
Re: [Dovecot] lock files causing time outs with Thunderbird
The two message were at the end of the Trash folder. I used fuser to find the pids on the Trash and Trash.lock files. fuser reported no pid for the Trash.lock file. The the ptruss was run on the pid on the Trash file. By synchronous writes I'm assuming on the nfs mount options? No, they are async mounts. Timo Sirainen wrote: On Thu, 2009-07-30 at 10:07 -0600, CJ Keist wrote: Okay, I think I got a test that can recreate the .lock file staying around so long. I have trash folder with about 3500 messages in it. I went in and deleted two messages from the Trash folder. How close to the end of the mailbox did you delete the messages from? I then clicked back to my inbox. There was a long pause where Thunderbird was saying Closing folder Then another long pause as it said Opening folder. After about two minutes thunderbird looks to have stopped processing and displayed my inbox. But the Trash.lock file stuck around for about another 5 minutes. Ran ptruss on the pid that still had the Trash folder open. There was no pid for the Trash.lock file during this time. What do you mean by this? Trash.lock didn't have a PID in it, but you found the PID anyway somehow? It looks to be doing seeks, stats, reads and writes over and over again. Attached is a partial listing of the ptruss command till the lock file went away. It looks like you deleted some messages over 4 MB from the end of file, and Dovecot just moves 4 MB data over the deleted one. It looks like it's being done in pretty inefficient way though.. I guess I should some day improve it, but that's probably going to be annoyingly difficult. Anyway, if you look at where most of the time is spent, it's in the pwrite64() calls. Many of them can take almost 0.1 seconds. Have you enabled synchronous writes or something? -- C. J. Keist Email: cj.ke...@colostate.edu UNIX/Network ManagerPhone: 970-491-0630 Engineering Network ServicesFax: 970-491-5569 College of Engineering, CSU Ft. Collins, CO 80523-1301 All I want is a chance to prove 'Money can't buy happiness'
[Dovecot] POSIX stupidity
On Thu, 2009-07-30 at 13:44 -0400, Timo Sirainen wrote: RETURN VALUE posix_fallocate() returns zero on success, or an error number on fail‐ ure. Note that errno is not set. What the hell were POSIX people thinking?? This is the first syscall I've seen that behaves like this, and apparently without any good reason! Wonder how many other new system calls there are like this, that I haven't noticed yet.. Looks like all posix_*() syscalls do that. Wonder if there are more. signature.asc Description: This is a digitally signed message part
Re: [Dovecot] lock files causing time outs with Thunderbird
On Thu, 2009-07-30 at 11:56 -0600, CJ Keist wrote: The two message were at the end of the Trash folder. Is it possible that some older messages were also marked as \Deleted, and when you expunged the two at the end it also expunged something from the middle? (The truss really looks like something like that happened) I used fuser to find the pids on the Trash and Trash.lock files. fuser reported no pid for the Trash.lock file. The the ptruss was run on the pid on the Trash file. OK. The Trash.lock file isn't kept open, so that's why fuser didn't find it. By synchronous writes I'm assuming on the nfs mount options? No, they are async mounts. Actually now that I think of it, it's pretty unsafe if write is performed only locally without waiting for reply from NFS server that it got it. signature.asc Description: This is a digitally signed message part
[Dovecot] Limiting user access
Hello, Is there a way to restrict clients access, for example: us...@domain.com - only access pop3 us...@domain.com - can access pop3 and imap in Dovecot? Thanks !!!
Re: [Dovecot] POSIX stupidity
On Thu, 2009-07-30 at 20:21 +0200, Remi Gacogne wrote: Le jeudi 30 juillet 2009, Timo Sirainen a écrit : What the hell were POSIX people thinking?? This is the first syscall I've seen that behaves like this, and apparently without any good reason! Wonder how many other new system calls there are like this, that I haven't noticed yet.. Looks like all posix_*() syscalls do that. Wonder if there are more. Looks like too many people were incorrectly using errno, especially in multi- threaded context. From http://www.unix.org/whitepapers/reentrant.html : In addition, all POSIX.1c functions avoid using errno and, instead, return the error number directly as the function return value, with a return value of zero indicating that no error was detected. This strategy is, in fact, being followed on a POSIX-wide basis for all new functions. But that doesn't solve anything, because old functions' API can't be changed. The only thing this change did was to make it more difficult for programmers to remember how functions' error handling should be done. In both APIs the success is indicated by returning 0, which makes it especially difficult to notice when it's being used wrong. If they really had to change this, it would have been much better to both set errno and return -error, that way it would have allowed also 2/3 of the old style error checks: if (posix_fallocate(..) 0) perror() // works if (posix_fallocate(..) != 0) perror() // works if (posix_fallocate(..) == -1) perror() // doesn't work Now none of them work. I did also a quick google code search for posix_fallocate and found several other programs that handle the error wrong. And I'm sure it's only going to grow. Oh well, maybe some day gcc and libc add some features to catch at least the 0 and == -1 usage (which would already work if posix_fallocate() had been specified to return unsigned int, not int). signature.asc Description: This is a digitally signed message part
Re: [Dovecot] Limiting user access
On Thu, 2009-07-30 at 15:29 -0300, Darvin Denmian wrote: Is there a way to restrict clients access, for example: us...@domain.com - only access pop3 us...@domain.com - can access pop3 and imap in Dovecot? Yes. What passdb do you use? For example in SQL query you could use %s variable. http://wiki.dovecot.org/Variables You could also use an extra deny=yes passdb, for example: passdb passwd-file { deny = yes args = /etc/deny.%Ls } and then create /etc/deny.imap having a list of usernames not allowed to log in with imap. signature.asc Description: This is a digitally signed message part
Re: [Dovecot] Limiting user access
Thanks again Timo !!! On Thu, Jul 30, 2009 at 3:45 PM, Timo Sirainent...@iki.fi wrote: On Thu, 2009-07-30 at 15:29 -0300, Darvin Denmian wrote: Is there a way to restrict clients access, for example: us...@domain.com - only access pop3 us...@domain.com - can access pop3 and imap in Dovecot? Yes. What passdb do you use? For example in SQL query you could use %s variable. http://wiki.dovecot.org/Variables You could also use an extra deny=yes passdb, for example: passdb passwd-file { deny = yes args = /etc/deny.%Ls } and then create /etc/deny.imap having a list of usernames not allowed to log in with imap.
Re: [Dovecot] Several errors
On Thu, 2009-07-30 at 21:18 +0200, A. van Harten wrote: Mea culpa, mea maxima culpa. I am not a guru. I am just a nerd who just learned the basics of Linux. Everyone says I have to install Dovecot - but no-one is willing to give descent support... I'm pretty sure your questions would have gotten much worse answers in other IMAP server lists. Mails shouldn't be owned by root. Fine, then I change auth-user in my dovecot.conf from root to vmail. auth_user isn't mail user. auth_user can be root. http://wiki.dovecot.org/UserIds lists all users Dovecot needs/uses. I created a user called vmail, with UID 1000. There is also a group, called vmail, and the GID is 1000. Then what?? Some chown command? Or CHMOD? Made I a mistake on the commands I wrote before? If you have existing mails/files then yeah: chown -R vmail.vmail /var/mail Why do many people EXPECT that I am a guru? I think having basic Linux administrating skills can be expected when you're installing a mail server. signature.asc Description: This is a digitally signed message part