Hi. I've been having some strange issues with dbmail-timsieved(3.1.17) lately:
every now and then I get errors like this in the log: Sep 24 18:02:57 lordvan.com dbmail-timsieved[26837]: [0x190aa00] Error:[server] _sock_cb(+582): 24:Too many open files and several thousand of that per second. obviously that fills up my /var/log which then causes things to crash. I've been having a look at the logs & open files and noticed this: for some reason i get a lot of connections which then result in "broken pipe": Sep 29 07:38:04 lordvan.com dbmail-timsieved[22749]: [0xb4ce00] Notice:[server] server_run(+775): starting main service loop for [SIEVE] Sep 29 07:38:04 lordvan.com dbmail-timsieved[22749]: [0xb4ce00] Info:[server] server_set_sighandler(+693): signal handler placed Sep 29 07:38:04 lordvan.com dbmail-timsieved[22749]: [0xb4ce00] Debug:[server] dm_bind_and_listen(+403): creating plain socket [12] on [0.0.0.0:2000] Sep 29 07:38:04 lordvan.com dbmail-timsieved[22749]: [0xb4ce00] Debug:[server] server_run(+813): Adding event for plain socket [12] [1/1] Sep 29 07:38:04 lordvan.com dbmail-timsieved[22749]: [0xb4ce00] Debug:[server] server_run(+840): dispatching event loop... Sep 29 07:39:05 lordvan.com dbmail-timsieved[22749]: [0xb4ce00] Info:[server] _sock_cb(+626): connection accepted Sep 29 07:39:05 lordvan.com dbmail-timsieved[22749]: [0xb4ce00] Notice:[clientbase] client_init(+184): incoming connection on [127.0.0.1:2000] from [127.0.0.1:53686] Sep 29 07:39:05 lordvan.com dbmail-timsieved[22749]: [0xb4ce00] Debug:[misc] create_unique_id(+125): created: 221ac121020da73abe25612dc6045134 Sep 29 07:39:05 lordvan.com dbmail-timsieved[22749]: [0xb4ce00] Debug:[clientbase] ci_cork(+205): [0x7f47eba47010] Sep 29 07:39:05 lordvan.com dbmail-timsieved[22749]: [0xb4ce00] Debug:[clientbase] ci_write(+343): [0x7f47eba47010] S > [43/43:"IMPLEMENTATION" "DBMail timsieved 0.9.] Sep 29 07:39:05 lordvan.com dbmail-timsieved[22749]: [0xb4ce00] Debug:[clientbase] client_error_cb(+127): [0x7f47eba47010] fd [14] Broken pipe[32], 0x7f47eba47010 Sep 29 07:39:05 lordvan.com dbmail-timsieved[22749]: [0xb4ce00] Debug:[clientbase] ci_uncork(+212): [0x7f47eba47010] Sep 29 07:39:05 lordvan.com dbmail-timsieved[22749]: [0xb4ce00] Debug:[server] server_sig_cb(+651): fd 13, event 8, Broken pipe Sep 29 07:40:05 lordvan.com dbmail-timsieved[22749]: [0xb4ce00] Info:[server] _sock_cb(+626): connection accepted Sep 29 07:40:05 lordvan.com dbmail-timsieved[22749]: [0xb4ce00] Notice:[clientbase] client_init(+184): incoming connection on [127.0.0.1:2000] from [127.0.0.1:53695] Sep 29 07:40:05 lordvan.com dbmail-timsieved[22749]: [0xb4ce00] Debug:[misc] create_unique_id(+125): created: bdca0cd5314b84f941c7ea1bd1b23bb3 Sep 29 07:40:05 lordvan.com dbmail-timsieved[22749]: [0xb4ce00] Debug:[clientbase] ci_cork(+205): [0x7f47eba06010] Sep 29 07:40:05 lordvan.com dbmail-timsieved[22749]: [0xb4ce00] Debug:[clientbase] ci_write(+343): [0x7f47eba06010] S > .... this continues for quite a while (while I am not sure what/who is connecting all the time I am sure of one thing: dbmail-timsieved seems not to close that socket again since the number of open sockets gets steadily increased (by 2) after every connection event - also the fd handles mentioned here in the log from client_error_cb are socket handle numbers. Unfortunately I don't have the time to dig into the code more right now, but this seems like a file-handle leak (if you can call it that) Do you have any idea why this would happen / how to fix this? Also my first idea how to tackle this issue with the logs getting huge was to use syslog instead, so I went to set the config like this file_logging_levels = 0 syslog_logging_levels = 31 now I don't know why but I am not getting a single line of logging from dbmail to my syslog-ng and can'T figure out why. Just to be sure I looked at some of the code and then wrote a little test program: #include <stdio.h> #include <syslog.h> int main (int argc, char **argv) { openlog("syslogtest", LOG_PID, LOG_MAIL); syslog(LOG_ERR, "Syslog test level ERR"); syslog(LOG_WARNING, "Syslog test level WARNING"); syslog(LOG_NOTICE, "Syslog test level NOTICE"); syslog(LOG_INFO, "Syslog test level INFO"); return 0; } this does log to my syslog just fine so I am at a loss why I don't get dbmail logging to syslog. any ideas? Regards _______________________________________________ DBmail mailing list DBmail@dbmail.org http://mailman.fastxs.nl/cgi-bin/mailman/listinfo/dbmail