Google Groups no longer supports new Usenet posts or subscriptions. Historical content remains viewable.
Dismiss

amavisd-new panics randomly

208 views
Skip to first unread message

Bánhalmi Csaba via amavis-users

unread,
May 28, 2014, 5:11:35 AM5/28/14
to
Hi all,

I have a FreeBSD 10.0-RELEASE system with postfix+amavisd-new+clamav.
amavisd-new has MySQL backend, spamassassin is not running in daemon
mode. A couple days ago amavisd started to panic randomly, in amavis.log
I see tons of this:

May 23 18:12:34 domain.hu /usr/local/sbin/amavisd[25492]: (!)_DIE: Suicide in child_init_hook: BDB no dbS: Lock table is out of available locker entries, . at (eval 107) line 31.
May 23 18:12:34 domain.hu /usr/local/sbin/amavisd[25494]: (!)_DIE: Suicide in child_init_hook: BDB no dbS: Lock table is out of available locker entries, . at (eval 107) line 31.
May 23 18:12:34 domain.hu /usr/local/sbin/amavisd[25493]: (!)_DIE: Suicide in child_init_hook: BDB no dbS: Lock table is out of available locker entries, . at (eval 107) line 31.
May 23 18:12:34 domain.hu /usr/local/sbin/amavisd[25495]: (!)_DIE: Suicide in child_init_hook: BDB no dbS: Lock table is out of available locker entries, . at (eval 107) line 31.
May 23 18:12:34 domain.hu /usr/local/sbin/amavisd[25496]: (!)_DIE: Suicide in child_init_hook: BDB no dbS: Lock table is out of available locker entries, . at (eval 107) line 31.

When I try to restart the amavisd-new service manually (/usr/local/etc/rc.d/amavisd restart) I see this in log and amavisd-new cannot start:
May 28 06:30:19 cool.prograph.hu /usr/local/sbin/amavisd[8859]: (!)Net::Server: 2014/05/28-06:30:19 Unable to load module for proto "Net::Server::Proto::UNIX": Can't locate Net/Server/Proto/UNIX.pm: Permission denied at
/usr/local/lib/perl5/site_perl/5.18/Net/Server/Proto.pm line 198.\n\n at line 198 in file /usr/local/lib/perl5/site_perl/5.18/Net/Server/Proto.pm

I have to wait 30 minutes or restart the server to start amavisd again. As far as I know BDB is used by amavis in /var/amavis/db:
-rw-r----- 1 vscan vscan 24576 May 28 06:33 __db.001
-rw-r----- 1 vscan vscan 65536 May 28 06:33 __db.002
-rw-r----- 1 vscan vscan 270336 May 28 06:33 __db.003
-rw-r----- 1 vscan vscan 753664 May 28 06:33 __db.004
-rw-r----- 1 vscan vscan 49152 May 28 11:04 nanny.db
-rw-r----- 1 vscan vscan 49152 May 28 11:04 snmp.db

In amavisd.conf I have these regarding the BDB:
$enable_db = 1; # enable use of BerkeleyDB/libdb (SNMP and nanny)
$enable_global_cache = 1; # enable use of libdb-based cache if $enable_db=1
$nanny_details_level = 2; # nanny verbosity: 1: traditional, 2: detailed


Can you give me a hint where should I look, what should I do? Not sure what does it mean "BDB no dbS"

Thank you and Best Regards,
Csaba

Quanah Gibson-Mount via amavis-users

unread,
May 28, 2014, 2:35:17 PM5/28/14
to
--On Wednesday, May 28, 2014 8:47 PM +0200 o...@field.hu wrote:

>
>
> Hi,
>
>
> Can you please tell me what should I write into DB_CONFIG? I couldn't
> find which parameter do I need.

Please keep replies on the list. I know this is hard to do because someone
totally screwed up the list software for the amavis list so it defaults to
replying to the sender rather than the list, but trust me the extra effort
is worth it.

It may depend somewhat on your version of BDB. For BDB 5, we use:

set_lk_max_locks 3000
set_lk_max_objects 1500
set_lk_max_lockers 1500

--Quanah


--

Quanah Gibson-Mount
Server Architect
Zimbra, Inc.
--------------------
Zimbra :: the leader in open source messaging and collaboration

Bánhalmi Csaba via amavis-users

unread,
May 28, 2014, 3:23:59 PM5/28/14
to
You are right, sorry, just replied from phone.
I think it's version 4.7, because I can get the stat with "db_stat-4.7
-c -h /var/amavis/db/" command.
After I create the DB_CONFIG file in /var/amavis/db directory and paste
these lines should I restart something or is it in effect just after I
save the file?

Best regards,
Csaba

2014.05.28. 20:35 keltez�ssel, Quanah Gibson-Mount �rta:

Quanah Gibson-Mount via amavis-users

unread,
May 28, 2014, 3:39:51 PM5/28/14
to
--On Wednesday, May 28, 2014 10:23 PM +0200 Bánhalmi Csaba <o...@field.hu>
wrote:

> You are right, sorry, just replied from phone.
> I think it's version 4.7, because I can get the stat with "db_stat-4.7 -c
> -h /var/amavis/db/" command.
> After I create the DB_CONFIG file in /var/amavis/db directory and paste
> these lines should I restart something or is it in effect just after I
> save the file?

For our 4.7, we have:

# Increase locks
set_lk_max_locks 3000
set_lk_max_objects 1500
set_lk_max_lockers 1500

which looks the same. ;)

I would stop amavis, add it to the directory with the *.bdb files, run the
4.7 db_recover, and then start amavis. That should pull in the new
DB_CONFIG values.

Bánhalmi Csaba via amavis-users

unread,
May 28, 2014, 4:05:14 PM5/28/14
to
It works! Thank you for your help, glad to see that amavisd has this
kind of user support :)
/var/amavis/db]# db_stat-4.7 -c -h /var/amavis/db/
33 Last allocated locker ID
0x7fffffff Current maximum unused locker ID
5 Number of lock modes
3000 Maximum number of locks possible
3000 Maximum number of lockers possible
3000 Maximum number of lock objects possible
0 new messages