Re: [Dovecot] Error: dict: Failed to initialize dictionary 'expire'
On Friday 19 December 2008 20.22.37 LÉVAI Dániel wrote: > Hi! > > Using dovecot-1.1.17, and BDB-4.6.21. > I'm having this error in every two weeks or so. I've running this in > a crontab: > /usr/local/sbin/dovecot --exec-mail \ > ext /usr/local/libexec/dovecot/expire-tool > > The expire plugin and tool is working fine, the configuration is ok, > and I'm using the BDB backend. > What happens in every ~two weeks is dovecot starts to give me this > error messages: > Error: dict: db_env: Unable to allocate memory for transaction detail > Error: dict: Failed to initialize dictionary 'expire' > > Reading thru Oracle's Berkeley DB FAQ: > http://www.oracle.com/technology/products/berkeley-db/faq/db_faq.html >#28 "This error means the maximum number of active transactions > configured for Berkeley DB has been reached [...] When all of the > memory available in the database environment for transactions is in > use, calls to being a transaction will fail until some active > transactions complete. By default, the database environment is > configured to support at least 20 active transactions." >. > What could be happening here? Why coudn't it finish its transactions? > After a dovecot restart it works fine :\ Sorry, I was in a hurry. It won't work even after a dovecot restart. I must delete expire's database directory, which I set with "expire = db:/var/dovecot/expire/expire.db" under the dict {} section. Then after a dovecot restart it works fine (at least for a couple of weeks). -- LEVAI Daniel PGP key ID = 0x4AC0A4B1 Key fingerprint = D037 03B9 C12D D338 4412 2D83 1373 917A 4AC0 A4B1
Re: [Dovecot] Error: dict: Failed to initialize dictionary 'expire'
On Friday 19 December 2008 20.22.37 LÉVAI Dániel wrote: > Hi! > > Using dovecot-1.1.17, and BDB-4.6.21. That is 1.1.7 :) -- LEVAI Daniel PGP key ID = 0x4AC0A4B1 Key fingerprint = D037 03B9 C12D D338 4412 2D83 1373 917A 4AC0 A4B1
[Dovecot] Error: dict: Failed to initialize dictionary 'expire'
Hi! Using dovecot-1.1.17, and BDB-4.6.21. I'm having this error in every two weeks or so. I've running this in a crontab: /usr/local/sbin/dovecot --exec-mail \ ext /usr/local/libexec/dovecot/expire-tool The expire plugin and tool is working fine, the configuration is ok, and I'm using the BDB backend. What happens in every ~two weeks is dovecot starts to give me this error messages: Error: dict: db_env: Unable to allocate memory for transaction detail Error: dict: Failed to initialize dictionary 'expire' Reading thru Oracle's Berkeley DB FAQ: http://www.oracle.com/technology/products/berkeley-db/faq/db_faq.html#28 "This error means the maximum number of active transactions configured for Berkeley DB has been reached [...] When all of the memory available in the database environment for transactions is in use, calls to being a transaction will fail until some active transactions complete. By default, the database environment is configured to support at least 20 active transactions." What could be happening here? Why coudn't it finish its transactions? After a dovecot restart it works fine :\ Thanks in advance for any hints. Daniel -- LEVAI Daniel PGP key ID = 0x4AC0A4B1 Key fingerprint = D037 03B9 C12D D338 4412 2D83 1373 917A 4AC0 A4B1
Re: [Dovecot] Apple patches 6-8
If you start renaming API functions, rename all of them for consistency. :) Agreed, but when changing code on a branch, minimizing code deltas makes merging easier. Your code disabled idle timeout entirely Yeah, probably not a good idea. If I had realized that I probably would have just dropped the connection after N failed auth attempts, and chosen N for when it matched the idle timeout. Your solution of clamping the backoff to just under the idle timeout is fine too. PS -- Today is busy so I'll try to submit the next patches Monday or Tuesday.
[Dovecot] Heartbeat OCF ressource agent
Hello, I've tried to write an OCF ressource agent in order to manage by the heartbeat way a dovecot server. It seems to work fine. This kind of script could be found in the directory on a CentOS release 5.2 : /usr/lib/ocf/resource.d/ If the attachement isn't working, I've cut and paste the script here : http://www-sop.inria.fr/members/Mathieu.Kretchner/dotclear/index.php/2008/12/19/5-heartbeat-dovecot #!/bin/bash -p # # $Id: ha-dovecot,v 1.2 2008/12/19 09:32:27 mkretchn Exp $ #---+ Notes ## Cf: http://linux-ha.org/OCFResourceAgent ## http://www.opencf.org/cgi-bin/viewcvs.cgi/specs/ra/resource-agent-api.txt?rev=HEAD ## /usr/share/heartbeat/crm.dtd #---+ Contexte OCF # Pour execution (status monitor) hors controle de heartbeat if [ -z "$OCF_ROOT" ]; then OCF_ROOT=/usr/lib/ocf fi source ${OCF_ROOT}/resource.d/heartbeat/.ocf-shellfuncs #---+ Actions usage () { echo "Usage: $0 {start|stop|monitor|meta-data|validate-all}" } meta_data () { local rev="$Revision: 1.2 $" rev=${rev#* }; rev=${rev% *} cat < $rev dovecot dovecot RA EOF } exec="/usr/sbin/dovecot" bin=$(basename $exec) config="/etc/dovecot.conf" start () { [ -x $exec ] || { echo >&2 "** $exec not executable" return $OCF_ERR_GENERIC } [ -f $config ] || { echo >&2 "** $config doesn't exist" return $OCF_ERR_GENERIC } local pid=$(dovecot_pid) if [ "$pid" ]; then echo >&2 "dovecot already running" return $OCF_SUCCESS elif $exec; then local pid=$(dovecot_pid) if [ "$pid" ]; then return $OCF_SUCCESS else echo >&2 "** no dovecot pid" return $OCF_ERR_GENERIC fi else echo >&2 "** $bin fails to start" return $OCF_ERR_GENERIC fi } stop () { local pid=$(dovecot_pid) echo $pid if [ "$pid" ]; then if killpid $pid; then return $OCF_SUCCESS else echo >&2 "** killpid $pid: fails" return $OCF_ERR_GENERIC fi else return $OCF_SUCCESS fi } status () { # Seems to not be used by heartbeat return } monitor () { local pid=$(dovecot_pid) if [ "$pid" ]; then MYSTATUS=`echo ". logout" | nc localhost 143 | grep "ready" | wc -l` if [ "$MYSTATUS" -eq "1" ]; then return $OCF_SUCCESS else return $OCF_ERR_GENERIC fi else return $OCF_NOT_RUNNING fi } validate_all () { return } #---+ Utilitaires dovecot_pid () { pidof $bin } # Check if $pid (could be plural) are running checkpid() { local i for i in $* ; do [ -d "/proc/$i" ] && return 0 done return 1 } killpid () { # Repris depuis /etc/init.d/functions:killproc # killpid [] # FIXME: faire faire ca par lps -k ou autre option? local pid=$1 local delay=${2:-3} # Succes si pas de process checkpid $pid || return 0 # TERM first, then KILL if not dead kill -TERM $pid usleep 10 if checkpid $pid && sleep 1 && checkpid $pid && sleep $delay && checkpid $pid ; then kill -KILL $pid usleep 10 fi if checkpid $pid; then return 1 else return 0 fi } #---+ Debug [[ $0 == *bash ]] && return #---+ Main if [ $# -eq 0 ] then usage exit $OCF_ERR_ARGS fi # PATH source /usr/local/bashutil/autoload_lib autoload_lib /usr/local/bashutil/lib/batch case $1 in start)start ;; stop) stop ;; status) status ;; monitor) monitor ;; meta-data)meta_data;; validate-all ) validate_all;; *)usage exit $OCF_ERR_UNIMPLEMENTED ;; esac begin:vcard fn:Mathieu Kretchner n:Kretchner;Mathieu org:INRIA;Syslog adr;dom:;;2004 route des lucioles - BP93;Sophia Antipolis;;06902 CEDEX email;internet:mathieu.kretch...@sophia.inria.fr tel;work:04 92 38 76 67 x-mozilla-html:FALSE version:2.1 end:vcard
Re: [Dovecot] Apple patches 1-5
Summary: On Mon, 2008-12-15 at 11:39 -0600, Mike Abbott wrote: > Here are the first few simple patches from Apple, based on > dovecot-1.1.7. The comments with "APPLE" in them helped us merge in > your new releases; feel free to remove them. Please let me know if > you want subsequent patches in a different format, or if you have any > questions. > > Patch #1. Some versions of Mac OS X have buggy CMSG_* macros. http://hg.dovecot.org/dovecot-1.1/rev/a217d9ae130b > Patch #2. Don't set "=1" in the environment. Waiting for your next patch to see if I should do it this way or some other way. > Patch #3. Some versions of Mac OS X return near-duplicate kevents. http://hg.dovecot.org/dovecot-1.1/rev/d178293dde50 > Patch #4. Null renames are actually pretty slow on HFS (Apple's file > system), so avoid them. http://hg.dovecot.org/dovecot-1.1/rev/92921985e4f5 > Patch #5. Required by Apple's lawyers. http://hg.dovecot.org/dovecot-1.1/rev/859099ac07bb signature.asc Description: This is a digitally signed message part