Re: [Dovecot] 2.1.10 crashes at login (buf->used <= buf->alloc)

2012-09-18 Thread Timo Sirainen
On 19.9.2012, at 0.18, interfaSys sàrl wrote:

> I thought it would be easily identifiable and a common problem, but
> apparently not :)
..
> #8  0x109c770b in antispam_user_created (user=0x10a83040) at
> user.c:17

Did you recompile antispam plugin? Is it the latest antispam? This line doesn't 
seem to match the current code.



Re: [Dovecot] 2.1.10 crashes at login (buf->used <= buf->alloc)

2012-09-18 Thread interfaSys sàrl
I thought it would be easily identifiable and a common problem, but
apparently not :)

Here is the trace:
(gdb) bt full
#0  0x10709ebc in kill () from /lib/libc.so.7
No symbol table info available.
#1  0x10708e43 in abort () from /lib/libc.so.7
No symbol table info available.
#2  0x105b8e65 in default_fatal_finish.14395 () from
/usr/lib/dovecot/libdovecot.so.0
No symbol table info available.
#3  0x10588e3d in i_internal_fatal_handler.14399 () from
/usr/lib/dovecot/libdovecot.so.0
No symbol table info available.
#4  0x105e4941 in i_panic () from /usr/lib/dovecot/libdovecot.so.0
No symbol table info available.
#5  0x105e7c77 in buffer_check_limits.13467 () from
/usr/lib/dovecot/libdovecot.so.0
No symbol table info available.
#6  0x105e7a6a in buffer_write () from
/usr/lib/dovecot/libdovecot.so.0
No symbol table info available.
#7  0x105ce9f9 in array_idx_set_i () from
/usr/lib/dovecot/libdovecot.so.0
No symbol table info available.
#8  0x109c770b in antispam_user_created (user=0x10a83040) at
user.c:17
_module_tmp = (void *) 0x10a84d28
asu = (struct antispam_user *) 0x10a84d28
tmp = 0x0
#9  0x104f1f04 in hook_mail_user_created () from
/usr/lib/dovecot/libdovecot-storage.so.0
No symbol table info available.
#10 0x104efaf9 in mail_user_init () from
/usr/lib/dovecot/libdovecot-storage.so.0
No symbol table info available.
#11 0x10495858 in mail_storage_service_init_post.46586.6405 ()
from /usr/lib/dovecot/libdovecot-storage.so.0
No symbol table info available.
#12 0x10495582 in mail_storage_service_next () from
/usr/lib/dovecot/libdovecot-storage.so.0
No symbol table info available.
#13 0x104951b3 in mail_storage_service_lookup_next () from
/usr/lib/dovecot/libdovecot-storage.so.0
No symbol table info available.
#14 0x0041f112 in client_create_from_input
(input=0x7fffe940, login_client=0x10a550c0, fd_in=11, fd_out=11,
input_buf=0x7fffe900,
error_r=0x7fffe938) at main.c:202
user = (struct mail_storage_service_user *) 0x10a55141
mail_user = (struct mail_user *) 0x3
client = (struct client *) 0x7fffec70
set = (const struct imap_settings *) 0x7fffe900
flags = 32767
#15 0x0041eeaa in login_client_connected (client=0x10a550c0,
username=0x10a04093 "t...@example.com", extra_fields=0x10a04118)
at main.c:272
input = {module = 0x423d0f "imap", service = 0x423d0f "imap",
username = 0x10a04093 "t...@example.com",
  session_id = 0x10a55120 "UCFMXQDK5gBewxZf", local_ip = {family = 2, u
= {ip6 = {__u6_addr = {__u6_addr8 = "N.8Q", '\0' ,
  __u6_addr16 = {11854, 20792, 0, 0, 0, 0, 0, 0}, __u6_addr32 =
{1362636366, 0, 0, 0}}}, ip4 = {s_addr = 1362636366}}}, remote_ip =
{family = 2,
u = {ip6 = {__u6_addr = {__u6_addr8 = "^¦\026_", '\0' , __u6_addr16 = {50014, 24342, 0, 0, 0, 0, 0, 0}, __u6_addr32 =
{1595327326,
0, 0, 0}}}, ip4 = {s_addr = 1595327326}}}, local_port = 0,
remote_port = 0, userdb_fields = 0x10a04118, flags_override_add = 0,
  flags_override_remove = 0, no_userdb_lookup = 0}
error = (const __unknown__ *) 0x0
input_buf = {data = 0x10a55141, used = 3, priv = {0x0, 0x0, 0x3,
0x0, 0x0}}
#16 0x105a229f in master_login_auth_finish.11302 () from
/usr/lib/dovecot/libdovecot.so.0
No symbol table info available.
#17 0x105efa50 in master_login_auth_callback.11253.2275 () from
/usr/lib/dovecot/libdovecot.so.0
No symbol table info available.
#18 0x10596f56 in master_login_auth_input_user.11520 () from
/usr/lib/dovecot/libdovecot.so.0
No symbol table info available.
#19 0x1058bf99 in master_login_auth_input.11492 () from
/usr/lib/dovecot/libdovecot.so.0
No symbol table info available.
#20 0x105e9b34 in io_loop_call_io () from
/usr/lib/dovecot/libdovecot.so.0
No symbol table info available.
#21 0x105d1ba7 in io_loop_handler_run () from
/usr/lib/dovecot/libdovecot.so.0
No symbol table info available.
#22 0x105d1a55 in io_loop_run () from
/usr/lib/dovecot/libdovecot.so.0
No symbol table info available.
#23 0x105d1790 in master_service_run () from
/usr/lib/dovecot/libdovecot.so.0
No symbol table info available.
#24 0x0041ed5d in main (argc=1, argv=0x7fffec60) at main.c:389
set_roots = {0x424020, 0x0}
login_set = {auth_socket_path = 0x10a04068
"/var/run/dovecot/auth-master", postlogin_socket_path = 0x0,
postlogin_timeout_secs = 60,
  callback = 0x41ed9d , failure_callback =
0x4194ee }
service_flags = MASTER_SERVICE_FLAG_KEEP_CONFIG_OPEN
storage_service_flags = MAIL_STORAGE_SERVICE_FLAG_DISALLOW_ROOT
username = (const __unknown__ *) 0x0
c = -1
set_roots = {0x424020, 0x0}


Cheers,

Olivier



On 18/09/2012 21:42, Timo Sirainen wrote:
> On 18.9.2012, at 23.32, interfaSys sàrl wrote:
> 
>> There is a big problem with 2.1.10.
>>
>> Here is what I saw 

Re: [Dovecot] 2.1.10 crashes at login (buf->used <= buf->alloc)

2012-09-18 Thread Timo Sirainen
On 18.9.2012, at 23.32, interfaSys sàrl wrote:

> There is a big problem with 2.1.10.
> 
> Here is what I saw in the logs:
> Sep 18 22:22:23 imap(): Panic: file buffer.c: line 86
> (buffer_check_limits): assertion failed: (buf->used <= buf->alloc)
> Sep 18 22:22:23 imap(): Fatal: master: service(imap): child 26833 killed
> with signal 6 (core dumped)
> 
> Reverting to 2.1.9 with the exact same config file works just fine

gdb backtrace? http://dovecot.org/bugreport.html



Re: [Dovecot] 2.1.10 crashes at login (buf->used <= buf->alloc)

2012-09-18 Thread Ralf Hildebrandt
* interfaSys sàrl :
> Hello,
> 
> There is a big problem with 2.1.10.
> 
> Here is what I saw in the logs:
> Sep 18 22:22:23 imap(): Panic: file buffer.c: line 86
> (buffer_check_limits): assertion failed: (buf->used <= buf->alloc)
> Sep 18 22:22:23 imap(): Fatal: master: service(imap): child 26833 killed
> with signal 6 (core dumped)
> 
> Reverting to 2.1.9 with the exact same config file works just fine

So far I'm not having problems wit 2.1.10 here (coming from 2.1.9)

-- 
Ralf Hildebrandt
  Geschäftsbereich IT | Abteilung Netzwerk
  Charité - Universitätsmedizin Berlin
  Campus Benjamin Franklin
  Hindenburgdamm 30 | D-12203 Berlin
  Tel. +49 30 450 570 155 | Fax: +49 30 450 570 962
  ralf.hildebra...@charite.de | http://www.charite.de



[Dovecot] 2.1.10 crashes at login (buf->used <= buf->alloc)

2012-09-18 Thread interfaSys sàrl
Hello,

There is a big problem with 2.1.10.

Here is what I saw in the logs:
Sep 18 22:22:23 imap(): Panic: file buffer.c: line 86
(buffer_check_limits): assertion failed: (buf->used <= buf->alloc)
Sep 18 22:22:23 imap(): Fatal: master: service(imap): child 26833 killed
with signal 6 (core dumped)

Reverting to 2.1.9 with the exact same config file works just fine

Cheers,

Olivier


[Dovecot] Released Pigeonhole v0.3.3 for Dovecot v2.1.10

2012-09-18 Thread Stephan Bosch

Hello Dovecot users,

Version 0.3.2 was a bit broken, because it failed to compile against 
installed Dovecot headers.


Changelog v0.3.3:

- Fixed compile against installed Dovecot headers. This was broken by
  the ld.gold fix in the previous release.

The release is available as follows:

http://www.rename-it.nl/dovecot/2.1/dovecot-2.1-pigeonhole-0.3.3.tar.gz
http://www.rename-it.nl/dovecot/2.1/dovecot-2.1-pigeonhole-0.3.3.tar.gz.sig

Refer to http://pigeonhole.dovecot.org and the Dovecot v2.x wiki for 
more information. Have fun testing this new release and don't hesitate 
to notify me when there are any problems.


Regards,

--
Stephan Bosch
step...@rename-it.nl













Re: [Dovecot] lda bug: multiple passdb ignored

2012-09-18 Thread Anthony Pankov
Hello Timo,

Tuesday, September 18, 2012, 8:58:53 PM, you wrote:

TS> On 18.9.2012, at 14.04, Алексей Панкратов wrote:

>> When dovecot configured to use multiple passdb and static userdb as:
TS> ..
>> all works fine but...
>> 
>> When LDA deliver mail it check passdb but only first appeared in 
>> configuration:
>> 
>> 18.09.2012 15:00:18 auth: Debug: master in: USER1   i...@zzz.zz  
>> service=lda
>> 18.09.2012 15:00:18 auth: Debug: cache(i...@zzz.zz): miss
>> 18.09.2012 15:00:18 auth: Debug: ldap(i...@zzz.zz): pass search: 
>> base=ou=account,ou=it,dc=planar,dc=local scope=subtree 
>> filter=(&(objectClass=x-mailUser)(uid=info)) fields=x-mailPassword
>> 18.09.2012 15:00:18 lda: Debug: auth input:
>> 18.09.2012 15:00:18 auth: Debug: cache(i...@planar.spb.ru): hit:
>> 18.09.2012 15:00:18 auth: Debug: master out: NOTFOUND   1 1

TS> This was an interesting bug. Fixed: 
http://hg.dovecot.org/dovecot-2.1/rev/c38060f0ad58

 
Thank you very much.


-- 
Best regards,
 Anthonymailto:a...@mail.ru




[Dovecot] v2.1.10 released

2012-09-18 Thread Timo Sirainen
http://dovecot.org/releases/2.1/dovecot-2.1.10.tar.gz
http://dovecot.org/releases/2.1/dovecot-2.1.10.tar.gz.sig

The director bugfix is pretty important at least when running in two
director setups, since it can break the directors until both of them are
manually shut down. I'm not entirely sure if the same happens in >2
director setups, but I'd think so (although I do wonder why I haven't
seen it happen in them).

BTW. I'm hoping for v2.2.alpha1 release within a week or two and to get
it stabilized rather quickly.

+ imap: Implemented THREAD=ORDEREDSUBJECT extension.
+ Added "doveadm exec" command to easily execute commands from
  libexec_dir, e.g. "doveadm exec imap -u user@domain"
+ Added "doveadm copy" command.
+ doveadm copy/move: Added optional user parameter to specify the
  source username. This allows easily copying mails between different
  users.
+ Added namespace { disabled } setting to quickly enable/disable
  namespaces. This is especially useful when its value is returned by
  userdb.
+ Added mailbox_alias plugin. It allows creating mailbox aliases using
  symlinks.
+ imapc storage: Added imapc_max_idle_time setting to force activity
  on connection.
+ fts-solr: Expunging multiple messages is now faster.
- director: In some conditions director may have disconnected from
  another director (without logging about it), thinking it was sending
  invalid data.
- imap: Various fixes to listing mailboxes.
- pop3-migration plugin: Avoid disconnection from POP3 server due
  to idling.
- login processes crashed if there were a lot of local {} or remote {}
  settings blocks.




Re: [Dovecot] Released Pigeonhole v0.3.2 for Dovecot v2.1.9

2012-09-18 Thread Stephan Bosch

On 9/18/2012 8:18 PM, Juan C. Blanco wrote:
Hi Stephan, I'm traying to rebuild the RH (Centos) EL5 RPM with the 
new pigeonhole version, however I've got the follwing errors when 
compiling:


It seems that the error is related to the ld.gold fix, If I revert the 
c52a0c561311 patch the error is not produced


Oh d'oh. Yes, it related to that. I fixed it for Dovecot v2.2 before, 
but I forgot the Dovecot v2.1 tree. Fixed now:


http://hg.rename-it.nl/dovecot-2.2-pigeonhole/rev/66adbdd89d5c

This only happens when you compile against installed Dovecot headers, 
people using --with-dovecot= (like me) would not have seen this.


I'll push out a new release once 2.1.10 comes out. I'm being told that 
is imminent.


Regards,

Stephan.




Re: [Dovecot] Released Pigeonhole v0.3.2 for Dovecot v2.1.9

2012-09-18 Thread Juan C. Blanco
Hi Stephan, I'm traying to rebuild the RH (Centos) EL5 RPM with the new 
pigeonhole version, however I've got the follwing errors when compiling:


gcc -shared  .libs/rfc2822.o .libs/edit-mail.o .libs/sieve-settings.o 
.libs/sieve-message.o .libs/sieve-smtp.o .libs/sieve-lexer.o 
.libs/sieve-script.o .libs/sieve-script-file.o .libs/sieve-script-dict.o 
.libs/sieve-ast.o .libs/sieve-binary.o .libs/sieve-binary-file.o 
.libs/sieve-binary-code.o .libs/sieve-binary-debug.o 
.libs/sieve-parser.o .libs/sieve-address.o .libs/sieve-validator.o 
.libs/sieve-generator.o .libs/sieve-interpreter.o 
.libs/sieve-runtime-trace.o .libs/sieve-code-dumper.o 
.libs/sieve-binary-dumper.o .libs/sieve-result.o .libs/sieve-error.o 
.libs/sieve-objects.o .libs/sieve-stringlist.o .libs/sieve-comparators.o 
.libs/sieve-match-types.o .libs/sieve-address-parts.o 
.libs/sieve-match.o .libs/sieve-commands.o .libs/sieve-code.o 
.libs/sieve-actions.o .libs/sieve-extensions.o .libs/sieve-plugins.o 
.libs/cmp-i-octet.o .libs/cmp-i-ascii-casemap.o .libs/mcht-is.o 
.libs/mcht-contains.o .libs/mcht-matches.o .libs/tst-truefalse.o 
.libs/tst-not.o .libs/tst-anyof.o .libs/tst-allof.o .libs/tst-address.o 
.libs/tst-header.o .libs/tst-exists.o .libs/tst-size.o 
.libs/cmd-require.o .libs/cmd-stop.o .libs/cmd-if.o .libs/cmd-keep.o 
.libs/cmd-redirect.o .libs/cmd-discard.o .libs/ext-fileinto.o 
.libs/ext-reject.o .libs/ext-envelope.o .libs/ext-encoded-character.o 
.libs/sieve.o -Wl,--whole-archive 
../../src/lib-sieve/plugins/vacation/.libs/libsieve_ext_vacation.a 
../../src/lib-sieve/plugins/subaddress/.libs/libsieve_ext_subaddress.a 
../../src/lib-sieve/plugins/comparator-i-ascii-numeric/.libs/libsieve_ext_comparator-i-ascii-numeric.a 
../../src/lib-sieve/plugins/relational/.libs/libsieve_ext_relational.a 
../../src/lib-sieve/plugins/regex/.libs/libsieve_ext_regex.a 
../../src/lib-sieve/plugins/copy/.libs/libsieve_ext_copy.a 
../../src/lib-sieve/plugins/imap4flags/.libs/libsieve_ext_imap4flags.a 
../../src/lib-sieve/plugins/include/.libs/libsieve_ext_include.a 
../../src/lib-sieve/plugins/body/.libs/libsieve_ext_body.a 
../../src/lib-sieve/plugins/variables/.libs/libsieve_ext_variables.a 
../../src/lib-sieve/plugins/enotify/.libs/libsieve_ext_enotify.a 
../../src/lib-sieve/plugins/notify/.libs/libsieve_ext_notify.a 
../../src/lib-sieve/plugins/environment/.libs/libsieve_ext_environment.a 
../../src/lib-sieve/plugins/mailbox/.libs/libsieve_ext_mailbox.a 
../../src/lib-sieve/plugins/date/.libs/libsieve_ext_date.a 
../../src/lib-sieve/plugins/spamvirustest/.libs/libsieve_ext_spamvirustest.a 
../../src/lib-sieve/plugins/ihave/.libs/libsieve_ext_ihave.a 
../../src/lib-sieve/plugins/editheader/.libs/libsieve_ext_editheader.a 
../../src/lib-sieve/plugins/vnd.dovecot/debug/.libs/libsieve_ext_debug.a 
../../src/lib-sieve/plugins/vnd.dovecot/duplicate/.libs/libsieve_ext_duplicate.a 
-Wl,--no-whole-archive  -Wl,--rpath -Wl,/usr/lib64/dovecot 
-L/var/tmp/dovecot-2.1-pigeonhole-0.3.2-219_3-root/usr/lib64/dovecot 
-L/usr/lib64/dovecot -ldovecot-lda 
-L/home/jc/rpmbuild/BUILD/dovecot-2.1.9/src/lib-storage/.libs 
-L/usr/kerberos/lib64 
-L/home/jc/rpmbuild/BUILD/dovecot-2.1.9/src/lib-dovecot/.libs -lrt  -m64 
-mtune=generic -Wl,-soname -Wl,libdovecot-sieve.so.0 -o 
.libs/libdovecot-sieve.so.0.0.0

/usr/bin/ld: cannot find -ldovecot-lda
collect2: ld returned 1 exit status
libtool: install: error: relink `libdovecot-sieve.la' with the above 
command before installing it

make[4]: *** [install-dovecot_pkglibLTLIBRARIES] Error 1
make[4]: Leaving directory 
`/home/jc/rpmbuild/BUILD/dovecot-2.1-pigeonhole-0.3.2/src/lib-sieve'

make[3]: *** [install-am] Error 2
make[3]: Leaving directory 
`/home/jc/rpmbuild/BUILD/dovecot-2.1-pigeonhole-0.3.2/src/lib-sieve'

make[2]: *** [install-recursive] Error 1
make[2]: Leaving directory 
`/home/jc/rpmbuild/BUILD/dovecot-2.1-pigeonhole-0.3.2/src/lib-sieve'

make[1]: *** [install-recursive] Error 1
make[1]: Leaving directory 
`/home/jc/rpmbuild/BUILD/dovecot-2.1-pigeonhole-0.3.2/src'

make: *** [install-recursive] Error 1
error: Bad exit status from /var/tmp/rpm-tmp.50565 (%install)


It seems that the error is related to the ld.gold fix, If I revert the 
c52a0c561311 patch the error is not produced


Regards



Re: [Dovecot] Changing Quota downward for special Mailboxes? (2.1.6)

2012-09-18 Thread Robert Schetterer
Am 18.09.2012 18:17, schrieb Timo Sirainen:
> On 18.9.2012, at 14.40, Jost Krieger wrote:
> 
>> It seems there is no way to correct te quota limit downward for some
>> mailboxes, like:
>>
>> quota_rule9 = UCE-TMP:storage=-10%%
>>
>> The idea is to not eat up the users storage with spam, so that spam
>> stays in the queue (for some time) while real mail gets delivered.
> 
> Interesting idea. This was pretty easy to fix:
> 
> http://hg.dovecot.org/dovecot-2.1/rev/74d639b2a5bf
> 
> Now, the next problem is that if LDA can't save the message to UCE-TMP 
> because of quota failure it saves it to INBOX. I'm not really sure how that 
> should be fixed, since generally it's a good idea to do it..
> 

some allready existing way is i.e
with milter and postfix tagged spam get in hold queue for i.e human
admin investigate, or some quarantaine with amavis
for sure there are benefits getting dovecot involved in spam tagging
but i would leave spam tagging to the mailserver in first way and
deliver it to Junk folder by global sieve rule with giving more quota or
ignoring  Quota to Junk folder, but i see this isnt the same what you
might wanna goal

-- 
Best Regards
MfG Robert Schetterer


Re: [Dovecot] lda bug: multiple passdb ignored

2012-09-18 Thread Timo Sirainen
On 18.9.2012, at 14.04, Алексей Панкратов wrote:

> When dovecot configured to use multiple passdb and static userdb as:
..
> all works fine but...
> 
> When LDA deliver mail it check passdb but only first appeared in 
> configuration:
> 
> 18.09.2012 15:00:18 auth: Debug: master in: USER1   i...@zzz.zz   
>service=lda
> 18.09.2012 15:00:18 auth: Debug: cache(i...@zzz.zz): miss
> 18.09.2012 15:00:18 auth: Debug: ldap(i...@zzz.zz): pass search: 
> base=ou=account,ou=it,dc=planar,dc=local scope=subtree 
> filter=(&(objectClass=x-mailUser)(uid=info)) fields=x-mailPassword
> 18.09.2012 15:00:18 lda: Debug: auth input:
> 18.09.2012 15:00:18 auth: Debug: cache(i...@planar.spb.ru): hit:
> 18.09.2012 15:00:18 auth: Debug: master out: NOTFOUND   1 1

This was an interesting bug. Fixed: 
http://hg.dovecot.org/dovecot-2.1/rev/c38060f0ad58



Re: [Dovecot] lda bug: multiple passdb ignored

2012-09-18 Thread Anthony Pankov
Hello Timo,

Tuesday, September 18, 2012, 8:04:06 PM, you wrote:

TS> On 18.9.2012, at 14.04, Алексей Панкратов wrote:

>> passdb {
>>driver = ldap
>>args = /usr/local/etc/dovecot/dv-ldap-virtual.conf
>> }

TS> Does dv-ldap-virtual.conf have auth_bind=yes?

No.
All ldap connection configured to use one prescribed ldap binding.

P.S. Thank you for your work.


-- 
Best regards,
 Anthonymailto:a...@mail.ru




Re: [Dovecot] Proxy connection timeouts

2012-09-18 Thread Timo Sirainen
On 18.9.2012, at 2.02, Kelsey Cummings wrote:

> We are seeing a few (0-15) proxy failures like the following out of ~3m 
> successful proxied connections a day. Average session creation load over our 
> peak hour is about 47/sec.  The backend servers aren't logging anything that 
> would suggest any internal problem like insufficient processes to handle the 
> load.  It doesn't seem to happen when utilization is lowest at night.
> 
> dovecot: imap-login: Error: proxy(foo): connect(1.1.1.1, 143) failed: 
> Connection timed out (after 63 secs)
> 
> I'm curious if anyone else has seen any similar problems or has any 
> suggestions.

I once had similar problems when the proxy backend was Courier. The problems 
went away after migration to Dovecot was complete. The possibilities are either:

a) The backend server is busy and doesn't have a chance to accept() the 
connection.

b) Packets get dropped in the network and the retry packet is slow in coming 
(or also gets lost).

Changing some kernel settings might help with a). There are also kernel 
settings that specify how SYN resend is attempted, you could try reducing it to 
a few seconds.



Re: [Dovecot] Syntax for doveadm auth cache

2012-09-18 Thread Timo Sirainen
On 18.9.2012, at 9.59, Angel L. Mateo wrote:

>>> So I'm running this command. Whenever I run it, I get the message that 
>>> 3 (sometimes, is 4) entries are removed, but user information isn't really 
>>> reloaded and I doubt it is really removed from cache (I have the user in a 
>>> passwd-file and information used by imap processes is still the old one, no 
>>> the new one, changed before the flush)
>> 
>> Works in my tests.
>> 
>   Is this cache the same than the user information cache?

Yes.

>   The parameter of the user I want to change is his quota, so I have 
> modified quota value in my ldap diretory, then I run:
> 
> doveadm auth cache flush 

What is your doveconf -n output and the dovecot-ldap.conf contents? Is  
with or without @domain? Also try this:

doveadm auth cache flush foo # make sure it isn't there
doveadm user foo
doveadm auth cache flush foo

Does the second flush return 1 or 0 entries? If 0, then there's a problem. If 
1, then it really should have worked.

You could try also if disabling userdb prefetch makes any difference. And if 
you still have multiple userdb try with only one.

Re: [Dovecot] Changing Quota downward for special Mailboxes? (2.1.6)

2012-09-18 Thread Timo Sirainen
On 18.9.2012, at 14.40, Jost Krieger wrote:

> It seems there is no way to correct te quota limit downward for some
> mailboxes, like:
> 
> quota_rule9 = UCE-TMP:storage=-10%%
> 
> The idea is to not eat up the users storage with spam, so that spam
> stays in the queue (for some time) while real mail gets delivered.

Interesting idea. This was pretty easy to fix:

http://hg.dovecot.org/dovecot-2.1/rev/74d639b2a5bf

Now, the next problem is that if LDA can't save the message to UCE-TMP because 
of quota failure it saves it to INBOX. I'm not really sure how that should be 
fixed, since generally it's a good idea to do it..



Re: [Dovecot] lda bug: multiple passdb ignored

2012-09-18 Thread Timo Sirainen
On 18.9.2012, at 14.04, Алексей Панкратов wrote:

> passdb {
>driver = ldap
>args = /usr/local/etc/dovecot/dv-ldap-virtual.conf
> }

Does dv-ldap-virtual.conf have auth_bind=yes?



Re: [Dovecot] Mailbox aliases

2012-09-18 Thread Timo Sirainen
This is now implemented as a plugin in hg. Usage in the commit message: 
http://hg.dovecot.org/dovecot-2.1/rev/f5bb9f6b304d

Also there's a generic change where symlinks within same directory are treated 
as mailbox aliases, which aren't counted towards quota.

On 2.9.2012, at 18.32, Timo Sirainen wrote:

> I've been wondering about ways to handle all the various different Sent/Sent 
> Messages/Sent Items/etc mailboxes that different clients create and if there 
> could be a way to make them work at least somewhat better. I'm mainly 
> thinking about ISP-like installations where users are using tons of different 
> clients and there's no way to get everyone configured properly. Of course the 
> eventual solution is hopefully that all the clients will support SPECIAL-USE 
> extension, but while waiting for that maybe mailbox aliases could help some.
> 
> So one possibility would be to force autocreation of wanted specific mailbox 
> names, and create aliases for the other commonly used mailboxes. The main 
> difference here for the current behavior is that all of the mailboxes would 
> contain the same mails, instead of different mails going to different 
> mailboxes with different clients. So for example:
> 
> ..
> mailbox Sent {
>  auto = create
>  special_use = \Sent
> }
> mailbox "Sent Messages" {
>  special_use = \Sent
>  alias_for = Sent
> }
> ..
> 
> If "Sent Messages" doesn't exist:
> - DELETE Sent works as usual
> - RENAME Sent works as usual
> 
> If "Sent Messages" is created:
> - it's symlinked to Sent
> - DELETE "Sent messages" deletes the symlink, not the contents
> - RENAME "Sent messages" isn't allowed
> - DELETE/RENAME Sent fails with message: Delete/Rename for Sent not allowed 
> before "Sent Messages" is deleted.
> 
> Thoughts?
> 
> The main disadvantage is that clients would still see two different 
> mailboxes, and some would download contents from both of them.
> 
> I was thinking about creating some wiki page which could list the best 
> working configurations and also a client list, which would specify if it 
> supports SPECIAL-USE and what the default mailbox names it uses are.



[Dovecot] Released Pigeonhole v0.3.2 for Dovecot v2.1.9

2012-09-18 Thread Stephan Bosch

Hello Dovecot users,

I've been busy recently with some wholly unrelated Dovecot IMAP patches, 
so Sieve development moved a bit into the background. This release 
therefore consists mostly of small bugfixes. The most important change 
is the fix of a bug in ManageSieve's CHECKSCRIPT command that causes a 
segfault. Quite a few people have encountered this problem recently, so 
it is about time I release this now.


Changelog v0.3.2:

+ sieve-refilter tool: improved man page documentation by explicitly
  specifying the syntax used for mailbox arguments.
+ Sieve: spamtest and virustest extensions: improved trace debugging of
  score calculation.
+ Sieve: made error messages about exceeding the maximum number of
  actions more verbose.
- Sieve tools: fixed problems with running as root: sievec and
  sieve-dump now ignore mail_uid and mail_gid settings when run as root.
- Sieve: fixed bug in action accounting (for limit checking): increase
  action instance count only when an action is actually created.
- Sieve: include extension: fixed namespace separation of :global and
  :personal scripts.
- ManageSieve: fixed segfault bug triggered by CHECKSCRIPT command.
- Fixed linking with ld.gold.
- Fixed several Clang compile warnings and a few potential bugs.

The release is available as follows:

http://www.rename-it.nl/dovecot/2.1/dovecot-2.1-pigeonhole-0.3.2.tar.gz
http://www.rename-it.nl/dovecot/2.1/dovecot-2.1-pigeonhole-0.3.2.tar.gz.sig

Refer to http://pigeonhole.dovecot.org and the Dovecot v2.x wiki for 
more information. Have fun testing this new release and don't hesitate 
to notify me when there are any problems.


Regards,

--
Stephan Bosch
step...@rename-it.nl













Re: [Dovecot] trash plugin together with sieve_before ?

2012-09-18 Thread Stephan Bosch

On 9/18/2012 1:38 PM, Jan-Frode Myklebust wrote:

We have a sieve script doing sieve_before to sort spam to
spam-folders. Now I'm trying to configure the "Trash" plugin, but it
doesn't seem to work.. I noticed my config file says:

   # Space separated list of plugins to load (none known to be useful
so far). Do NOT
   # try to load IMAP plugins here.
   #mail_plugins =

and that doveconf doesn't list any plugins loaded for "protocol
sieve". Should we load quota and trash here ?


Keep in mind that the Sieve language and the Sieve protocol are two 
different things. The Sieve language is what processes incoming e-mails; 
for Dovecot it is executed by a plugin for LTMP or LDA during message 
delivery. The Sieve protocol - which is actually called ManageSieve - is 
used to upload Sieve scripts to the Server. That mail_plugins setting 
applies to the Sieve protocol, for which currently no useful plugins are 
known. The Sieve protocol service does not (currently) open any mail 
stores, which makes configuring mail-related plugins for it - such as 
quota and trash - utterly useless.


So, in short, the answer to the above question is no.

To help you further, we need some more information about your 
configuration. First of all, please provide the output of dovecot -n to 
this list. Also, describe more thoroughly what is going wrong. Do you 
see any log messages, etc.


Regards,

Stephan.


[Dovecot] Changing Quota downward for special Mailboxes? (2.1.6)

2012-09-18 Thread Jost Krieger
It seems there is no way to correct te quota limit downward for some
mailboxes, like:

quota_rule9 = UCE-TMP:storage=-10%%

The idea is to not eat up the users storage with spam, so that spam
stays in the queue (for some time) while real mail gets delivered.

There *is* a line

} else if (*value != '-' && relative_rule) {

in quota.c, but nothing else handles it, starting with
quota_rule_parse_percentage.
 
Yours
Jost Krieger
-- 
| jost.krieger+...@ruhr-uni-bochum.de  Please help stamp out spam! |
| Postmaster, JAPH, resident answer machineat RUB Comp. Center |
| Sincere words are not sweet, sweet words are not sincere.|
|  Lao Tse, Tao Te King 81 |


[Dovecot] trash plugin together with sieve_before ?

2012-09-18 Thread Jan-Frode Myklebust
We have a sieve script doing sieve_before to sort spam to
spam-folders. Now I'm trying to configure the "Trash" plugin, but it
doesn't seem to work.. I noticed my config file says:

  # Space separated list of plugins to load (none known to be useful
so far). Do NOT
  # try to load IMAP plugins here.
  #mail_plugins =

and that doveconf doesn't list any plugins loaded for "protocol
sieve". Should we load quota and trash here ?


  -jf


Re: [Dovecot] Shared Mailboxes in a multi domain environment

2012-09-18 Thread Alessio Cecchi

Il 17/09/2012 14:44, Timo Sirainen ha scritto:

So, why don't provide a way to restrict shared mailboxes also for dict in SQL?

One way could be to add to "user_shares" table a column "domains" which is the same 
domain of the mailbox'owner and a config option, for acl, like acl_only_for_same_domain =yes/no so dovecot 
can add a "WHERE %n = domain"  for the SELECT.

If you don't include %d as part of the shared namespace prefix you already 
restrict the users sharing within same domain, no need for extra SQL WHEREs.


Good, after change my shared namespace from

namespace {
  list = children
  location = maildir:%%h/Maildir:INDEX=~/Maildir/shared/%%u
  prefix = shared/%%u/
  separator = /
  subscriptions = no
  type = shared
}


to

namespace {
  list = children
  location = maildir:%%h/Maildir:INDEX=~/Maildir/shared/%%u
  prefix = shared/%%n/  ## <<=- change %u to %n
  separator = /
  subscriptions = no
  type = shared
}

shared mailboxes have become available only inside the same domains.

Thanks!

--
Alessio Cecchi is:
@ ILS -> http://www.linux.it/~alessice/
on LinkedIn -> http://www.linkedin.com/in/alessice
Assistenza Sistemi GNU/Linux -> http://www.cecchi.biz/
@ PLUG -> ex-Presidente, adesso senatore a vita, http://www.prato.linux.it



Re: [Dovecot] Syntax for doveadm auth cache

2012-09-18 Thread Angel L. Mateo

El 11/09/12 16:24, Timo Sirainen escribió:

On 3.9.2012, at 14.16, Angel L. Mateo wrote:


Moreover... according to previous mails (thread 
http://www.dovecot.org/list/dovecot/2012-June/066691.html) there is a patch to 
remove a specific user entry from cache. This patch I think is included in 
dovecot 2.1.9 (which I'm running) and the syntax is (I think):

doveadm auth cache flush 
4 cache entries flushed


Yep.


So I'm running this command. Whenever I run it, I get the message that 
3 (sometimes, is 4) entries are removed, but user information isn't really 
reloaded and I doubt it is really removed from cache (I have the user in a 
passwd-file and information used by imap processes is still the old one, no the 
new one, changed before the flush)


Works in my tests.


Is this cache the same than the user information cache?

	The parameter of the user I want to change is his quota, so I have 
modified quota value in my ldap diretory, then I run:


doveadm auth cache flush 

in the logs I get:

Sep 18 08:47:13 myotis34 dovecot: auth: Debug: master in: 
CACHE-FLUSH#0111#011


now I ask for user information with:

doveadm user 

and this is what I get from logs:

Sep 18 08:47:19 myotis34 dovecot: auth: Debug: master in: 
USER#0111#011#011service=doveadm


Sep 18 08:47:19 myotis34 dovecot: auth: Debug: prefetch(): 
passdb didn't return userdb entries, trying the next userdb


Sep 18 08:47:19 myotis34 dovecot: auth: Debug: userdb-cache(): 
hit: #011home=/home/otros/99/151299#011uid=151299#011gid=405


Sep 18 08:47:19 myotis34 dovecot: auth: Debug: master out: 
USER#0111#011#011home=/home/otros/99/151299#011uid=151299#011gid=405


Sep 18 08:47:41 myotis34 dovecot: auth: Debug: master in: 
USER#0111#011#011service=doveadm


Sep 18 08:47:41 myotis34 dovecot: auth: Debug: prefetch(): 
passdb didn't return userdb entries, trying the next userdb


Sep 18 08:47:41 myotis34 dovecot: auth: Debug: userdb-cache(): 
hit: #011home=/home/otros/99/151299#011uid=151299#011gid=405


Sep 18 08:47:41 myotis34 dovecot: auth: Debug: master out: 
USER#0111#011#011home=/home/otros/99/151299#011uid=151299#011gid=405


	As you can see in the third message, it is still using information from 
userdb cache