Corrupted Aliases.db (Was: bug creating new lists)
Definitely, the problem seems related with a corrupted aliases db.
Looking at the archives I've found a thread on past August about the same problem and gave a try to the trick used by R.Pilas: using 'postalias hash:/mailman/data/aliases' to build the db. I'm then able to send messages. But... I can't create or delete lists (!). At each attempt I get the following errors, both related to Postfix.py and dbhash.py:
mailer:/usr/local/mailman# bin/newlist test5 me@ieev.uma.es xxxxx Traceback (most recent call last): File "bin/newlist", line 188, in ? main() File "bin/newlist", line 163, in main sys.modules[modname].create(mlist) File "/usr/local/mailman/Mailman/MTA/Postfix.py", line 122, in create db = dbhash.open(DBFILE, 'c') File "/usr/local/lib/python2.2/dbhash.py", line 16, in open return bsddb.hashopen(file, flag, mode) bsddb.error: (22, 'Argumento invalido')
mailer:/usr/local/mailman# bin/rmlist -a test3 Traceback (most recent call last): File "bin/rmlist", line 120, in ? main() File "bin/rmlist", line 100, in main sys.modules[modname].remove(mlist) File "/usr/local/mailman/Mailman/MTA/Postfix.py", line 157, in remove db = dbhash.open(DBFILE, 'c') File "/usr/local/lib/python2.2/dbhash.py", line 16, in open return bsddb.hashopen(file, flag, mode) bsddb.error: (22, 'Argumento invalido')
On the other side, following the steps on Readme.Postfix, genaliases seems to build a db unreadable by Postfix. I deleted aliases.db and rebuilt it with genaliases. I've been then able to create new lists and delete them, but Postfix is unable to read aliases.db and complaints with 'warning: mail_scan_any: got EOF; expected: string' and 'warning: private/local: malformed response'. Then, to send/receive mail I have to comment the call to the mailman alias in postfix/main.cf
Any ideas?
JA.
"JA" == J Accino <jaccino@ieev.uma.es> writes:
JA> Definitely, the problem seems related with a corrupted aliases
JA> db.
Actually, I'll bet its an incompatibility between the bsddb libraries used by Python and those used by Postfix. We need to figure out which version the two programs are using. The only way I can think of to do this is to use ldd to see which dynamic library the two of them are linked against, e.g.
% ldd /usr/local/bin/postfix libdb.so.3 => /lib/libdb.so.3 (0x40018000) libnsl.so.1 => /lib/libnsl.so.1 (0x40053000) libresolv.so.2 => /lib/libresolv.so.2 (0x40069000) libc.so.6 => /lib/libc.so.6 (0x40078000) /lib/ld-linux.so.2 => /lib/ld-linux.so.2 (0x40000000) % ldd /usr/local/lib/python2.1/lib-dynload/bsddb.so libdb.so.3 => /lib/libdb.so.3 (0x40009000) libc.so.6 => /lib/libc.so.6 (0x40044000) /lib/ld-linux.so.2 => /lib/ld-linux.so.2 (0x80000000)
So in my case both are linked against libdb.so.3.
What do yours say?
If they differ, read this page for hints on how to get Python to use the same bsddb module as Postfix:
http://python.sourceforge.net/devel-docs/lib/module-bsddb.html
anticipating-a-faq-entry-ly y'rs, -Barry
Actually, I'll bet its an incompatibility between the bsddb libraries used by Python and those used by Postfix.
Yes, python 2.2 is using libdb.so.2, while postfix uses libdb.so.3
# ldd /usr/local/lib/python2.2/lib-dynload/bsddb.so libdb.so.2 => /lib/libdb.so.2 (0x40007000) libc.so.6 => /lib/libc.so.6 (0x40016000) /lib/ld-linux.so.2 => /lib/ld-linux.so.2 (0x80000000)
# ldd /usr/sbin/postfix libdb.so.3 => /lib/libdb.so.3 (0x40016000) libnsl.so.1 => /lib/libnsl.so.1 (0x40052000) libresolv.so.2 => /lib/libresolv.so.2 (0x40068000) libc.so.6 => /lib/libc.so.6 (0x40077000) /lib/ld-linux.so.2 => /lib/ld-linux.so.2 (0x40000000)
However, previous Python was also using libdb.so.3
# ldd /usr/local/lib/python2.1/lib-dynload/bsddb.so libdb.so.3 => /lib/libdb.so.3 (0x40007000) libc.so.6 => /lib/libc.so.6 (0x40043000) /lib/ld-linux.so.2 => /lib/ld-linux.so.2 (0x80000000)
I think I'll get the email package and return back to Python 2.1. Any advantage on going into Python 2.2 (besides the email lib)?
JA.
participants (3)
-
barry@zope.com
-
J.Accino
-
Jose A. Accino