Re: [Dovecot] Convert plugin mbox to maildir has no effect
On Wed, 11 Apr 2007 23:10:53 +0200 guenther wrote: On Wed, 2007-04-11 at 08:57 +0200, Frank Elsner wrote: On Tue, 10 Apr 2007 17:58:03 +0200 guenther wrote: On Tue, 2007-04-10 at 17:06 +0300, Timo Sirainen wrote: On Sun, 2007-04-08 at 23:26 +0200, Frank Elsner wrote: Apr 8 23:13:36 seymour dovecot: IMAP(migrant): Mailbox conversion: Couldn't create mailbox directory .gnome2_private Maildir uses . as hierarchy separator, so this filename is invalid. I'm not sure if convert_skip_broken_mailboxes=yes should just cause these to be ignored, but for now it doesn't.. Just spotted the above error message (deleted previous posts already), and it strikes me as seriously odd. Dots in mbox file names are usually embedded (as in dovecot.org), where it makes sense, as opposed to beginning with a dot. Even worse, this particular name is kind of weird for a mail folder... However, this name is well known to me: [EMAIL PROTECTED] ~]$ ls -ld .gnome2_private drwx-- 2 guenther users 4096 Jul 21 2005 .gnome2_private/ Me Too :-) Hmm, so one of your users really got a mail folder named gnome2_private? Odd... No, of course. It's one of the dot files, which nearly each application creates. Anyway, another idea hit me -- is this really an invalid name, as Timo said? I don't know the convert plugin and what it logs, and I don't know the exact details of Maildir either. However, creating a mail folder named gnome2_private in your MUA will result in a dir by that name with a leading dot. Just like the name in the error message, no? Valid name or not, that's not the primary question. What abot the idea to ignore directories and check the contents of files for beeing am mail folder? If yes, then comes the question about the name. I'd check where the Maildir data actually is being created and what files are being attempted to convert. Almost looks like the Maildir dirs are being created in the users $HOME... No, dovecot.conf contains I did not want you to paste the settings again, but to check if the Maildir files are being created where you expect them. Grepping or changing conf files doesn't mean anything, if the running process doesn't use this particular version. ;) The Maildir directory was created, but no folder converted. BTW: Thanks for explaining trivia. :-) --Frank Elsner guenther -- char *t=[EMAIL PROTECTED]; main(){ char h,m=h=*t++,*x=t+2*h,c,i,l=*x,s=0; for (i=0;il;i++){ i%8? c=1: (c=*++x); c128 (s+=h); if (!(h=1)||!t[s+h]){ putchar(t[s]);h=m;s=0; }}}
Re: [Dovecot] Comment from OpenLDAP developer regarding deferring operations
On Wed, 2007-04-11 at 19:50 -0500, Ben Beuchler wrote: I'd note that if your client is performing search + bind on the same connection in an asynchronous manner, then the server behavior as per RFC4511 is undefined, since a server is not supposed to be willing to handle operations intermixed with binds until a bind is concluded. That is, any operation can be multiplexed on a single LDAP connection __except__ binds, which must be serialized. That's how I thought it was working. But I think I found a bug in there. See if the attached patch fixes it? Index: src/auth/db-ldap.c === RCS file: /var/lib/cvs/dovecot/src/auth/db-ldap.c,v retrieving revision 1.41.2.18 diff -u -r1.41.2.18 db-ldap.c --- src/auth/db-ldap.c 19 Jan 2007 15:27:42 - 1.41.2.18 +++ src/auth/db-ldap.c 12 Apr 2007 08:00:32 - @@ -196,6 +196,8 @@ request-callback(conn, request, NULL); return; } + db_ldap_add_delayed_request(conn, request); + return; } msgid = ldap_search(conn-ld, request-base, scope, signature.asc Description: This is a digitally signed message part
[Dovecot] [PATCH] Compile cleaning against OpenLDAP 2.3.x
Hi List Looks like OpenLDAP 2.3 doesn't define LDAP_DEPRECATED [1] anymore which causes a few warnings in Gentoo [2]. Attached is a patch that re-defines this so that dovecot can continue using simple functions like ldap_bind(). Thanks Roy [1] http://www.mail-archive.com/[EMAIL PROTECTED]/msg00487.html [2] http://bugs.gentoo.org/show_bug.cgi?id=162437diff -ur /tmp/dovecot-1.0.rc29/src/auth/db-ldap.h dovecot-1.0.rc29/src/auth/db-ldap.h --- /tmp/dovecot-1.0.rc29/src/auth/db-ldap.h 2007-01-19 15:15:13.0 + +++ dovecot-1.0.rc29/src/auth/db-ldap.h 2007-04-12 09:29:06.0 +0100 @@ -1,6 +1,10 @@ #ifndef __DB_LDAP_H #define __DB_LDAP_H +/* Functions like ldap_bind have been deprecated in openldap 2.3 + * This define enables them until the code here can be refactored */ +#define LDAP_DEPRECATED 1 + #include ldap.h struct auth_request;
Re: [Dovecot] Comment from OpenLDAP developer regarding deferring operations
I'll apply the patch later this morning and and let you know what I see. For what it's worth, last night I started dumping traffic between dovecot and openldap. The pattern I see most consistently was this: - bind request (anonymous) - search request - bind response - search result As I understand it, the search request being sent before the result of the bind request is received could trigger the deferrals. Thanks! -Ben On 4/12/07, Timo Sirainen [EMAIL PROTECTED] wrote: On Wed, 2007-04-11 at 19:50 -0500, Ben Beuchler wrote: I'd note that if your client is performing search + bind on the same connection in an asynchronous manner, then the server behavior as per RFC4511 is undefined, since a server is not supposed to be willing to handle operations intermixed with binds until a bind is concluded. That is, any operation can be multiplexed on a single LDAP connection __except__ binds, which must be serialized. That's how I thought it was working. But I think I found a bug in there. See if the attached patch fixes it?
Re: [Dovecot] Dovecot Assertion on mail server with POP3 and LDAP authentication
Timo Sirainen wrote: On 10.4.2007, at 20.31, Tim Alberts wrote: Apr 4 08:44:38 msi2 dovecot: auth(default): dovecot-auth: ../../../libraries/liblber/io.c:491: ber_get_next: Assertion `ber-ber_buf == ((void *)0)' failed. Apr 4 08:44:38 msi2 dovecot: auth(default): pam(secretuser,192.168.0.200): Child process died .. passdb: driver: pam userdb: driver: passwd So you're using pam_ldap and nss_ldap. See http://wiki.dovecot.org/AuthDatabase/Passwd So I'd suggest upgrading. Thank you for the quick response. It doesn't look like the problem I'm having though? I don't have problems with people getting other peoples email. I have problems with the Assertion errors that I mentioned. No, but it could very well be caused by the same problem. Just to close off this threadThis seems to have fixed the problem. I upgraded to a newer version and that alone made a huge difference. However, I didn't make the configuration changes I was supposed to at that time. The following day, I checked the server logs and saw the problem happen a couple times within a second and that was it. Significantly less, but it prompted me to read the dovecot website again and make the recommended configuration changes. Running for a couple days now, no problems and positive reports from the clients. Thank you for the resolution and best wishes to everyone.
Re: [Dovecot] Comment from OpenLDAP developer regarding deferring operations
On 4/12/07, Timo Sirainen [EMAIL PROTECTED] wrote: On Wed, 2007-04-11 at 19:50 -0500, Ben Beuchler wrote: I'd note that if your client is performing search + bind on the same connection in an asynchronous manner, then the server behavior as per RFC4511 is undefined, since a server is not supposed to be willing to handle operations intermixed with binds until a bind is concluded. That is, any operation can be multiplexed on a single LDAP connection __except__ binds, which must be serialized. That's how I thought it was working. But I think I found a bug in there. See if the attached patch fixes it? It does! Not a single deferring operation entry in nearly an hour! Now to wait and see if this change, Roy's patch, and linking against the new libldap_r can combine to eliminate my intermittent (and frustratingly non-reproducible) auth freezes. -Ben
[Dovecot] convert plugin created maildirfolder file in root maildir directory
I've noticed that if a user's maildir gets created by deliver or pop/imap without the convert plugin running, the maildir structure is fine (no maildirfolder file). But, if a user gets converted, there is a maildirfolder file in the user's base maildir directory. As far as I can tell, that doesn't cause any problems, but I just wanted to mention it. I've looked at the code for a while but didn't find why it behaves differently.
Re: [Dovecot] Connection refused with auth-master afterupgradingto Dovecot 1.0 rc 28
On Tue, 2007-04-10 at 13:12 -0600, Jason Warner wrote: Anyway I should be able to figure out the assert by looking at the code too. Just a bit more difficult, since a couple of minutes wasn't enough. :) This should fix it: http://dovecot.org/list/dovecot-cvs/2007-April/008653.html signature.asc Description: This is a digitally signed message part
Re: [Dovecot] convert plugin created maildirfolder file in root maildir directory
On Thu, 2007-04-12 at 12:33 -0400, Justin McAleer wrote: I've noticed that if a user's maildir gets created by deliver or pop/imap without the convert plugin running, the maildir structure is fine (no maildirfolder file). But, if a user gets converted, there is a maildirfolder file in the user's base maildir directory. As far as I can tell, that doesn't cause any problems, but I just wanted to mention it. I've looked at the code for a while but didn't find why it behaves differently. Dovecot doesn't care about maildirfolder file, but if you use a MDA that updates Maildir++ quota you could have problems. Fixed: http://dovecot.org/list/dovecot-cvs/2007-April/008659.html signature.asc Description: This is a digitally signed message part
[Dovecot] 1.0.rc32 released
http://dovecot.org/releases/dovecot-1.0.rc32.tar.gz http://dovecot.org/releases/dovecot-1.0.rc32.tar.gz.sig Pretty late for changes if v1.0 is supposed to come out tomorrow, but I can't really leave these LDAP bugs unfixed. They shouldn't anyway break anything, so here's one more day for you people to find out about any bugs. One thing that I'm a bit concerned about is the addition of #define LDAP_DEPRECATED. I know it fixes crashes with OpenLDAP 2.3 + 64bit systems, but I hope it doesn't break compiling with some old versions or non-OpenLDAP libraries.. - LDAP, auth_bind=no: Don't crash if doing non-plaintext ldap passdb lookup for unknown user. This also broke deliver when userdb static was used. - LDAP, auth_bind=yes and userdb ldap: We didn't wait until bind was finished before sending the userdb request, which could have caused problems. - LDAP: Don't break when compiling with OpenLDAP v2.3 library - Convert plugin: Don't create maildirfolder file to Maildir root. signature.asc Description: This is a digitally signed message part
Re: [Dovecot] 1.0.rc32 released
Well, it builds OK for me on Solaris 8 32-bit SPARC with OpenLDAP 2.3, with less complaints from gcc (3.3.2), just:- mail-index.c: In function `mail_index_parse_extensions': mail-index.c:343: warning: comparison between signed and unsigned mail-index.c: In function `mail_index_map_clone': mail-index.c:1294: warning: comparison between signed and unsigned idxview.c: In function `dump_hdr': idxview.c:89: warning: comparison between signed and unsigned idxview.c: In function `dump_cache_hdr': idxview.c:179: warning: comparison between signed and unsigned idxview.c:194: warning: comparison between signed and unsigned idxview.c: In function `dump_cache': idxview.c:243: warning: comparison between signed and unsigned idxview.c: In function `dump_record': idxview.c:345: warning: comparison between signed and unsigned whereas before I had:- db-ldap.c: In function `db_ldap_search': db-ldap.c:201: warning: implicit declaration of function `ldap_search' db-ldap.c: In function `db_ldap_bind_callback': db-ldap.c:425: warning: implicit declaration of function `ldap_result2error' db-ldap.c: In function `db_ldap_bind': db-ldap.c:443: warning: implicit declaration of function `ldap_bind' db-ldap.c: In function `db_ldap_connect': db-ldap.c:494: warning: implicit declaration of function `ldap_init' db-ldap.c:494: warning: assignment makes pointer from integer without a cast db-ldap.c: In function `ldap_conn_close': db-ldap.c:599: warning: implicit declaration of function `ldap_unbind' passdb-ldap.c: In function `ldap_query_save_attr': passdb-ldap.c:84: warning: implicit declaration of function `ldap_get_values' passdb-ldap.c:84: warning: assignment makes pointer from integer without a cast passdb-ldap.c:103: warning: implicit declaration of function `ldap_value_free' passdb-ldap.c: In function `handle_request_get_entry': passdb-ldap.c:155: warning: implicit declaration of function `ldap_result2error' passdb-ldap.c: In function `authbind_start': passdb-ldap.c:268: warning: implicit declaration of function `ldap_bind' userdb-ldap.c: In function `ldap_query_get_result': userdb-ldap.c:84: warning: implicit declaration of function `ldap_get_values' userdb-ldap.c:84: warning: assignment makes pointer from integer without a cast userdb-ldap.c:104: warning: implicit declaration of function `ldap_value_free' userdb-ldap.c: In function `handle_request': userdb-ldap.c:146: warning: implicit declaration of function `ldap_result2error' as well. Hopefully I'll manage to try some direct LDAP auth before tomorrow (we're using pam_ldap instead at the moment). I'll let you know if there are any issues. Best Wishes, Chris Timo Sirainen wrote: One thing that I'm a bit concerned about is the addition of #define LDAP_DEPRECATED. I know it fixes crashes with OpenLDAP 2.3 + 64bit systems, but I hope it doesn't break compiling with some old versions or non-OpenLDAP libraries.. -- --+---+---+---+---+---+---+---+---+---+---+---+---+---+---+---+---+---+- Christopher Wakelin, [EMAIL PROTECTED] IT Services Centre, The University of Reading, Tel: +44 (0)118 378 8439 Whiteknights, Reading, RG6 2AF, UK Fax: +44 (0)118 975 3094
Re: [Dovecot] 1.0.rc32 released
On Thu, 2007-04-12 at 18:58 +0100, Chris Wakelin wrote: Well, it builds OK for me on Solaris 8 32-bit SPARC with OpenLDAP 2.3, with less complaints from gcc (3.3.2), just:- mail-index.c: In function `mail_index_parse_extensions': mail-index.c:343: warning: comparison between signed and unsigned mail-index.c: In function `mail_index_map_clone': mail-index.c:1294: warning: comparison between signed and unsigned idxview.c: In function `dump_hdr': idxview.c:89: warning: comparison between signed and unsigned idxview.c: In function `dump_cache_hdr': idxview.c:179: warning: comparison between signed and unsigned idxview.c:194: warning: comparison between signed and unsigned idxview.c: In function `dump_cache': idxview.c:243: warning: comparison between signed and unsigned idxview.c: In function `dump_record': idxview.c:345: warning: comparison between signed and unsigned These should all go away with a newer gcc. whereas before I had:- db-ldap.c: In function `db_ldap_search': db-ldap.c:201: warning: implicit declaration of function `ldap_search' The LDAP_DEPRECATED define should have fixed these. Maybe your ldap.h doesn't have the deprecated functions at all for some reason? Or did I somehow mess up applying the deprecated-patch. :) I'd anyway try fixing these warnings before trying to run the code. I guess they should work with 32bit systems without crashing, but I wouldn't bet on it. signature.asc Description: This is a digitally signed message part
Re: [Dovecot] 1.0.rc32 released
The LDAP_DEPRECATED define should have fixed these. Maybe your ldap.h doesn't have the deprecated functions at all for some reason? Or did I somehow mess up applying the deprecated-patch. :) rc32 builds cleanly for me (only a few minor warnings) and seems to be running well. Thanks! -Ben
[Dovecot] Moving Maildir files from multiple Dovecot installs
I currently have Dovecot running on a SuSE SLES 10 mail server with postfix as the MTA and a number of real linux users. I have postfix delivering to Maildir records. We are going to convert to a virtual user/domain system with PostfixAdmin. I have checked out all of our settings and they appear to work well except for a problem with authenticating against mySQL using MD5-Crypt; plaintext works well however. My question is how to transfer the maildir files from the real users Maildirs to the created virtual users. When creating a mail user PostfixAdmin will create the maildir directory. Once this is created can I simply rsync the complete old directory including the dovecot files to the new mailbox? Sorry for the newbie question. Many Thanks - We won't tell. Get more on shows you hate to love (and love to hate): Yahoo! TV's Guilty Pleasures list.