1 (edited by rain6966 2019-06-18 15:03:52)

Topic: 更新 iRedAPD-2.9 後 , 出現 Warning: Incorrect integer value

==== REQUIRED BASIC INFO OF YOUR IREDMAIL SERVER ====
- iRedMail version (check /etc/iredmail-release): 0.9.9
- Deployed with iRedMail Easy or the downloadable installer? download install
- Linux/BSD distribution name and version:  CentOS 7
- Store mail accounts in which backend (LDAP/MySQL/PGSQL): LDAP
- Web server (Apache or Nginx):Nginx
- Manage mail accounts with iRedAdmin-Pro? 3.7
- [IMPORTANT] Related original log or error message is required if you're experiencing an issue.
====

Hi 版主:
更新 iRedAPD-2.9 後出現如下訊息:
messages:
Jun 14 13:25:32 mail python2: /usr/lib64/python2.7/site-packages/sqlalchemy/engine/default.py:436: Warning: Incorrect integer value: 'cur_msgs + 1' for column 'cur_msgs' at row 1
Jun 14 13:25:32 mail python2: /usr/lib64/python2.7/site-packages/sqlalchemy/engine/default.py:436: Warning: Incorrect integer value: 'cur_quota + 5838' for column 'cur_quota' at row 1
Jun 14 14:39:43 mail python2: /usr/lib64/python2.7/site-packages/sqlalchemy/engine/default.py:436: Warning: Incorrect integer value: 'cur_quota + 6034' for column 'cur_quota' at row 1

改為 iRedAPD-2.8 則不會.

感謝.

----

Spider Email Archiver: On-Premises, lightweight email archiving software developed by iRedMail team. Supports Amazon S3 compatible storage and custom branding.

2

Re: 更新 iRedAPD-2.9 後 , 出現 Warning: Incorrect integer value

Hi 版主:

gmail to mydomain 會有異常log

mydomain to gmail

a@mydomain.com  to  b@mydomain.com
這兩種情況則沒有 異常log

3

Re: 更新 iRedAPD-2.9 後 , 出現 Warning: Incorrect integer value

rain6966 wrote:

Jun 14 13:25:32 mail python2: /usr/lib64/python2.7/site-packages/sqlalchemy/engine/default.py:436: Warning: Incorrect integer value: 'cur_msgs + 1' for column 'cur_msgs' at row 1

可否帮个忙:打开 iredapd 的 debug 模式,然后再次触发这个错误,将 iredapd log file 里和这个测试邮件相关的完整 log 都贴到这里。

4

Re: 更新 iRedAPD-2.9 後 , 出現 Warning: Incorrect integer value

Hi 版主:
我修正一下:

內部 test@mydomain.com to b@mydomain.com 是正常

test@mydomain To rain@gmail.com 或 rain@gmail.com To test@mydomain.com 是會有異常訊息.

iRedAPD log:
a).test@mydomain to rain@gmail.com  (內到外)
Jun 19 09:46:50 mail journal: iredapd DEBUG: [srs][recipient] input: get test@mydomain.com
Jun 19 09:46:50 mail journal: iredapd DEBUG: [srs][recipient] 500 Not a valid SRS address, bypassed.
Jun 19 09:46:50 mail journal: iredapd DEBUG: [srs][recipient] input: get rain@gmail.com
Jun 19 09:46:50 mail journal: iredapd DEBUG: [srs][recipient] 500 Not a valid SRS address, bypassed.
Jun 19 09:46:50 mail journal: iredapd DEBUG: [policy] request=smtpd_access_policy
Jun 19 09:46:50 mail journal: iredapd DEBUG: [policy] protocol_state=RCPT
Jun 19 09:46:50 mail journal: iredapd DEBUG: [policy] protocol_name=ESMTP
Jun 19 09:46:50 mail journal: iredapd DEBUG: [policy] client_address=xxx.xxx.xxx.xxx
Jun 19 09:46:50 mail journal: iredapd DEBUG: [policy] client_name=xxx-xxx-xxx-xxx.HINET-IP.hinet.net
Jun 19 09:46:50 mail journal: iredapd DEBUG: [policy] reverse_client_name=xxx-xxx-xxx-xxx.HINET-IP.hinet.net
Jun 19 09:46:50 mail journal: iredapd DEBUG: [policy] helo_name=[192.168.xxx.xxx]
Jun 19 09:46:50 mail journal: iredapd DEBUG: [policy] sender=test@mydomain.com
Jun 19 09:46:50 mail journal: iredapd DEBUG: [policy] recipient=rain@gmail.com
Jun 19 09:46:50 mail journal: iredapd DEBUG: [policy] recipient_count=0
Jun 19 09:46:50 mail journal: iredapd DEBUG: [policy] queue_id=
Jun 19 09:46:50 mail journal: iredapd DEBUG: [policy] instance=53a6.5d09940a.c6857.0
Jun 19 09:46:50 mail journal: iredapd DEBUG: [policy] size=475
Jun 19 09:46:50 mail journal: iredapd DEBUG: [policy] etrn_domain=
Jun 19 09:46:50 mail journal: iredapd DEBUG: [policy] stress=
Jun 19 09:46:50 mail journal: iredapd DEBUG: [policy] sasl_method=PLAIN
Jun 19 09:46:50 mail journal: iredapd DEBUG: [policy] sasl_username=test@mydomain.com
Jun 19 09:46:50 mail journal: iredapd DEBUG: [policy] sasl_sender=
Jun 19 09:46:50 mail journal: iredapd DEBUG: [policy] ccert_subject=
Jun 19 09:46:50 mail journal: iredapd DEBUG: [policy] ccert_issuer=
Jun 19 09:46:50 mail journal: iredapd DEBUG: [policy] ccert_fingerprint=
Jun 19 09:46:50 mail journal: iredapd DEBUG: [policy] ccert_pubkey_fingerprint=
Jun 19 09:46:50 mail journal: iredapd DEBUG: [policy] encryption_protocol=TLSv1.2
Jun 19 09:46:50 mail journal: iredapd DEBUG: [policy] encryption_cipher=ECDHE-RSA-AES128-GCM-SHA256
Jun 19 09:46:50 mail journal: iredapd DEBUG: [policy] encryption_keysize=128
Jun 19 09:46:50 mail journal: iredapd DEBUG: --> Apply plugin: reject_null_sender
Jun 19 09:46:50 mail journal: iredapd DEBUG: <-- Result: DUNNO
Jun 19 09:46:50 mail journal: iredapd DEBUG: --> Apply plugin: wblist_rdns
Jun 19 09:46:50 mail journal: iredapd DEBUG: Found SASL username, bypass rDNS check for outbound.
Jun 19 09:46:50 mail journal: iredapd DEBUG: <-- Result: DUNNO
Jun 19 09:46:50 mail journal: iredapd DEBUG: --> Apply plugin: reject_sender_login_mismatch
Jun 19 09:46:50 mail journal: iredapd DEBUG: Sender: test@mydomain.com, SASL username: test@mydomain.com
Jun 19 09:46:50 mail journal: iredapd DEBUG: SKIP: sender == sasl username.
Jun 19 09:46:50 mail journal: iredapd DEBUG: <-- Result: DUNNO
Jun 19 09:46:50 mail journal: iredapd DEBUG: --> Apply plugin: greylisting
Jun 19 09:46:50 mail journal: iredapd DEBUG: Found SASL username, bypass greylisting for outbound email.
Jun 19 09:46:50 mail journal: iredapd DEBUG: <-- Result: DUNNO
Jun 19 09:46:50 mail journal: iredapd DEBUG: --> Apply plugin: throttle
Jun 19 09:46:50 mail journal: iredapd DEBUG: Found sasl_username, consider this sender as an internal sender.
Jun 19 09:46:50 mail journal: iredapd DEBUG: Check sender throttling.
Jun 19 09:46:50 mail journal: iredapd DEBUG: [LDAP] query target domain of given alias domain (mydomain.com).
Jun 19 09:46:50 mail journal: iredapd DEBUG: [LDAP] query filter: ((&(objectClass=mailDomain)(accountStatus=active)(domainAliasName=mydomain.com)))
Jun 19 09:46:50 mail journal: iredapd DEBUG: result: []
Jun 19 09:46:50 mail journal: iredapd DEBUG: [SQL] Query throttle setting: #012        SELECT id, account, priority, period, max_msgs, max_quota, msg_size#012          FROM throttle#012         WHERE kind='outbound' AND account IN ('xxx.xxx.xxx.xxx', '@ip', 'test@mydomain.com', '@mydomain.com', '@.', '@.mydomain.com', '@.com', 'xxx.xxx.xxx.*', 'xxx.xxx.*.xxx')#012         ORDER BY priority DESC
Jun 19 09:46:50 mail journal: iredapd DEBUG: [SQL] Query result: [(4L, '@mydomain.com', 5, 86400L, 150L, -1L, 100000000L)]
Jun 19 09:46:50 mail journal: iredapd DEBUG: sender throttle setting: msg_size=100000000 (bytes)/id=4/account=@mydomain.com; max_msgs=150/id=4/account=@mydomain.com;
Jun 19 09:46:50 mail journal: iredapd DEBUG: [SQL] Query throttle tracking data: SELECT id, tid, account, cur_msgs, cur_quota, init_time, last_time, last_notify_time#012               FROM throttle_tracking#012              WHERE (tid=4 AND account='test@mydomain.com') OR (tid=4 AND account='xxx.xxx.xxx.xxx')
Jun 19 09:46:50 mail journal: iredapd DEBUG: [SQL] Query result: [(213L, 4L, 'test@mydomain.com', 0, 0L, 1560845767L, 1560908641L, 0L)]
Jun 19 09:46:50 mail journal: iredapd DEBUG: Tracking IDs: {(4L, 'test@mydomain.com'): 213L}
Jun 19 09:46:50 mail journal: iredapd INFO: [xxx.xxx.xxx.xxx] sender throttle, test@mydomain.com -> max_msgs (0/150, period: 86400 seconds, time left: 6 hours, 32 minutes, 6 seconds)
Jun 19 09:46:50 mail journal: iredapd DEBUG: [OK] Passed all sender throttle settings.
Jun 19 09:46:50 mail journal: iredapd DEBUG: Bypass recipient throttling (found sasl_username).
Jun 19 09:46:50 mail journal: iredapd DEBUG: <-- Result: DUNNO
Jun 19 09:46:50 mail journal: iredapd DEBUG: [+] Getting LDIF data of account: rain@gmail.com
Jun 19 09:46:50 mail journal: iredapd DEBUG: search base dn: o=domains,dc=mydomain,dc=com
Jun 19 09:46:50 mail journal: iredapd DEBUG: search scope: SUBTREE
Jun 19 09:46:50 mail journal: iredapd DEBUG: search filter: (&(!(domainStatus=disabled))(|(mail=rain@gmail.com)(shadowAddress=rain@gmail.com))(|(objectClass=mailUser)(objectClass=mailList)(objectClass=mailAlias)))
Jun 19 09:46:50 mail journal: iredapd DEBUG: search attributes: ['objectClass', 'accountStatus', 'listAllowedUser', 'accessPolicy', 'enabledService']
Jun 19 09:46:50 mail journal: iredapd DEBUG: No such account.
Jun 19 09:46:50 mail journal: iredapd DEBUG: --> Apply plugin: ldap_maillist_access_policy
Jun 19 09:46:50 mail journal: iredapd DEBUG: <-- Result: DUNNO (Recipient is not a local account - no LDIF data)
Jun 19 09:46:50 mail journal: iredapd DEBUG: --> Apply plugin: amavisd_wblist
Jun 19 09:46:50 mail journal: iredapd DEBUG: [LDAP] query target domain of given alias domain (mydomain.com).
Jun 19 09:46:50 mail journal: iredapd DEBUG: [LDAP] query filter: ((&(objectClass=mailDomain)(accountStatus=active)(domainAliasName=mydomain.com)))
Jun 19 09:46:50 mail journal: iredapd DEBUG: result: []
Jun 19 09:46:50 mail journal: iredapd DEBUG: [LDAP] query target domain of given alias domain (gmail.com).
Jun 19 09:46:50 mail journal: iredapd DEBUG: [LDAP] query filter: ((&(objectClass=mailDomain)(accountStatus=active)(domainAliasName=gmail.com)))
Jun 19 09:46:50 mail journal: iredapd DEBUG: result: []
Jun 19 09:46:50 mail journal: iredapd DEBUG: Possible policy senders: ['test@mydomain.com', '@mydomain.com', '@.', '@.mydomain.com', '@.com', 'xxx.xxx.xxx.xxx', 'xxx.xxx.xxx.*', 'xxx.xxx.*.xxx']
Jun 19 09:46:50 mail journal: iredapd DEBUG: Possible policy recipients: ['rain@gmail.com', '@gmail.com', '@.', '@.gmail.com', '@.com']
Jun 19 09:46:50 mail journal: iredapd DEBUG: Apply wblist for outbound message.
Jun 19 09:46:50 mail journal: iredapd DEBUG: [SQL] Query local addresses: #012SELECT id, email#012               FROM users#012              WHERE email IN ('test@mydomain.com', '@mydomain.com', '@.', '@.mydomain.com', '@.com', 'xxx.xxx.xxx.xxx', 'xxx.xxx.xxx.*', 'xxx.xxx.*.xxx')#012           ORDER BY priority DESC
Jun 19 09:46:50 mail journal: iredapd DEBUG: Local addresses (in `users`): [(3L, '@mydomain.com'), (1L, '@.')]
Jun 19 09:46:50 mail journal: iredapd DEBUG: [SQL] Query external addresses: #012SELECT id, email#012               FROM mailaddr#012              WHERE email IN ('rain@gmail.com', '@gmail.com', '@.', '@.gmail.com', '@.com')#012           ORDER BY priority DESC
Jun 19 09:46:50 mail journal: iredapd DEBUG: No record found in SQL database.
Jun 19 09:46:50 mail journal: iredapd DEBUG: [SQL] Query CIDR network: #012SELECT id, email#012               FROM mailaddr#012              WHERE email LIKE 'xxx.%%'#012           ORDER BY priority DESC
Jun 19 09:46:50 mail journal: iredapd DEBUG: No valid sender id or recipient id.
Jun 19 09:46:50 mail journal: iredapd DEBUG: <-- Result: DUNNO
Jun 19 09:46:50 mail journal: iredapd DEBUG: Session ended.
Jun 19 09:46:50 mail journal: iredapd INFO: [xxx.xxx.xxx.xxx] RCPT, test@mydomain.com => rain@gmail.com, DUNNO [sasl_username=test@mydomain.com, sender=test@mydomain.com, client_name=xxx-xxx-xxx-xxx.HINET-IP.hinet.net, reverse_client_name=xxx-xxx-xxx-xxx.hinet-ip.hinet.net, helo=[192.168.xxx.xxx], encryption_protocol=TLSv1.2, process_time=0.0163s]
Jun 19 09:46:50 mail journal: iredapd DEBUG: [srs][sender] input: get test@mydomain.com
Jun 19 09:46:50 mail journal: iredapd DEBUG: [srs][sender] 500 Domain is a local mail domain, bypassed.
Jun 19 09:46:50 mail journal: iredapd DEBUG: [srs][recipient] input: get rain@gmail.com
Jun 19 09:46:50 mail journal: iredapd DEBUG: [srs][recipient] 500 Not a valid SRS address, bypassed.
Jun 19 09:46:50 mail journal: iredapd DEBUG: [policy] request=smtpd_access_policy
Jun 19 09:46:50 mail journal: iredapd DEBUG: [policy] protocol_state=END-OF-MESSAGE
Jun 19 09:46:50 mail journal: iredapd DEBUG: [policy] protocol_name=ESMTP
Jun 19 09:46:50 mail journal: iredapd DEBUG: [policy] client_address=xxx.xxx.xxx.xxx
Jun 19 09:46:50 mail journal: iredapd DEBUG: [policy] client_name=xxx-xxx-xxx-xxx.HINET-IP.hinet.net
Jun 19 09:46:50 mail journal: iredapd DEBUG: [policy] reverse_client_name=xxx-xxx-xxx-xxx.HINET-IP.hinet.net
Jun 19 09:46:50 mail journal: iredapd DEBUG: [policy] helo_name=[192.168.xxx.xxx]
Jun 19 09:46:50 mail journal: iredapd DEBUG: [policy] sender=test@mydomain.com
Jun 19 09:46:50 mail journal: iredapd DEBUG: [policy] recipient=rain@gmail.com
Jun 19 09:46:50 mail journal: iredapd DEBUG: [policy] recipient_count=1
Jun 19 09:46:50 mail journal: iredapd DEBUG: [policy] queue_id=45T79664b8zBsThrG
Jun 19 09:46:50 mail journal: iredapd DEBUG: [policy] instance=53axxx.5d09940a.c6857.0
Jun 19 09:46:50 mail journal: iredapd DEBUG: [policy] size=475
Jun 19 09:46:50 mail journal: iredapd DEBUG: [policy] etrn_domain=
Jun 19 09:46:50 mail journal: iredapd DEBUG: [policy] stress=
Jun 19 09:46:50 mail journal: iredapd DEBUG: [policy] sasl_method=PLAIN
Jun 19 09:46:50 mail journal: iredapd DEBUG: [policy] sasl_username=test@mydomain.com
Jun 19 09:46:50 mail journal: iredapd DEBUG: [policy] sasl_sender=
Jun 19 09:46:50 mail journal: iredapd DEBUG: [policy] ccert_subject=
Jun 19 09:46:50 mail journal: iredapd DEBUG: [policy] ccert_issuer=
Jun 19 09:46:50 mail journal: iredapd DEBUG: [policy] ccert_fingerprint=
Jun 19 09:46:50 mail journal: iredapd DEBUG: [policy] ccert_pubkey_fingerprint=
Jun 19 09:46:50 mail journal: iredapd DEBUG: [policy] encryption_protocol=TLSv1.2
Jun 19 09:46:50 mail journal: iredapd DEBUG: [policy] encryption_cipher=ECDHE-RSA-AES128-GCM-SHA256
Jun 19 09:46:50 mail journal: iredapd DEBUG: [policy] encryption_keysize=128
Jun 19 09:46:50 mail journal: iredapd DEBUG: Skip plugin: reject_null_sender (protocol_state != END-OF-MESSAGE)
Jun 19 09:46:50 mail journal: iredapd DEBUG: Skip plugin: wblist_rdns (protocol_state != END-OF-MESSAGE)
Jun 19 09:46:50 mail journal: iredapd DEBUG: Skip plugin: reject_sender_login_mismatch (protocol_state != END-OF-MESSAGE)
Jun 19 09:46:50 mail journal: iredapd DEBUG: Skip plugin: greylisting (protocol_state != END-OF-MESSAGE)
Jun 19 09:46:50 mail journal: iredapd DEBUG: --> Apply plugin: throttle
Jun 19 09:46:50 mail journal: iredapd DEBUG: Found sasl_username, consider this sender as an internal sender.
Jun 19 09:46:50 mail journal: iredapd DEBUG: Check sender throttling.
Jun 19 09:46:50 mail journal: iredapd DEBUG: [LDAP] query target domain of given alias domain (mydomain.com).
Jun 19 09:46:50 mail journal: iredapd DEBUG: [LDAP] query filter: ((&(objectClass=mailDomain)(accountStatus=active)(domainAliasName=mydomain.com)))
Jun 19 09:46:50 mail journal: iredapd DEBUG: result: []
Jun 19 09:46:50 mail journal: iredapd DEBUG: [SQL] Query throttle setting: #012        SELECT id, account, priority, period, max_msgs, max_quota, msg_size#012          FROM throttle#012         WHERE kind='outbound' AND account IN ('xxx.xxx.xxx.xxx', '@ip', 'test@mydomain.com', '@mydomain.com', '@.', '@.mydomain.com', '@.com', 'xxx.xxx.xxx.*', 'xxx.xxx.*.xxx')#012         ORDER BY priority DESC
Jun 19 09:46:50 mail journal: iredapd DEBUG: [SQL] Query result: [(4L, '@mydomain.com', 5, 86400L, 150L, -1L, 100000000L)]
Jun 19 09:46:50 mail journal: iredapd DEBUG: sender throttle setting: msg_size=100000000 (bytes)/id=4/account=@mydomain.com; max_msgs=150/id=4/account=@mydomain.com;
Jun 19 09:46:50 mail journal: iredapd DEBUG: [SQL] Query throttle tracking data: SELECT id, tid, account, cur_msgs, cur_quota, init_time, last_time, last_notify_time#012               FROM throttle_tracking#012              WHERE (tid=4 AND account='test@mydomain.com') OR (tid=4 AND account='xxx.xxx.xxx.xxx')
Jun 19 09:46:50 mail journal: iredapd DEBUG: [SQL] Query result: [(213L, 4L, 'test@mydomain.com', 0, 0L, 1560845767L, 1560908641L, 0L)]
Jun 19 09:46:50 mail journal: iredapd DEBUG: Tracking IDs: {(4L, 'test@mydomain.com'): 213L}
Jun 19 09:46:50 mail journal: iredapd INFO: [xxx.xxx.xxx.xxx] sender throttle, test@mydomain.com -> msg_size (475/100000000, period: 86400 seconds, time left: 6 hours, 32 minutes, 6 seconds)
Jun 19 09:46:50 mail journal: iredapd DEBUG: [SQL] Update tracking record: UPDATE throttle_tracking#012                              SET period=:period,#012                                  last_time=:last_time,#012                                  init_time=:init_time,#012                                  cur_msgs=:cur_msgs,#012                                  cur_quota=:cur_quota#012                            WHERE id=:id
Jun 19 09:46:50 mail journal: iredapd DEBUG: [OK] Passed all sender throttle settings.
Jun 19 09:46:50 mail journal: iredapd DEBUG: Bypass recipient throttling (found sasl_username).
Jun 19 09:46:50 mail journal: iredapd DEBUG: <-- Result: DUNNO
Jun 19 09:46:50 mail journal: iredapd DEBUG: Skip plugin: ldap_maillist_access_policy (protocol_state != END-OF-MESSAGE)
Jun 19 09:46:50 mail journal: iredapd DEBUG: Skip plugin: amavisd_wblist (protocol_state != END-OF-MESSAGE)
Jun 19 09:46:50 mail journal: iredapd DEBUG: Session ended.
Jun 19 09:46:50 mail journal: iredapd INFO: [xxx.xxx.xxx.xxx] END-OF-MESSAGE, test@mydomain.com => rain@gmail.com, DUNNO [recipient_count=1, size=475, process_time=0.0495s]


b).rain@gmail.com To test@mydomain.com (外到內)

Jun 19 09:48:16 mail journal: iredapd DEBUG: [srs][recipient] input: get rain@gmail.com
Jun 19 09:48:16 mail journal: iredapd DEBUG: [srs][recipient] 500 Not a valid SRS address, bypassed.
Jun 19 09:48:16 mail journal: iredapd DEBUG: [srs][recipient] input: get test@mydomain.com
Jun 19 09:48:16 mail journal: iredapd DEBUG: [srs][recipient] 500 Not a valid SRS address, bypassed.
Jun 19 09:48:16 mail journal: iredapd DEBUG: [policy] request=smtpd_access_policy
Jun 19 09:48:16 mail journal: iredapd DEBUG: [policy] protocol_state=RCPT
Jun 19 09:48:16 mail journal: iredapd DEBUG: [policy] protocol_name=ESMTP
Jun 19 09:48:16 mail journal: iredapd DEBUG: [policy] client_address=209.85.214.180
Jun 19 09:48:16 mail journal: iredapd DEBUG: [policy] client_name=mail-pl1-f180.google.com
Jun 19 09:48:16 mail journal: iredapd DEBUG: [policy] reverse_client_name=mail-pl1-f180.google.com
Jun 19 09:48:16 mail journal: iredapd DEBUG: [policy] helo_name=mail-pl1-f180.google.com
Jun 19 09:48:16 mail journal: iredapd DEBUG: [policy] sender=rain@gmail.com
Jun 19 09:48:16 mail journal: iredapd DEBUG: [policy] recipient=test@mydomain.com
Jun 19 09:48:16 mail journal: iredapd DEBUG: [policy] recipient_count=0
Jun 19 09:48:16 mail journal: iredapd DEBUG: [policy] queue_id=
Jun 19 09:48:16 mail journal: iredapd DEBUG: [policy] instance=53ed.5d099460.c9a7f.0
Jun 19 09:48:16 mail journal: iredapd DEBUG: [policy] size=2661
Jun 19 09:48:16 mail journal: iredapd DEBUG: [policy] etrn_domain=
Jun 19 09:48:16 mail journal: iredapd DEBUG: [policy] stress=
Jun 19 09:48:16 mail journal: iredapd DEBUG: [policy] sasl_method=
Jun 19 09:48:16 mail journal: iredapd DEBUG: [policy] sasl_username=
Jun 19 09:48:16 mail journal: iredapd DEBUG: [policy] sasl_sender=
Jun 19 09:48:16 mail journal: iredapd DEBUG: [policy] ccert_subject=
Jun 19 09:48:16 mail journal: iredapd DEBUG: [policy] ccert_issuer=
Jun 19 09:48:16 mail journal: iredapd DEBUG: [policy] ccert_fingerprint=
Jun 19 09:48:16 mail journal: iredapd DEBUG: [policy] ccert_pubkey_fingerprint=
Jun 19 09:48:16 mail journal: iredapd DEBUG: [policy] encryption_protocol=TLSv1.2
Jun 19 09:48:16 mail journal: iredapd DEBUG: [policy] encryption_cipher=ECDHE-RSA-AES128-GCM-SHA256
Jun 19 09:48:16 mail journal: iredapd DEBUG: [policy] encryption_keysize=128
Jun 19 09:48:16 mail journal: iredapd DEBUG: --> Apply plugin: reject_null_sender
Jun 19 09:48:16 mail journal: iredapd DEBUG: <-- Result: DUNNO
Jun 19 09:48:16 mail journal: iredapd DEBUG: --> Apply plugin: wblist_rdns
Jun 19 09:48:16 mail journal: iredapd DEBUG: All policy rDNS names: ['mail-pl1-f180.google.com', '.mail-pl1-f180.google.com', '.google.com', '.com']
Jun 19 09:48:16 mail journal: iredapd DEBUG: [SQL] Query whitelisted rDNS names: #012SELECT rdns#012               FROM wblist_rdns#012              WHERE rdns IN ('mail-pl1-f180.google.com', '.mail-pl1-f180.google.com', '.google.com', '.com') AND wb='W'#012              LIMIT 1
Jun 19 09:48:16 mail journal: iredapd DEBUG: [SQL] Query blacklisted rDNS names: #012SELECT rdns#012               FROM wblist_rdns#012              WHERE rdns IN ('mail-pl1-f180.google.com', '.mail-pl1-f180.google.com', '.google.com', '.com') AND wb='B'#012              LIMIT 1
Jun 19 09:48:16 mail journal: iredapd DEBUG: <-- Result: DUNNO
Jun 19 09:48:16 mail journal: iredapd DEBUG: --> Apply plugin: reject_sender_login_mismatch
Jun 19 09:48:16 mail journal: iredapd DEBUG: Not an authenticated sender (no sasl_username).
Jun 19 09:48:16 mail journal: iredapd DEBUG: Sender domain is NOT hosted locally.
Jun 19 09:48:16 mail journal: iredapd DEBUG: <-- Result: DUNNO
Jun 19 09:48:16 mail journal: iredapd DEBUG: --> Apply plugin: greylisting
Jun 19 09:48:16 mail journal: iredapd DEBUG: [SQL] Query greylisting whitelists from `greylisting_whitelist_domain_spf`: #012SELECT sender#012                   FROM greylisting_whitelist_domain_spf#012                  WHERE account IN ('test@mydomain.com', '@mydomain.com', '@.', '@.mydomain.com', '@.com')
Jun 19 09:48:16 mail journal: iredapd DEBUG: [SQL] Query greylisting whitelists from `greylisting_whitelists`: #012SELECT sender#012                   FROM greylisting_whitelists#012                  WHERE account IN ('test@mydomain.com', '@mydomain.com', '@.', '@.mydomain.com', '@.com')
Jun 19 09:48:16 mail journal: iredapd DEBUG: [209.85.214.180] Client is not explictly whitelisted.
Jun 19 09:48:16 mail journal: iredapd INFO: [209.85.214.180] Client network is whitelisted: cidr=209.85.128.0/17
Jun 19 09:48:16 mail journal: iredapd DEBUG: <-- Result: DUNNO
Jun 19 09:48:16 mail journal: iredapd DEBUG: --> Apply plugin: throttle
Jun 19 09:48:16 mail journal: iredapd DEBUG: Check sender throttling.
Jun 19 09:48:16 mail journal: iredapd DEBUG: [LDAP] query target domain of given alias domain (gmail.com).
Jun 19 09:48:16 mail journal: iredapd DEBUG: [LDAP] query filter: ((&(objectClass=mailDomain)(accountStatus=active)(domainAliasName=gmail.com)))
Jun 19 09:48:16 mail journal: iredapd DEBUG: result: []
Jun 19 09:48:16 mail journal: iredapd DEBUG: [SQL] Query throttle setting: #012        SELECT id, account, priority, period, max_msgs, max_quota, msg_size#012          FROM throttle#012         WHERE kind='external' AND account IN ('209.85.214.180', '@ip', 'rain@gmail.com', '@gmail.com', '@.', '@.gmail.com', '@.com', '209.85.214.*', '209.85.*.180')#012         ORDER BY priority DESC
Jun 19 09:48:16 mail journal: iredapd DEBUG: [SQL] Query result: []
Jun 19 09:48:16 mail journal: iredapd DEBUG: No sender throttle setting.
Jun 19 09:48:16 mail journal: iredapd DEBUG: Check recipient throttling.
Jun 19 09:48:16 mail journal: iredapd DEBUG: [LDAP] query target domain of given alias domain (mydomain.com).
Jun 19 09:48:16 mail journal: iredapd DEBUG: [LDAP] query filter: ((&(objectClass=mailDomain)(accountStatus=active)(domainAliasName=mydomain.com)))
Jun 19 09:48:16 mail journal: iredapd DEBUG: result: []
Jun 19 09:48:16 mail journal: iredapd DEBUG: [SQL] Query throttle setting: #012        SELECT id, account, priority, period, max_msgs, max_quota, msg_size#012          FROM throttle#012         WHERE kind='inbound' AND account IN ('209.85.214.180', '@ip', 'test@mydomain.com', '@mydomain.com', '@.', '@.mydomain.com', '@.com', '209.85.214.*', '209.85.*.180')#012         ORDER BY priority DESC
Jun 19 09:48:16 mail journal: iredapd DEBUG: [SQL] Query result: [(3L, '@mydomain.com', 5, 86400L, 150L, -1L, 100000000L)]
Jun 19 09:48:16 mail journal: iredapd DEBUG: recipient throttle setting: msg_size=100000000 (bytes)/id=3/account=@mydomain.com; max_msgs=150/id=3/account=@mydomain.com;
Jun 19 09:48:16 mail journal: iredapd DEBUG: [SQL] Query throttle tracking data: SELECT id, tid, account, cur_msgs, cur_quota, init_time, last_time, last_notify_time#012               FROM throttle_tracking#012              WHERE (tid=3 AND account='test@mydomain.com') OR (tid=3 AND account='209.85.214.180')
Jun 19 09:48:16 mail journal: iredapd DEBUG: [SQL] Query result: [(212L, 3L, 'test@mydomain.com', 0, 0L, 1560904282L, 1560907571L, 0L)]
Jun 19 09:48:16 mail journal: iredapd DEBUG: Tracking IDs: {(3L, 'test@mydomain.com'): 212L}
Jun 19 09:48:16 mail journal: iredapd INFO: [209.85.214.180] recipient throttle, test@mydomain.com -> max_msgs (0/150, period: 86400 seconds, time left: 23 hours, 5 minutes, 11 seconds)
Jun 19 09:48:16 mail journal: iredapd DEBUG: [OK] Passed all recipient throttle settings.
Jun 19 09:48:16 mail journal: iredapd DEBUG: <-- Result: DUNNO
Jun 19 09:48:16 mail journal: iredapd DEBUG: [+] Getting LDIF data of account: test@mydomain.com
Jun 19 09:48:16 mail journal: iredapd DEBUG: search base dn: o=domains,dc=mydomain,dc=com
Jun 19 09:48:16 mail journal: iredapd DEBUG: search scope: SUBTREE
Jun 19 09:48:16 mail journal: iredapd DEBUG: search filter: (&(!(domainStatus=disabled))(|(mail=test@mydomain.com)(shadowAddress=test@mydomain.com))(|(objectClass=mailUser)(objectClass=mailList)(objectClass=mailAlias)))
Jun 19 09:48:16 mail journal: iredapd DEBUG: search attributes: ['objectClass', 'accountStatus', 'listAllowedUser', 'accessPolicy', 'enabledService']
Jun 19 09:48:16 mail journal: iredapd DEBUG: result: [('mail=test@mydomain.com,ou=Users,domainName=mydomain.com,o=domains,dc=mydomain,dc=com', {'objectClass': ['inetOrgPerson', 'mailUser', 'shadowAccount', 'amavisAccount'], 'enabledService': ['managesievetls', 'managesieve', 'imaptls', 'displayedInGlobalAddressBook', 'sievetls', 'smtp', 'lda', 'smtpsecured', 'pop3', 'forward', 'deliver', 'lmtp', 'lib-storage', 'sieve', 'imap', 'dsync', 'smtptls', 'sogo', 'imapsecured', 'pop3tls', 'pop3secured', 'internal', 'doveadm', 'managesievesecured', 'mail', 'indexer-worker', 'sievesecured'], 'accountStatus': ['active']})]
Jun 19 09:48:16 mail journal: iredapd DEBUG: --> Apply plugin: ldap_maillist_access_policy
Jun 19 09:48:16 mail journal: iredapd DEBUG: <-- Result: DUNNO (Recipient is not a mailing list account)
Jun 19 09:48:16 mail journal: iredapd DEBUG: --> Apply plugin: amavisd_wblist
Jun 19 09:48:16 mail journal: iredapd DEBUG: [LDAP] query target domain of given alias domain (gmail.com).
Jun 19 09:48:16 mail journal: iredapd DEBUG: [LDAP] query filter: ((&(objectClass=mailDomain)(accountStatus=active)(domainAliasName=gmail.com)))
Jun 19 09:48:16 mail journal: iredapd DEBUG: result: []
Jun 19 09:48:16 mail journal: iredapd DEBUG: [LDAP] query target domain of given alias domain (mydomain.com).
Jun 19 09:48:16 mail journal: iredapd DEBUG: [LDAP] query filter: ((&(objectClass=mailDomain)(accountStatus=active)(domainAliasName=mydomain.com)))
Jun 19 09:48:16 mail journal: iredapd DEBUG: result: []
Jun 19 09:48:16 mail journal: iredapd DEBUG: Possible policy senders: ['rain@gmail.com', '@gmail.com', '@.', '@.gmail.com', '@.com', 'rain@*', '209.85.214.180', '209.85.214.*', '209.85.*.180']
Jun 19 09:48:16 mail journal: iredapd DEBUG: Possible policy recipients: ['test@mydomain.com', '@mydomain.com', '@.', '@.mydomain.com', '@.com']
Jun 19 09:48:16 mail journal: iredapd DEBUG: Apply wblist for inbound message.
Jun 19 09:48:16 mail journal: iredapd DEBUG: [SQL] Query local addresses: #012SELECT id, email#012               FROM users#012              WHERE email IN ('test@mydomain.com', '@mydomain.com', '@.', '@.mydomain.com', '@.com')#012           ORDER BY priority DESC
Jun 19 09:48:16 mail journal: iredapd DEBUG: Local addresses (in `users`): [(3L, '@mydomain.com'), (1L, '@.')]
Jun 19 09:48:16 mail journal: iredapd DEBUG: [SQL] Query external addresses: #012SELECT id, email#012               FROM mailaddr#012              WHERE email IN ('rain@gmail.com', '@gmail.com', '@.', '@.gmail.com', '@.com', 'rain@*', '209.85.214.180', '209.85.214.*', '209.85.*.180')#012           ORDER BY priority DESC
Jun 19 09:48:16 mail journal: iredapd DEBUG: No record found in SQL database.
Jun 19 09:48:16 mail journal: iredapd DEBUG: [SQL] Query CIDR network: #012SELECT id, email#012               FROM mailaddr#012              WHERE email LIKE '209.%%'#012           ORDER BY priority DESC
Jun 19 09:48:16 mail journal: iredapd DEBUG: No valid sender id or recipient id.
Jun 19 09:48:16 mail journal: iredapd DEBUG: <-- Result: DUNNO
Jun 19 09:48:16 mail journal: iredapd DEBUG: Session ended.
Jun 19 09:48:16 mail journal: iredapd INFO: [209.85.214.180] RCPT, rain@gmail.com -> test@mydomain.com, DUNNO [sasl_username=, sender=rain@gmail.com, client_name=mail-pl1-f180.google.com, reverse_client_name=mail-pl1-f180.google.com, helo=mail-pl1-f180.google.com, encryption_protocol=TLSv1.2, process_time=0.0316s]
Jun 19 09:48:18 mail journal: iredapd DEBUG: [srs][sender] input: get rain@gmail.com
Jun 19 09:48:18 mail journal: iredapd DEBUG: [srs][sender] [SQL] Query srs_exclude_domains: SELECT id FROM srs_exclude_domains WHERE domain IN ('gmail.com', '.gmail.com', 'com', '.com') LIMIT 1
Jun 19 09:48:18 mail journal: iredapd DEBUG: [srs][sender] [SQL] Query result: None
Jun 19 09:48:18 mail journal: iredapd INFO: [srs][sender] rewrited: rain@gmail.com -> SRS0=Rj1L=US=gmail.com=rain@mail.mydomain.com
Jun 19 09:48:18 mail journal: iredapd DEBUG: [srs][sender] 200 SRS0=Rj1L=US=gmail.com=rain@mail.mydomain.com
Jun 19 09:48:18 mail journal: iredapd DEBUG: [srs][sender] input: get SRS0=Rj1L=US=gmail.com=rain@mail.mydomain.com
Jun 19 09:48:18 mail journal: iredapd DEBUG: [srs][sender] 500 Domain is srs_domain, bypassed.
Jun 19 09:48:18 mail journal: iredapd DEBUG: [srs][recipient] input: get test@mydomain.com
Jun 19 09:48:18 mail journal: iredapd DEBUG: [srs][recipient] 500 Not a valid SRS address, bypassed.
Jun 19 09:48:19 mail journal: iredapd DEBUG: [policy] request=smtpd_access_policy
Jun 19 09:48:19 mail journal: iredapd DEBUG: [policy] protocol_state=END-OF-MESSAGE
Jun 19 09:48:19 mail journal: iredapd DEBUG: [policy] protocol_name=ESMTP
Jun 19 09:48:19 mail journal: iredapd DEBUG: [policy] client_address=209.85.214.180
Jun 19 09:48:19 mail journal: iredapd DEBUG: [policy] client_name=mail-pl1-f180.google.com
Jun 19 09:48:19 mail journal: iredapd DEBUG: [policy] reverse_client_name=mail-pl1-f180.google.com
Jun 19 09:48:19 mail journal: iredapd DEBUG: [policy] helo_name=mail-pl1-f180.google.com
Jun 19 09:48:19 mail journal: iredapd DEBUG: [policy] sender=rain@gmail.com
Jun 19 09:48:19 mail journal: iredapd DEBUG: [policy] recipient=test@mydomain.com
Jun 19 09:48:19 mail journal: iredapd DEBUG: [policy] recipient_count=1
Jun 19 09:48:19 mail journal: iredapd DEBUG: [policy] queue_id=45T7Bp69SwzBsThrG
Jun 19 09:48:19 mail journal: iredapd DEBUG: [policy] instance=53ed.5d099460.c9a7f.0
Jun 19 09:48:19 mail journal: iredapd DEBUG: [policy] size=2661
Jun 19 09:48:19 mail journal: iredapd DEBUG: [policy] etrn_domain=
Jun 19 09:48:19 mail journal: iredapd DEBUG: [policy] stress=
Jun 19 09:48:19 mail journal: iredapd DEBUG: [policy] sasl_method=
Jun 19 09:48:19 mail journal: iredapd DEBUG: [policy] sasl_username=
Jun 19 09:48:19 mail journal: iredapd DEBUG: [policy] sasl_sender=
Jun 19 09:48:19 mail journal: iredapd DEBUG: [policy] ccert_subject=
Jun 19 09:48:19 mail journal: iredapd DEBUG: [policy] ccert_issuer=
Jun 19 09:48:19 mail journal: iredapd DEBUG: [policy] ccert_fingerprint=
Jun 19 09:48:19 mail journal: iredapd DEBUG: [policy] ccert_pubkey_fingerprint=
Jun 19 09:48:19 mail journal: iredapd DEBUG: [policy] encryption_protocol=TLSv1.2
Jun 19 09:48:19 mail journal: iredapd DEBUG: [policy] encryption_cipher=ECDHE-RSA-AES128-GCM-SHA256
Jun 19 09:48:19 mail journal: iredapd DEBUG: [policy] encryption_keysize=128
Jun 19 09:48:19 mail journal: iredapd DEBUG: Skip plugin: reject_null_sender (protocol_state != END-OF-MESSAGE)
Jun 19 09:48:19 mail journal: iredapd DEBUG: Skip plugin: wblist_rdns (protocol_state != END-OF-MESSAGE)
Jun 19 09:48:19 mail journal: iredapd DEBUG: Skip plugin: reject_sender_login_mismatch (protocol_state != END-OF-MESSAGE)
Jun 19 09:48:19 mail journal: iredapd DEBUG: Skip plugin: greylisting (protocol_state != END-OF-MESSAGE)
Jun 19 09:48:19 mail journal: iredapd DEBUG: --> Apply plugin: throttle
Jun 19 09:48:19 mail journal: iredapd DEBUG: Check sender throttling.
Jun 19 09:48:19 mail journal: iredapd DEBUG: [LDAP] query target domain of given alias domain (gmail.com).
Jun 19 09:48:19 mail journal: iredapd DEBUG: [LDAP] query filter: ((&(objectClass=mailDomain)(accountStatus=active)(domainAliasName=gmail.com)))
Jun 19 09:48:19 mail journal: iredapd DEBUG: result: []
Jun 19 09:48:19 mail journal: iredapd DEBUG: [SQL] Query throttle setting: #012        SELECT id, account, priority, period, max_msgs, max_quota, msg_size#012          FROM throttle#012         WHERE kind='external' AND account IN ('209.85.214.180', '@ip', 'rain@gmail.com', '@gmail.com', '@.', '@.gmail.com', '@.com', '209.85.214.*', '209.85.*.180')#012         ORDER BY priority DESC
Jun 19 09:48:19 mail journal: iredapd DEBUG: [SQL] Query result: []
Jun 19 09:48:19 mail journal: iredapd DEBUG: No sender throttle setting.
Jun 19 09:48:19 mail journal: iredapd DEBUG: Check recipient throttling.
Jun 19 09:48:19 mail journal: iredapd DEBUG: [LDAP] query target domain of given alias domain (mydomain.com).
Jun 19 09:48:19 mail journal: iredapd DEBUG: [LDAP] query filter: ((&(objectClass=mailDomain)(accountStatus=active)(domainAliasName=mydomain.com)))
Jun 19 09:48:19 mail journal: iredapd DEBUG: result: []
Jun 19 09:48:19 mail journal: iredapd DEBUG: [SQL] Query throttle setting: #012        SELECT id, account, priority, period, max_msgs, max_quota, msg_size#012          FROM throttle#012         WHERE kind='inbound' AND account IN ('209.85.214.180', '@ip', 'test@mydomain.com', '@mydomain.com', '@.', '@.mydomain.com', '@.com', '209.85.214.*', '209.85.*.180')#012         ORDER BY priority DESC
Jun 19 09:48:19 mail journal: iredapd DEBUG: [SQL] Query result: [(3L, '@mydomain.com', 5, 86400L, 150L, -1L, 100000000L)]
Jun 19 09:48:19 mail journal: iredapd DEBUG: recipient throttle setting: msg_size=100000000 (bytes)/id=3/account=@mydomain.com; max_msgs=150/id=3/account=@mydomain.com;
Jun 19 09:48:19 mail journal: iredapd DEBUG: [SQL] Query throttle tracking data: SELECT id, tid, account, cur_msgs, cur_quota, init_time, last_time, last_notify_time#012               FROM throttle_tracking#012              WHERE (tid=3 AND account='test@mydomain.com') OR (tid=3 AND account='209.85.214.180')
Jun 19 09:48:19 mail journal: iredapd DEBUG: [SQL] Query result: [(212L, 3L, 'test@mydomain.com', 0, 0L, 1560904282L, 1560907571L, 0L)]
Jun 19 09:48:19 mail journal: iredapd DEBUG: Tracking IDs: {(3L, 'test@mydomain.com'): 212L}
Jun 19 09:48:19 mail journal: iredapd INFO: [209.85.214.180] recipient throttle, test@mydomain.com -> msg_size (2661/100000000, period: 86400 seconds, time left: 23 hours, 5 minutes, 11 seconds)
Jun 19 09:48:19 mail journal: iredapd DEBUG: [SQL] Update tracking record: UPDATE throttle_tracking#012                              SET period=:period,#012                                  last_time=:last_time,#012                                  init_time=:init_time,#012                                  cur_msgs=:cur_msgs,#012                                  cur_quota=:cur_quota#012                            WHERE id=:id
Jun 19 09:48:19 mail journal: iredapd DEBUG: [OK] Passed all recipient throttle settings.
Jun 19 09:48:19 mail journal: iredapd DEBUG: <-- Result: DUNNO
Jun 19 09:48:19 mail journal: iredapd DEBUG: Skip plugin: ldap_maillist_access_policy (protocol_state != END-OF-MESSAGE)
Jun 19 09:48:19 mail journal: iredapd DEBUG: Skip plugin: amavisd_wblist (protocol_state != END-OF-MESSAGE)
Jun 19 09:48:19 mail journal: iredapd DEBUG: Session ended.
Jun 19 09:48:19 mail journal: iredapd INFO: [209.85.214.180] END-OF-MESSAGE, rain@gmail.com -> test@mydomain.com, DUNNO [recipient_count=1, size=2661, process_time=0.0284s]

5

Re: 更新 iRedAPD-2.9 後 , 出現 Warning: Incorrect integer value

这个问题今早在另外一个客户的服务器上也重现了。请尝试这个 patch:

diff -r 446d426e02be plugins/throttle.py
--- a/plugins/throttle.py    Thu Jun 13 16:19:29 2019 +0800
+++ b/plugins/throttle.py    Wed Jun 19 13:31:14 2019 +0800
@@ -160,7 +160,7 @@
 import time
 from sqlalchemy.sql import text
 from libs.logger import logger
-from web import sqlquote
+from web import sqlquote, sqlliteral
 import settings
 from libs import SMTP_ACTIONS, utils
 
@@ -633,7 +633,7 @@
                         sql_updates[tracking_id]['cur_quota'] = now
                     else:
                         sql_updates[tracking_id]['init_time'] = v['init_time']
-                        sql_updates[tracking_id]['cur_msgs'] = 'cur_msgs + %d' % recipient_count
+                        sql_updates[tracking_id]['cur_msgs'] = sqlliteral('cur_msgs + %d' % recipient_count)
                         sql_updates[tracking_id]['cur_quota'] = 'cur_quota + %d' % size
 
                 else:

6 (edited by rain6966 2019-06-19 14:52:03)

Re: 更新 iRedAPD-2.9 後 , 出現 Warning: Incorrect integer value

Hi 版主:
感謝回復.

上了 patch 後, 還是一樣如下錯誤: (我把Server 重開機)
6997:Jun 19 14:42:44 mail python2: /usr/lib64/python2.7/site-packages/sqlalchemy/engine/default.py:436: Warning: Incorrect integer value: 'cur_msgs + 1' for column 'cur_msgs' at row 1
6998-Jun 19 14:42:44 mail python2: cursor.execute(statement, parameters)
6999:Jun 19 14:42:44 mail python2: /usr/lib64/python2.7/site-packages/sqlalchemy/engine/default.py:436: Warning: Incorrect integer value: 'cur_quota + 9521' for column 'cur_quota' at row 1
7000-Jun 19 14:42:44 mail python2: cursor.execute(statement, parameters)


把這行也改了:  sql_updates[tracking_id]['cur_quota'] = sqlliteral('cur_quota + %d' % size) 也一樣

7

Re: 更新 iRedAPD-2.9 後 , 出現 Warning: Incorrect integer value

请启用 debug 模式,然后重新发一封测试邮件触发这个错误,再将 debug log 贴上来。
FYI: https://docs.iredmail.org/debug.iredapd.html

8

Re: 更新 iRedAPD-2.9 後 , 出現 Warning: Incorrect integer value

Hi 版主:

  a).rain@gmail.com To test@mydomain.com (外到內)
iRedAPD 的log:

Jun 19 15:40:49 mail journal: iredapd DEBUG: [srs][recipient] input: get rain@gmail.com
Jun 19 15:40:49 mail journal: iredapd DEBUG: [srs][recipient] 500 Not a valid SRS address, bypassed.
Jun 19 15:40:49 mail journal: iredapd DEBUG: [srs][recipient] input: get test@mydoamin.com
Jun 19 15:40:49 mail journal: iredapd DEBUG: [srs][recipient] 500 Not a valid SRS address, bypassed.
Jun 19 15:40:49 mail journal: iredapd DEBUG: [policy] request=smtpd_access_policy
Jun 19 15:40:49 mail journal: iredapd DEBUG: [policy] protocol_state=RCPT
Jun 19 15:40:49 mail journal: iredapd DEBUG: [policy] protocol_name=ESMTP
Jun 19 15:40:49 mail journal: iredapd DEBUG: [policy] client_address=209.85.210.176
Jun 19 15:40:49 mail journal: iredapd DEBUG: [policy] client_name=mail-pf1-f176.google.com
Jun 19 15:40:49 mail journal: iredapd DEBUG: [policy] reverse_client_name=mail-pf1-f176.google.com
Jun 19 15:40:49 mail journal: iredapd DEBUG: [policy] helo_name=mail-pf1-f176.google.com
Jun 19 15:40:49 mail journal: iredapd DEBUG: [policy] sender=rain@gmail.com
Jun 19 15:40:49 mail journal: iredapd DEBUG: [policy] recipient=test@mydoamin.com
Jun 19 15:40:49 mail journal: iredapd DEBUG: [policy] recipient_count=0
Jun 19 15:40:49 mail journal: iredapd DEBUG: [policy] queue_id=
Jun 19 15:40:49 mail journal: iredapd DEBUG: [policy] instance=5012.5d09e701.993b5.0
Jun 19 15:40:49 mail journal: iredapd DEBUG: [policy] size=2661
Jun 19 15:40:49 mail journal: iredapd DEBUG: [policy] etrn_domain=
Jun 19 15:40:49 mail journal: iredapd DEBUG: [policy] stress=
Jun 19 15:40:49 mail journal: iredapd DEBUG: [policy] sasl_method=
Jun 19 15:40:49 mail journal: iredapd DEBUG: [policy] sasl_username=
Jun 19 15:40:49 mail journal: iredapd DEBUG: [policy] sasl_sender=
Jun 19 15:40:49 mail journal: iredapd DEBUG: [policy] ccert_subject=
Jun 19 15:40:49 mail journal: iredapd DEBUG: [policy] ccert_issuer=
Jun 19 15:40:49 mail journal: iredapd DEBUG: [policy] ccert_fingerprint=
Jun 19 15:40:49 mail journal: iredapd DEBUG: [policy] ccert_pubkey_fingerprint=
Jun 19 15:40:49 mail journal: iredapd DEBUG: [policy] encryption_protocol=TLSv1.2
Jun 19 15:40:49 mail journal: iredapd DEBUG: [policy] encryption_cipher=ECDHE-RSA-AES128-GCM-SHA256
Jun 19 15:40:49 mail journal: iredapd DEBUG: [policy] encryption_keysize=128
Jun 19 15:40:49 mail journal: iredapd DEBUG: --> Apply plugin: reject_null_sender
Jun 19 15:40:49 mail journal: iredapd DEBUG: <-- Result: DUNNO
Jun 19 15:40:49 mail journal: iredapd DEBUG: --> Apply plugin: wblist_rdns
Jun 19 15:40:49 mail journal: iredapd DEBUG: All policy rDNS names: ['mail-pf1-f176.google.com', '.mail-pf1-f176.google.com', '.google.com', '.com']
Jun 19 15:40:49 mail journal: iredapd DEBUG: [SQL] Query whitelisted rDNS names: #012SELECT rdns#012               FROM wblist_rdns#012              WHERE rdns IN ('mail-pf1-f176.google.com', '.mail-pf1-f176.google.com', '.google.com', '.com') AND wb='W'#012              LIMIT 1
Jun 19 15:40:49 mail journal: iredapd DEBUG: [SQL] Query blacklisted rDNS names: #012SELECT rdns#012               FROM wblist_rdns#012              WHERE rdns IN ('mail-pf1-f176.google.com', '.mail-pf1-f176.google.com', '.google.com', '.com') AND wb='B'#012              LIMIT 1
Jun 19 15:40:49 mail journal: iredapd DEBUG: <-- Result: DUNNO
Jun 19 15:40:49 mail journal: iredapd DEBUG: --> Apply plugin: reject_sender_login_mismatch
Jun 19 15:40:49 mail journal: iredapd DEBUG: Not an authenticated sender (no sasl_username).
Jun 19 15:40:49 mail journal: iredapd DEBUG: Sender domain is NOT hosted locally.
Jun 19 15:40:49 mail journal: iredapd DEBUG: <-- Result: DUNNO
Jun 19 15:40:49 mail journal: iredapd DEBUG: --> Apply plugin: greylisting
Jun 19 15:40:49 mail journal: iredapd DEBUG: [SQL] Query greylisting whitelists from `greylisting_whitelist_domain_spf`: #012SELECT sender#012                   FROM greylisting_whitelist_domain_spf#012                  WHERE account IN ('test@mydoamin.com', '@mydoamin.com', '@.', '@.mydoamin.com', '@.com')
Jun 19 15:40:49 mail journal: iredapd DEBUG: [SQL] Query greylisting whitelists from `greylisting_whitelists`: #012SELECT sender#012                   FROM greylisting_whitelists#012                  WHERE account IN ('test@mydoamin.com', '@mydoamin.com', '@.', '@.mydoamin.com', '@.com')
Jun 19 15:40:49 mail journal: iredapd DEBUG: [209.85.210.176] Client is not explictly whitelisted.
Jun 19 15:40:49 mail journal: iredapd INFO: [209.85.210.176] Client network is whitelisted: cidr=209.85.128.0/17
Jun 19 15:40:49 mail journal: iredapd DEBUG: <-- Result: DUNNO
Jun 19 15:40:49 mail journal: iredapd DEBUG: --> Apply plugin: throttle
Jun 19 15:40:49 mail journal: iredapd DEBUG: Check sender throttling.
Jun 19 15:40:49 mail journal: iredapd DEBUG: [LDAP] query target domain of given alias domain (gmail.com).
Jun 19 15:40:49 mail journal: iredapd DEBUG: [LDAP] query filter: ((&(objectClass=mailDomain)(accountStatus=active)(domainAliasName=gmail.com)))
Jun 19 15:40:49 mail journal: iredapd DEBUG: result: []
Jun 19 15:40:49 mail journal: iredapd DEBUG: [SQL] Query throttle setting: #012        SELECT id, account, priority, period, max_msgs, max_quota, msg_size#012          FROM throttle#012         WHERE kind='external' AND account IN ('209.85.210.176', '@ip', 'rain@gmail.com', '@gmail.com', '@.', '@.gmail.com', '@.com', '209.85.210.*', '209.85.*.176')#012         ORDER BY priority DESC
Jun 19 15:40:49 mail journal: iredapd DEBUG: [SQL] Query result: []
Jun 19 15:40:49 mail journal: iredapd DEBUG: No sender throttle setting.
Jun 19 15:40:49 mail journal: iredapd DEBUG: Check recipient throttling.
Jun 19 15:40:49 mail journal: iredapd DEBUG: [LDAP] query target domain of given alias domain (mydoamin.com).
Jun 19 15:40:49 mail journal: iredapd DEBUG: [LDAP] query filter: ((&(objectClass=mailDomain)(accountStatus=active)(domainAliasName=mydoamin.com)))
Jun 19 15:40:49 mail journal: iredapd DEBUG: result: []
Jun 19 15:40:49 mail journal: iredapd DEBUG: [SQL] Query throttle setting: #012        SELECT id, account, priority, period, max_msgs, max_quota, msg_size#012          FROM throttle#012         WHERE kind='inbound' AND account IN ('209.85.210.176', '@ip', 'test@mydoamin.com', '@mydoamin.com', '@.', '@.mydoamin.com', '@.com', '209.85.210.*', '209.85.*.176')#012         ORDER BY priority DESC
Jun 19 15:40:49 mail journal: iredapd DEBUG: [SQL] Query result: [(3L, '@mydoamin.com', 5, 86400L, 150L, -1L, 100000000L)]
Jun 19 15:40:49 mail journal: iredapd DEBUG: recipient throttle setting: msg_size=100000000 (bytes)/id=3/account=@mydoamin.com; max_msgs=150/id=3/account=@mydoamin.com;
Jun 19 15:40:49 mail journal: iredapd DEBUG: [SQL] Query throttle tracking data: SELECT id, tid, account, cur_msgs, cur_quota, init_time, last_time, last_notify_time#012               FROM throttle_tracking#012              WHERE (tid=3 AND account='209.85.210.176') OR (tid=3 AND account='test@mydoamin.com')
Jun 19 15:40:49 mail journal: iredapd DEBUG: [SQL] Query result: [(212L, 3L, 'test@mydoamin.com', 0, 0L, 1560904282L, 1560926642L, 0L)]
Jun 19 15:40:49 mail journal: iredapd DEBUG: Tracking IDs: {(3L, 'test@mydoamin.com'): 212L}
Jun 19 15:40:49 mail journal: iredapd INFO: [209.85.210.176] recipient throttle, test@mydoamin.com -> max_msgs (0/150, period: 86400 seconds, time left: 17 hours, 47 minutes, 20 seconds)
Jun 19 15:40:49 mail journal: iredapd DEBUG: [OK] Passed all recipient throttle settings.
Jun 19 15:40:49 mail journal: iredapd DEBUG: <-- Result: DUNNO
Jun 19 15:40:49 mail journal: iredapd DEBUG: [+] Getting LDIF data of account: test@mydoamin.com
Jun 19 15:40:49 mail journal: iredapd DEBUG: search base dn: o=domains,dc=mydoamin,dc=com
Jun 19 15:40:49 mail journal: iredapd DEBUG: search scope: SUBTREE
Jun 19 15:40:49 mail journal: iredapd DEBUG: search filter: (&(!(domainStatus=disabled))(|(mail=test@mydoamin.com)(shadowAddress=test@mydoamin.com))(|(objectClass=mailUser)(objectClass=mailList)(objectClass=mailAlias)))
Jun 19 15:40:49 mail journal: iredapd DEBUG: search attributes: ['objectClass', 'accountStatus', 'listAllowedUser', 'accessPolicy', 'enabledService']
Jun 19 15:40:49 mail journal: iredapd DEBUG: result: [('mail=test@mydoamin.com,ou=Users,domainName=mydoamin.com,o=domains,dc=mydoamin,dc=com', {'objectClass': ['inetOrgPerson', 'mailUser', 'shadowAccount', 'amavisAccount'], 'enabledService': ['managesievetls', 'managesieve', 'imaptls', 'displayedInGlobalAddressBook', 'sievetls', 'smtp', 'lda', 'smtpsecured', 'pop3', 'forward', 'deliver', 'lmtp', 'lib-storage', 'sieve', 'imap', 'dsync', 'smtptls', 'sogo', 'imapsecured', 'pop3tls', 'pop3secured', 'internal', 'doveadm', 'managesievesecured', 'mail', 'indexer-worker', 'sievesecured'], 'accountStatus': ['active']})]
Jun 19 15:40:49 mail journal: iredapd DEBUG: --> Apply plugin: ldap_maillist_access_policy
Jun 19 15:40:49 mail journal: iredapd DEBUG: <-- Result: DUNNO (Recipient is not a mailing list account)
Jun 19 15:40:49 mail journal: iredapd DEBUG: --> Apply plugin: amavisd_wblist
Jun 19 15:40:49 mail journal: iredapd DEBUG: [LDAP] query target domain of given alias domain (gmail.com).
Jun 19 15:40:49 mail journal: iredapd DEBUG: [LDAP] query filter: ((&(objectClass=mailDomain)(accountStatus=active)(domainAliasName=gmail.com)))
Jun 19 15:40:49 mail journal: iredapd DEBUG: result: []
Jun 19 15:40:49 mail journal: iredapd DEBUG: [LDAP] query target domain of given alias domain (mydoamin.com).
Jun 19 15:40:49 mail journal: iredapd DEBUG: [LDAP] query filter: ((&(objectClass=mailDomain)(accountStatus=active)(domainAliasName=mydoamin.com)))
Jun 19 15:40:49 mail journal: iredapd DEBUG: result: []
Jun 19 15:40:49 mail journal: iredapd DEBUG: Possible policy senders: ['rain@gmail.com', '@gmail.com', '@.', '@.gmail.com', '@.com', 'rain@*', '209.85.210.176', '209.85.210.*', '209.85.*.176']
Jun 19 15:40:49 mail journal: iredapd DEBUG: Possible policy recipients: ['test@mydoamin.com', '@mydoamin.com', '@.', '@.mydoamin.com', '@.com']
Jun 19 15:40:49 mail journal: iredapd DEBUG: Apply wblist for inbound message.
Jun 19 15:40:49 mail journal: iredapd DEBUG: [SQL] Query local addresses: #012SELECT id, email#012               FROM users#012              WHERE email IN ('test@mydoamin.com', '@mydoamin.com', '@.', '@.mydoamin.com', '@.com')#012           ORDER BY priority DESC
Jun 19 15:40:49 mail journal: iredapd DEBUG: Local addresses (in `users`): [(3L, '@mydoamin.com'), (1L, '@.')]
Jun 19 15:40:49 mail journal: iredapd DEBUG: [SQL] Query external addresses: #012SELECT id, email#012               FROM mailaddr#012              WHERE email IN ('rain@gmail.com', '@gmail.com', '@.', '@.gmail.com', '@.com', 'rain@*', '209.85.210.176', '209.85.210.*', '209.85.*.176')#012           ORDER BY priority DESC
Jun 19 15:40:49 mail journal: iredapd DEBUG: No record found in SQL database.
Jun 19 15:40:49 mail journal: iredapd DEBUG: [SQL] Query CIDR network: #012SELECT id, email#012               FROM mailaddr#012              WHERE email LIKE '209.%%'#012           ORDER BY priority DESC
Jun 19 15:40:49 mail journal: iredapd DEBUG: No valid sender id or recipient id.
Jun 19 15:40:49 mail journal: iredapd DEBUG: <-- Result: DUNNO
Jun 19 15:40:49 mail journal: iredapd DEBUG: Session ended.
Jun 19 15:40:49 mail journal: iredapd INFO: [209.85.210.176] RCPT, rain@gmail.com -> test@mydoamin.com, DUNNO [sasl_username=, sender=rain@gmail.com, client_name=mail-pf1-f176.google.com, reverse_client_name=mail-pf1-f176.google.com, helo=mail-pf1-f176.google.com, encryption_protocol=TLSv1.2, process_time=0.0167s]
Jun 19 15:40:53 mail journal: iredapd DEBUG: [srs][sender] input: get rain@gmail.com
Jun 19 15:40:53 mail journal: iredapd DEBUG: [srs][sender] [SQL] Query srs_exclude_domains: SELECT id FROM srs_exclude_domains WHERE domain IN ('gmail.com', '.gmail.com', 'com', '.com') LIMIT 1
Jun 19 15:40:53 mail journal: iredapd DEBUG: [srs][sender] [SQL] Query result: None
Jun 19 15:40:53 mail journal: iredapd INFO: [srs][sender] rewrited: rain@gmail.com -> SRS0=Rj1L=US=gmail.com=rain@mail.mydoamin.com
Jun 19 15:40:53 mail journal: iredapd DEBUG: [srs][sender] 200 SRS0=Rj1L=US=gmail.com=rain@mail.mydoamin.com
Jun 19 15:40:53 mail journal: iredapd DEBUG: [srs][sender] input: get SRS0=Rj1L=US=gmail.com=rain@mail.mydoamin.com
Jun 19 15:40:53 mail journal: iredapd DEBUG: [srs][sender] 500 Domain is srs_domain, bypassed.
Jun 19 15:40:53 mail journal: iredapd DEBUG: [srs][recipient] input: get test@mydoamin.com
Jun 19 15:40:53 mail journal: iredapd DEBUG: [srs][recipient] 500 Not a valid SRS address, bypassed.
Jun 19 15:40:54 mail journal: iredapd DEBUG: [policy] request=smtpd_access_policy
Jun 19 15:40:54 mail journal: iredapd DEBUG: [policy] protocol_state=END-OF-MESSAGE
Jun 19 15:40:54 mail journal: iredapd DEBUG: [policy] protocol_name=ESMTP
Jun 19 15:40:54 mail journal: iredapd DEBUG: [policy] client_address=209.85.210.176
Jun 19 15:40:54 mail journal: iredapd DEBUG: [policy] client_name=mail-pf1-f176.google.com
Jun 19 15:40:54 mail journal: iredapd DEBUG: [policy] reverse_client_name=mail-pf1-f176.google.com
Jun 19 15:40:54 mail journal: iredapd DEBUG: [policy] helo_name=mail-pf1-f176.google.com
Jun 19 15:40:54 mail journal: iredapd DEBUG: [policy] sender=rain@gmail.com
Jun 19 15:40:54 mail journal: iredapd DEBUG: [policy] recipient=test@mydoamin.com
Jun 19 15:40:54 mail journal: iredapd DEBUG: [policy] recipient_count=1
Jun 19 15:40:54 mail journal: iredapd DEBUG: [policy] queue_id=45TH1d6q34zBsTh8c
Jun 19 15:40:54 mail journal: iredapd DEBUG: [policy] instance=5012.5d09e701.993b5.0
Jun 19 15:40:54 mail journal: iredapd DEBUG: [policy] size=2661
Jun 19 15:40:54 mail journal: iredapd DEBUG: [policy] etrn_domain=
Jun 19 15:40:54 mail journal: iredapd DEBUG: [policy] stress=
Jun 19 15:40:54 mail journal: iredapd DEBUG: [policy] sasl_method=
Jun 19 15:40:54 mail journal: iredapd DEBUG: [policy] sasl_username=
Jun 19 15:40:54 mail journal: iredapd DEBUG: [policy] sasl_sender=
Jun 19 15:40:54 mail journal: iredapd DEBUG: [policy] ccert_subject=
Jun 19 15:40:54 mail journal: iredapd DEBUG: [policy] ccert_issuer=
Jun 19 15:40:54 mail journal: iredapd DEBUG: [policy] ccert_fingerprint=
Jun 19 15:40:54 mail journal: iredapd DEBUG: [policy] ccert_pubkey_fingerprint=
Jun 19 15:40:54 mail journal: iredapd DEBUG: [policy] encryption_protocol=TLSv1.2
Jun 19 15:40:54 mail journal: iredapd DEBUG: [policy] encryption_cipher=ECDHE-RSA-AES128-GCM-SHA256
Jun 19 15:40:54 mail journal: iredapd DEBUG: [policy] encryption_keysize=128
Jun 19 15:40:54 mail journal: iredapd DEBUG: Skip plugin: reject_null_sender (protocol_state != END-OF-MESSAGE)
Jun 19 15:40:54 mail journal: iredapd DEBUG: Skip plugin: wblist_rdns (protocol_state != END-OF-MESSAGE)
Jun 19 15:40:54 mail journal: iredapd DEBUG: Skip plugin: reject_sender_login_mismatch (protocol_state != END-OF-MESSAGE)
Jun 19 15:40:54 mail journal: iredapd DEBUG: Skip plugin: greylisting (protocol_state != END-OF-MESSAGE)
Jun 19 15:40:54 mail journal: iredapd DEBUG: --> Apply plugin: throttle
Jun 19 15:40:54 mail journal: iredapd DEBUG: Check sender throttling.
Jun 19 15:40:54 mail journal: iredapd DEBUG: [LDAP] query target domain of given alias domain (gmail.com).
Jun 19 15:40:54 mail journal: iredapd DEBUG: [LDAP] query filter: ((&(objectClass=mailDomain)(accountStatus=active)(domainAliasName=gmail.com)))
Jun 19 15:40:54 mail journal: iredapd DEBUG: result: []
Jun 19 15:40:54 mail journal: iredapd DEBUG: [SQL] Query throttle setting: #012        SELECT id, account, priority, period, max_msgs, max_quota, msg_size#012          FROM throttle#012         WHERE kind='external' AND account IN ('209.85.210.176', '@ip', 'rain@gmail.com', '@gmail.com', '@.', '@.gmail.com', '@.com', '209.85.210.*', '209.85.*.176')#012         ORDER BY priority DESC
Jun 19 15:40:54 mail journal: iredapd DEBUG: [SQL] Query result: []
Jun 19 15:40:54 mail journal: iredapd DEBUG: No sender throttle setting.
Jun 19 15:40:54 mail journal: iredapd DEBUG: Check recipient throttling.
Jun 19 15:40:54 mail journal: iredapd DEBUG: [LDAP] query target domain of given alias domain (mydoamin.com).
Jun 19 15:40:54 mail journal: iredapd DEBUG: [LDAP] query filter: ((&(objectClass=mailDomain)(accountStatus=active)(domainAliasName=mydoamin.com)))
Jun 19 15:40:54 mail journal: iredapd DEBUG: result: []
Jun 19 15:40:54 mail journal: iredapd DEBUG: [SQL] Query throttle setting: #012        SELECT id, account, priority, period, max_msgs, max_quota, msg_size#012          FROM throttle#012         WHERE kind='inbound' AND account IN ('209.85.210.176', '@ip', 'test@mydoamin.com', '@mydoamin.com', '@.', '@.mydoamin.com', '@.com', '209.85.210.*', '209.85.*.176')#012         ORDER BY priority DESC
Jun 19 15:40:54 mail journal: iredapd DEBUG: [SQL] Query result: [(3L, '@mydoamin.com', 5, 86400L, 150L, -1L, 100000000L)]
Jun 19 15:40:54 mail journal: iredapd DEBUG: recipient throttle setting: msg_size=100000000 (bytes)/id=3/account=@mydoamin.com; max_msgs=150/id=3/account=@mydoamin.com;
Jun 19 15:40:54 mail journal: iredapd DEBUG: [SQL] Query throttle tracking data: SELECT id, tid, account, cur_msgs, cur_quota, init_time, last_time, last_notify_time#012               FROM throttle_tracking#012              WHERE (tid=3 AND account='209.85.210.176') OR (tid=3 AND account='test@mydoamin.com')
Jun 19 15:40:54 mail journal: iredapd DEBUG: [SQL] Query result: [(212L, 3L, 'test@mydoamin.com', 0, 0L, 1560904282L, 1560926642L, 0L)]
Jun 19 15:40:54 mail journal: iredapd DEBUG: Tracking IDs: {(3L, 'test@mydoamin.com'): 212L}
Jun 19 15:40:54 mail journal: iredapd INFO: [209.85.210.176] recipient throttle, test@mydoamin.com -> msg_size (2661/100000000, period: 86400 seconds, time left: 17 hours, 47 minutes, 20 seconds)
Jun 19 15:40:54 mail journal: iredapd DEBUG: [SQL] Update tracking record: UPDATE throttle_tracking#012                              SET period=:period,#012                                  last_time=:last_time,#012                                  init_time=:init_time,#012                                  cur_msgs=:cur_msgs,#012                                  cur_quota=:cur_quota#012                            WHERE id=:id
Jun 19 15:40:54 mail journal: iredapd DEBUG: [OK] Passed all recipient throttle settings.
Jun 19 15:40:54 mail journal: iredapd DEBUG: <-- Result: DUNNO
Jun 19 15:40:54 mail journal: iredapd DEBUG: Skip plugin: ldap_maillist_access_policy (protocol_state != END-OF-MESSAGE)
Jun 19 15:40:54 mail journal: iredapd DEBUG: Skip plugin: amavisd_wblist (protocol_state != END-OF-MESSAGE)
Jun 19 15:40:54 mail journal: iredapd DEBUG: Session ended.
Jun 19 15:40:54 mail journal: iredapd INFO: [209.85.210.176] END-OF-MESSAGE, rain@gmail.com -> test@mydoamin.com, DUNNO [recipient_count=1, size=2661, process_time=0.0275s]

b). messages 的log
Jun 19 15:40:54 mail python2: /usr/lib64/python2.7/site-packages/sqlalchemy/engine/default.py:436: Warning: Incorrect integer value: 'cur_quota + 2661' for column 'cur_quota' at row 1
Jun 19 15:40:54 mail python2: cursor.execute(statement, parameters)

9

Re: 更新 iRedAPD-2.9 後 , 出現 Warning: Incorrect integer value

几分钟前修复了这个 bug 并测试通过。
请下载这个最新版本的 plugins/throttle.py 并替换掉 /opt/iredapd/plugins/throttle.py,然后重启 iredapd 服务即可。
https://bitbucket.org/zhb/iredapd/raw/9 … hrottle.py

10

Re: 更新 iRedAPD-2.9 後 , 出現 Warning: Incorrect integer value

Hi 版主:

測試 ok ,沒有異常的 log 訊息.

感謝.

11

Re: 更新 iRedAPD-2.9 後 , 出現 Warning: Incorrect integer value

谢谢反馈。topic closed.