[Dovecot] now rc24 Re: rc22 segv when over quota

Steffen Kaiser skdovecot at smail.inf.fh-bonn-rhein-sieg.de
Fri Feb 23 08:49:38 UTC 2007


-----BEGIN PGP SIGNED MESSAGE-----
Hash: SHA1

On Fri, 23 Feb 2007, Steffen Kaiser wrote:

When ^C "dovecot -F", there are log messages like:
dovecot: Feb 23 09:04:41 Warning: I/O leak: 0x804d860 (158)
dovecot: Feb 23 09:04:41 Warning: I/O leak: 0x804d860 (152)

====

I just downloaded & compiled rc24.
In the mean time, I also put kernel 2.6.20 on this box.

There is a change in the log:

Note the "Success", previous versions said "Disk quota exceeded". I tested 
with the _same_ (not copies, but physically the same files) mailbox, index 
and control files in rc22, rc23 and rc24.
I also notices a different behaviour, whether the user's hard quota is 
100% full when uploading another mail starts, in opposite when the hard 
quota is reached during the upload, please see the end of the mail.

===

The disk quotas are absolutely utilised, no single block can be allocated 
on the disk with the maildir. (indexes and control files are located 
elsewhere without quota).

dovecot: Feb 23 09:13:29 Error: IMAP(dvtest): 
o_stream_send_istream(/mnt/mailcache/dvtest/MailDir/.test/tmp/1172218409.P19175Q0M237232.ux-2s11-9) 
failed: Success
dovecot: Feb 23 09:13:29 Error: child 19175 (imap) killed with signal 11

Using host libthread_db library "/lib/tls/i686/cmov/libthread_db.so.1".

warning: Can't read pathname for load map: Input/output error.
Core was generated by `imap [dvtest 10.20.10.63]'.
Program terminated with signal 11, Segmentation fault.
#0  mailbox_save_continue (ctx=0x80deb54) at mail-storage.c:530
530             return ctx->transaction->box->v.save_continue(ctx);
#0  mailbox_save_continue (ctx=0x80deb54) at mail-storage.c:530
No locals.
#1  0x080571f3 in client_input (context=0x80deb10) at cmd-append.c:67
         client = (struct client *) 0x0
         cmd = (struct client_command_context *) 0x80e0d68
#2  0x080ba752 in io_loop_handler_run (ioloop=0x80dd9b0) at 
ioloop-poll.c:199
         ctx = (struct ioloop_handler_context *) 0x80dd9d8
         pollfd = <value optimized out>
         tv = {tv_sec = 9, tv_usec = 994346}
         io = (struct io *) 0x80decc8
         t_id = 2
         msecs = <value optimized out>
         ret = 135129872
         call = <value optimized out>
#3  0x080b9a98 in io_loop_run (ioloop=0x80dd9b0) at ioloop.c:284
No locals.
#4  0x08063980 in main (argc=Cannot access memory at address 0x5a8
) at main.c:287
         home = 0x0

=====

/usr/local# ./dovecot.rc24/sbin/dovecot -n
# /usr/local/dovecot.rc24/etc/dovecot.conf
log_path: /var/tmp/dovecot.log
info_log_path: /var/tmp/dovecot.info
ssl_disable: yes
disable_plaintext_auth: no
verbose_ssl: yes
login_dir: /usr/local/dovecot.rc24/var/run/dovecot/login
login_executable: /usr/local/dovecot.rc24/libexec/dovecot/imap-login
verbose_proctitle: yes
mail_location: 
maildir:/mnt/mailcache/%u/MailDir:CONTROL=/var/cache/dovecot/%i/control:INDEX=/var/cache/dovecot/%i/index
mail_debug: yes
mail_drop_priv_before_exec: yes
auth default:
   mechanisms: plain login
   cache_size: 10
   verbose: yes
   debug: yes
   debug_passwords: yes
   passdb:
     driver: pam
     args: cache_key=%u dovecot
   userdb:
     driver: passwd

=====

Summary of configure:
Install prefix ...................... : /usr/local/dovecot.rc24
File offsets ........................ : 64bit
I/O loop method ..................... : poll
File change notification method ..... : dnotify
Building with SSL support ........... : yes (OpenSSL)
Building with IPv6 support .......... : yes
Building with pop3 server ........... : yes
Building with mail delivery agent  .. : yes
Building with GSSAPI support ........ : no
Building with user database modules . : static prefetch passwd passwd-file 
checkpassword ldap sql (modules)
Building with password lookup modules : passwd passwd-file shadow pam 
checkpassword ldap sql (modules)
Building with SQL drivers ............: pgsql

===========

I re-built Dovecot rc24 with no argument other than --prefix:
Install prefix ...................... : /usr/local/dovecot.rc24_plain
File offsets ........................ : 64bit
I/O loop method ..................... : poll
File change notification method ..... : dnotify
Building with SSL support ........... : yes (OpenSSL)
Building with IPv6 support .......... : yes
Building with pop3 server ........... : yes
Building with mail delivery agent  .. : yes
Building with GSSAPI support ........ : no
Building with user database modules . : static prefetch passwd passwd-file 
checkpassword (modules)
Building with password lookup modules : passwd passwd-file shadow pam 
checkpassword (modules)
Building with SQL drivers ............:

The behaviour is the same.

====

Found another thing, I removed one mail, hence, the quota dropped a bit 
below the hard quota:
Disk quotas for user dvtest (uid 1012):
      Filesystem  blocks   quota   limit   grace   files   quota   limit 
grace
                    1021*    600    1024   6days     145       0       0

When I now upload a mail above 4K to the server:

dovecot: Feb 23 09:34:41 Error: IMAP(dvtest): 
o_stream_send_istream(/mnt/mailcache/dvtest/MailDir/.test/tmp/1172219681.P20611Q0M827098.ux-2s11-9) 
failed: Success

Note: The first time, there was NO segv, but just a note about an internal 
server error and that I should refer to the server log.

dovecot: Feb 23 09:35:00 Error: IMAP(dvtest): 
o_stream_send_istream(/mnt/mailcache/dvtest/MailDir/.test/tmp/1172219700.P20612Q0M157711.ux-2s11-9) 
failed: Success
dovecot: Feb 23 09:35:00 Error: child 20612 (imap) killed with signal 11
dovecot: Feb 23 09:35:00 Error: IMAP(dvtest): 
o_stream_send_istream(/mnt/mailcache/dvtest/MailDir/.test/tmp/1172219700.P20611Q1.ux-2s11-9) 
failed: Success
dovecot: Feb 23 09:35:00 Error: child 20611 (imap) killed with signal 11

This is the second try immediately following the first one. I got the box 
about an internal server error on time.

======

Restart Dovecot, the following happens in one session of Dovecot and 
Thunderbird, no manual restarts.

Try to upload a 8KB mail:
dovecot: Feb 23 09:40:13 Error: IMAP(dvtest): 
o_stream_send_istream(/mnt/mailcache/dvtest/MailDir/tmp/1172220013.P20656Q0M441909.ux-2s11-9) 
failed: Success
dovecot: Feb 23 09:40:13 Error: child 20656 (imap) killed with signal 11
dovecot: Feb 23 09:40:13 Error: IMAP(dvtest): 
o_stream_send_istream(/mnt/mailcache/dvtest/MailDir/tmp/1172220013.P20657Q0M493383.ux-2s11-9) 
failed: Success

One box about internal server error.

Try to upload a 4K mail:
dovecot: Feb 23 09:40:41 Error: IMAP(dvtest): 
o_stream_send_istream(/mnt/mailcache/dvtest/MailDir/tmp/1172220041.P20657Q1.ux-2s11-9) 
failed: Success

The box: Internal server error

Try to upload a 2KB mail:
success, no log entry; the quota is now 100% full again.

Try to upload another 2KB mail:
endless:
dovecot: Feb 23 09:43:19 Error: IMAP(dvtest): 
o_stream_send_istream(/mnt/mailcache/dvtest/MailDir/tmp/1172220199.P21072Q0M865499.ux-2s11-9) 
failed: Success
dovecot: Feb 23 09:43:19 Error: child 21072 (imap) killed with signal 11
dovecot: Feb 23 09:43:19 Error: IMAP(dvtest): 
o_stream_send_istream(/mnt/mailcache/dvtest/MailDir/tmp/1172220199.P21073Q0M901234.ux-2s11-9) 
failed: Success
dovecot: Feb 23 09:43:19 Error: child 21073 (imap) killed with signal 11
dovecot: Feb 23 09:43:19 Error: IMAP(dvtest): 
o_stream_send_istream(/mnt/mailcache/dvtest/MailDir/tmp/1172220199.P21074Q0M933467.ux-2s11-9) 
failed: Success
dovecot: Feb 23 09:43:19 Error: child 21074 (imap) killed with signal 11

and re-logins log entries.
Thunderbird re-tries to upload the mail again and again.

Bye,

- -- 
Steffen Kaiser
-----BEGIN PGP SIGNATURE-----
Version: GnuPG v1.4.6 (GNU/Linux)

iQEVAwUBRd6qpC9SORjhbDpvAQIdJgf/TUIqSXjDCMzpjauM6Wer6BBEj3Wxq769
NPvtxvuuMqDSIds106Dk6ixhiqi+2RDmHhtzHyXB2lX1HRw5Tf+XPRiM7TakVC2B
ih+SXt3XfIl1dW5Ja2d04wNHyoUi4yri0dubichw8Plw+6lRC6uFNdx5lm2rwFdk
bf7SxxcpCCmJX03lGTe82bEGKS69PvsMM0gWpsUZfC3SUzSd6ceSlvjB51c6OUnv
xa86ElodFIuUSTHeRQAkKTtomQB410uL48g8Qb23UMSYnWoFKMRpYh6t+ikWHxz4
FJ/ReJgj26SqrZ/NSLftM9imr1ftF1JERvXZj706rOjR2ime4wR7/g==
=kWOS
-----END PGP SIGNATURE-----


More information about the dovecot mailing list