NS8 mail error in logfiles, startup looping

Does this ring a bell please?

Account provider: AD

------- App error

2023-11-08T16:12:01+01:00 [1:mail1:systemd] Started libcrun container.
2023-11-08T16:12:01+01:00 [1:mail1:postfix] e7a3d5db75d069a293b52a812499a94d81a560a9859f58d114454925c60e43e4
2023-11-08T16:12:01+01:00 [1:mail1:systemd] Started Postfix MTA/MSA server.
2023-11-08T16:12:03+01:00 [1:mail1:postfix/postfix-script] the Postfix mail system is not running
2023-11-08T16:12:03+01:00 [1:mail1:postfix/postfix-script] starting the Postfix mail system
2023-11-08T16:12:03+01:00 [1:mail1:postfix/master] fatal: bind 0.0.0.0 port 25: Address in use
2023-11-08T16:12:04+01:00 [1:mail1:systemd] postfix.service: Main process exited, code=exited, status=1/FAILURE
2023-11-08T16:12:04+01:00 [1:mail1:postfix] e7a3d5db75d069a293b52a812499a94d81a560a9859f58d114454925c60e43e4
2023-11-08T16:12:04+01:00 [1:mail1:systemd] postfix.service: Failed with result 'exit-code'.
2023-11-08T16:12:04+01:00 [1:mail1:systemd] postfix.service: Consumed 2.005s CPU time.
2023-11-08T16:12:05+01:00 [1:mail1:systemd] postfix.service: Scheduled restart job, restart counter is at 27693.
2023-11-08T16:12:05+01:00 [1:mail1:systemd] Stopped Postfix MTA/MSA server.
2023-11-08T16:12:05+01:00 [1:mail1:systemd] postfix.service: Consumed 2.005s CPU time.
2023-11-08T16:12:05+01:00 [1:mail1:systemd] Starting Postfix MTA/MSA server...

Task module/mail1/get-filter-configuration failed

Traceback (most recent call last):
  File "/home/mail1/.config/actions/get-filter-configuration/10get_filter_configuration", line 29, in <module>
    odata["bypass_rules"] = sum([len(set(l)) for l in mail.rspamd_get_bypass_maps().values()])
                                                      ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
  File "/home/mail1/.config/pypkg/mail.py", line 344, in rspamd_get_bypass_maps
    if not omap['uri'].startswith('/var/lib/rspamd/bypass_'):
           ~~~~^^^^^^^
TypeError: string indices must be integers, not 'str'

----------

Traceback (most recent call last):
  File "/usr/local/agent/pyenv/lib64/python3.11/site-packages/requests/models.py", line 971, in json
    return complexjson.loads(self.text, **kwargs)
           ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
  File "/usr/lib64/python3.11/json/__init__.py", line 346, in loads
    return _default_decoder.decode(s)
           ^^^^^^^^^^^^^^^^^^^^^^^^^^
  File "/usr/lib64/python3.11/json/decoder.py", line 337, in decode
    obj, end = self.raw_decode(s, idx=_w(s, 0).end())
               ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
  File "/usr/lib64/python3.11/json/decoder.py", line 355, in raw_decode
    raise JSONDecodeError("Expecting value", s, err.value) from None
json.decoder.JSONDecodeError: Expecting value: line 1 column 1 (char 0)

During handling of the above exception, another exception occurred:

Traceback (most recent call last):
  File "/home/mail1/.config/actions/list-public-mailboxes/10list_public_mailboxes", line 64, in <module>
    for mbxn in mail.get_public_mailboxes():
                ^^^^^^^^^^^^^^^^^^^^^^^^^^^
  File "/home/mail1/.config/pypkg/mail.py", line 72, in get_public_mailboxes
    for ombx in doveadm_query("mailboxList", {"user": "vmail","mailboxMask":["%"]}):
                ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
  File "/home/mail1/.config/pypkg/mail.py", line 269, in doveadm_query
    oresp = requests.post(f"http://127.0.0.1:{dport}/doveadm/v1", json=req, headers={"Authorization": "X-Dovecot-API " + atok}).json()
            ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
  File "/usr/local/agent/pyenv/lib64/python3.11/site-packages/requests/models.py", line 975, in json
    raise RequestsJSONDecodeError(e.msg, e.doc, e.pos)
requests.exceptions.JSONDecodeError: Expecting value: line 1 column 1 (char 0)

Is another Mail instance or SMTP service holding port 25?

Node 1 has 2 mail instances. 1 with AD and 1 with LDAP. Node 1 is the only node.

Two services cannot listen on the same TCP port.

Only one Mail instance can run on a node: remove one of them!

As mail1 is in crashloop, I’d remove it first.

7 posts were split to a new topic: Two mail instances on the same node

Yes it does!

Thank you for running NS8 and for your feedback! :medal_sports: