1

Topic: iredapd dict errors

==== REQUIRED BASIC INFO OF YOUR IREDMAIL SERVER ====
- iRedMail version (check /etc/iredmail-release):  1.1
- Deployed with iRedMail Easy or the downloadable installer? download
- Linux/BSD distribution name and version: RHEL6.10
- Store mail accounts in which backend (LDAP/MySQL/PGSQL): PGSQL (postgresql 8.4)
- Web server (Apache or Nginx): Apache
- Manage mail accounts with iRedAdmin-Pro? Yes
- [IMPORTANT] Related original log or error message is required if you're experiencing an issue.
====
iredapd Error while getting list of id of external addresses: TypeError("'dict' object does not support indexing",), SQL: SELECT id, email#012               FROM mailaddr#012              WHERE email IN ('@.', '{%fromname%}630@*', '92.101.230.222', '92.101.230.*', '92.101.*.222')#012           ORDER BY priority DESC

iredapd <!> Error while logging smtp action: TypeError("'dict' object does not support indexing",)

Thanks.

2

Re: iredapd dict errors

- RHEL 6, PostgreSQL 8.4, both are quite old. sad
- Which iRedAPD release are you running? You can get the version number with command "ls -dl /opt/iredapd".
- Which Python version are you running? Run "python -V" to get the version number.

----

Does my reply help a little? How about buying me a cup of coffee ($5) as an encouragement?

buy me a cup of coffee

3

Re: iredapd dict errors

The plan is to move to RHEL8.

iRedAPD-3.5
Python 2.6.6

4

Re: iredapd dict errors

The error log is not very clear, could you please turn on debug mode and trigger same error again, then extract full debug log of the error?
FYI: https://docs.iredmail.org/debug.iredapd.html

----

Does my reply help a little? How about buying me a cup of coffee ($5) as an encouragement?

buy me a cup of coffee

5

Re: iredapd dict errors

Mar 10 11:47:22 package iredapd [176.209.70.114] END-OF-MESSAGE, {%fromname%}346@me.com -> rathbun@cnf.cornell.edu, DUNNO [recipient
_count=1, size=4978, process_time=0.0025s]

Mar 10 11:47:22 package iredapd [SQL] Insert into smtp_sessions: #012        INSERT INTO smtp_sessions (#012            time, time_n
um,#012            action, reason, instance,#012            client_address, client_name, reverse_client_name, helo_name,#012       
    encryption_protocol, encryption_cipher,#012            server_address, server_port,#012            sender, sender_domain,#012   
         sasl_username, sasl_domain,#012            recipient, recipient_domain)#012        VALUES (#012            '2020-03-10 15:4
7:22', 1583855242,#012            'DUNNO', '', '74ba.5e67b683.78dc6.0',#012            '176.209.70.114', 'unknown', 'unknown', 'me.c
om',#012            '', '',#012            '', '',#012            '{%fromname%}346@me.com', 'me.com',#012            '', '',#012   
        'rathbun@cnf.cornell.edu', 'cnf.cornell.edu')#012   

Mar 10 11:47:22 package iredapd <!> Error while logging smtp action: TypeError("'dict' object does not support indexing",)

6

Re: iredapd dict errors

Mar 10 11:47:19 package iredapd [SQL] query local domain (cnf.cornell.edu): #012SELECT domain#012                   FROM domain#012
                 WHERE domain='cnf.cornell.edu' AND active=1 #012                  LIMIT 1
Mar 10 11:47:19 package iredapd SQL query result: ('cnf.cornell.edu',)
Mar 10 11:47:19 package iredapd Apply wblist for inbound message.

Mar 10 11:47:19 package iredapd [SQL] Query local addresses: #012SELECT id, email#012               FROM users#012              WHER
E email IN ('rathbun@cnf.cornell.edu', '@cnf.cornell.edu', '@.', '@.cnf.cornell.edu', '@.cornell.edu', '@.edu')#012           ORDER
BY priority DESC

Mar 10 11:47:19 package iredapd Local addresses (in `users`): [(1, <read-only buffer for 0x2268190, size 2, offset 0 at 0x225ea70>)]

Mar 10 11:47:19 package iredapd [SQL] Query external addresses: #012SELECT id, email#012               FROM mailaddr#012           
  WHERE email IN ('@.', '{%fromname%}346@*', '176.209.70.114', '176.209.70.*', '176.209.*.114')#012           ORDER BY priority DESC

Mar 10 11:47:19 package iredapd Error while getting list of id of external addresses: TypeError("'dict' object does not support inde
xing",), SQL: SELECT id, email#012               FROM mailaddr#012              WHERE email IN ('@.', '{%fromname%}346@*', '176.209.
70.114', '176.209.70.*', '176.209.*.114')#012           ORDER BY priority DESC

Mar 10 11:47:19 package iredapd [SQL] Query CIDR network: #012SELECT id, email#012               FROM mailaddr#012              WHER
E email LIKE '176.%%'#012           ORDER BY priority DESC

Mar 10 11:47:19 package iredapd No valid sender id or recipient id.
Mar 10 11:47:19 package iredapd <-- Result: DUNNO

7

Re: iredapd dict errors

- Which iRedAPD release are you running? You can get it with command "ls -dl /opt/iredapd".
- Which version of Python module "SQLAlchemy" are you running? Get it with command below:

python2 -c "import sqlalchemy; print sqlalchemy.__version__"

Did you upgrade any packages manually (without yum)?

----

Does my reply help a little? How about buying me a cup of coffee ($5) as an encouragement?

buy me a cup of coffee

8

Re: iredapd dict errors

ZhangHuangbin wrote:

- Which iRedAPD release are you running? You can get it with command "ls -dl /opt/iredapd".
- Which version of Python module "SQLAlchemy" are you running? Get it with command below:

python2 -c "import sqlalchemy; print sqlalchemy.__version__"

Did you upgrade any packages manually (without yum)?

No. All package upgrades to python things are via yum.

$ python2 -c "import sqlalchemy; print sqlalchemy.__version__"
0.5.5
rpm -qa | grep -i python |grep sql
python-sqlalchemy-0.5.5-3.el6_2.noarch
python-zope-sqlalchemy-0.4-3.el6.noarch

rpm -q python-sqlalchemy-0.5.5-3.el6_2.noarch -i
...
Vendor: Red Hat, Inc.
...

9

Re: iredapd dict errors

I tried the latest iRedAPD-3.5 on a CentOS 6 server, but i didn't get this error.
Did you modify /opt/iredapd/plugins/amavisd_wblist.py?

----

Does my reply help a little? How about buying me a cup of coffee ($5) as an encouragement?

buy me a cup of coffee