[SOLVED] Transports destination host doesn't reflect changes

lonea

Active Member
Feb 25, 2020
30
3
28
49
I'm not sure if this is a bug (6.0-6) or not.

I have tried removing the domain in the Relay, Transports section and then add it back. Just tried updating the host field under Transports, also restarted the server. All resulted the same. Emails being routed to the old destination.

To break down my issue.
old destination - oldint.domain.com
new destination - newint.domain.com

I have my filtering/Transport routing setup as such.

Incoming email (service.domain.com) -> externalmx
From externalmx, it forwards back into (incoming.domain.com) -> newint.domain.com

I'm have it setup this way for archiving and PHP piping purpose.

Doesn't matter what I'm trying, PMG is still routing to oldint.domain.com. I have even tried removing the domain incoming.domain.com from Transports and Relay and then send a email to test. As this should bounceback with a message saying the domain is not authorized to relay etc... But the test email still get routed to oldint.domain.com

What's going on here ?
 
please post the logs of one such mail - and the current configuration (pmgconfig dump) - anonymize the config in a way that it can still be understood.
 
Here is an email I just sent

Outside email (test@testemail.com) to email address cs@service.domain.com -> extMX (1.2.3.4)
Code:
Feb 26 09:36:44 infilter1 postfix/smtpd[29052]: connect from mail-pl1-f194.google.com[209.85.214.194]
Feb 26 09:36:44 infilter1 postfix/smtpd[29052]: ECE5F2005E4: client=mail-pl1-f194.google.com[209.85.214.194]
Feb 26 09:36:44 infilter1 postfix/cleanup[29055]: ECE5F2005E4: info: header From: S J <test@testemail.com> from mail-pl1-f194.google.com[209.85.214.194]; from=<test@testemail.com> to=<cs@service.domain.com> proto=ESMTP helo=<mail-pl1-f194.google.com>
Feb 26 09:36:44 infilter1 postfix/cleanup[29055]: ECE5F2005E4: message-id=<CAPvnPVQLA3=p0PVKXU9hCXkoV5miYanS6EhnYUwLixD060dqsg@mail.gmail.com>
Feb 26 09:36:44 infilter1 postfix/cleanup[29055]: ECE5F2005E4: info: header Subject: test from mail-pl1-f194.google.com[209.85.214.194]; from=<test@testemail.com> to=<cs@service.domain.com> proto=ESMTP helo=<mail-pl1-f194.google.com>
Feb 26 09:36:44 infilter1 postfix/cleanup[29055]: ECE5F2005E4: info: header To: Company Customer Care <cs@service.domain.com> from mail-pl1-f194.google.com[209.85.214.194]; from=<test@testemail.com> to=<cs@service.domain.com> proto=ESMTP helo=<mail-pl1-f194.google.com>
Feb 26 09:36:45 infilter1 postfix/qmgr[803]: ECE5F2005E4: from=<test@testemail.com>, size=2878, nrcpt=1 (queue active)
Feb 26 09:36:45 infilter1 pmg-smtp-filter[28946]: 2007195E56827D0DF7C: new mail message-id=<CAPvnPVQLA3=p0PVKXU9hCXkoV5miYanS6EhnYUwLixD060dqsg@mail.gmail.com>#012
Feb 26 09:36:45 infilter1 postfix/smtpd[29052]: disconnect from mail-pl1-f194.google.com[209.85.214.194] ehlo=2 starttls=1 mail=1 rcpt=1 bdat=1 quit=1 commands=7
Feb 26 09:36:46 infilter1 pmg-smtp-filter[28946]: 2007195E56827D0DF7C: SA score=0/5 time=0.898 bayes=0.00 autolearn=ham autolearn_force=no hits=AWL(0.138),BAYES_00(-1.9),DKIM_SIGNED(0.1),DKIM_VALID(-0.1),DKIM_VALID_AU(-0.1),DKIM_VALID_EF(-0.1),FREEMAIL_FROM(0.001),HTML_MESSAGE(0.001),RCVD_IN_MSPIKE_H3(0.001),RCVD_IN_MSPIKE_WL(0.001),SPF_HELO_NONE(0.001),SPF_PASS(-0.001)
Feb 26 09:36:46 infilter1 postfix/smtpd[29060]: connect from localhost.localdomain[127.0.0.1]
Feb 26 09:36:46 infilter1 postfix/smtpd[29060]: 277F020071A: client=localhost.localdomain[127.0.0.1], orig_client=mail-pl1-f194.google.com[209.85.214.194]
Feb 26 09:36:46 infilter1 postfix/cleanup[29055]: 277F020071A: message-id=<CAPvnPVQLA3=p0PVKXU9hCXkoV5miYanS6EhnYUwLixD060dqsg@mail.gmail.com>
Feb 26 09:36:46 infilter1 postfix/qmgr[803]: 277F020071A: from=<test@testemail.com>, size=4046, nrcpt=1 (queue active)
Feb 26 09:36:46 infilter1 postfix/smtpd[29060]: disconnect from localhost.localdomain[127.0.0.1] ehlo=1 xforward=1 mail=1 rcpt=1 data=1 commands=5
Feb 26 09:36:46 infilter1 pmg-smtp-filter[28946]: 2007195E56827D0DF7C: accept mail to <cs@service.domain.com> (277F020071A) (rule: default-accept)
Feb 26 09:36:46 infilter1 pmg-smtp-filter[28946]: 2007195E56827D0DF7C: processing time: 1.161 seconds (0.898, 0.099, 0)
Feb 26 09:36:46 infilter1 postfix/lmtp[29056]: ECE5F2005E4: to=<cs@service.domain.com>, relay=127.0.0.1[127.0.0.1]:10024, delay=1.4, delays=0.18/0.03/0.01/1.2, dsn=2.5.0, status=sent (250 2.5.0 OK (2007195E56827D0DF7C))
Feb 26 09:36:46 infilter1 postfix/qmgr[803]: ECE5F2005E4: removed
Feb 26 09:36:46 infilter1 postfix/smtp[29061]: 277F020071A: to=<cs@service.domain.com>, relay=m.externalmx.com[1.2.3.4]:25, delay=0.63, delays=0.05/0.06/0.11/0.4, dsn=2.0.0, status=sent (250 OK)
Feb 26 09:36:46 infilter1 postfix/qmgr[803]: 277F020071A: removed
 
Here is the log from extMX (1.2.3.4) forwarding back to the piping email address (pipe@incoming.domain.com) (int.servers.com - 2.3.4.5) but it should be (newint.servers.com - 3.4.5.6)

Code:
Feb 26 09:36:53 infilter1 postfix/smtpd[29052]: connect from m.externalmx.com[1.2.3.4]
Feb 26 09:36:53 infilter1 postfix/smtpd[29052]: A63F62005E4: client=m.externalmx.com[1.2.3.4]
Feb 26 09:36:53 infilter1 postfix/cleanup[29055]: A63F62005E4: info: header From: S J <test@testemail.com> from m.externalmx.com[1.2.3.4]; from=<SRS0=7BIQ=5E=GMAIL.COM=testemail@SERVICE.domain.com> to=<pipe@incoming.domain.com> proto=ESMTP helo=<m.externalmx.com>
Feb 26 09:36:53 infilter1 postfix/cleanup[29055]: A63F62005E4: message-id=<CAPvnPVQLA3=p0PVKXU9hCXkoV5miYanS6EhnYUwLixD060dqsg@mail.gmail.com>
Feb 26 09:36:53 infilter1 postfix/cleanup[29055]: A63F62005E4: info: header Subject: test from m.externalmx.com[1.2.3.4]; from=<SRS0=7BIQ=5E=GMAIL.COM=testemail@SERVICE.domain.com> to=<pipe@incoming.domain.com> proto=ESMTP helo=<m.externalmx.com>
Feb 26 09:36:53 infilter1 postfix/cleanup[29055]: A63F62005E4: info: header To: Company Customer Care <cs@service.domain.com> from m.externalmx.com[1.2.3.4]; from=<SRS0=7BIQ=5E=GMAIL.COM=testemail@SERVICE.domain.com> to=<pipe@incoming.domain.com> proto=ESMTP helo=<m.externalmx.com>
Feb 26 09:36:53 infilter1 postfix/qmgr[803]: A63F62005E4: from=<SRS0=7BIQ=5E=GMAIL.COM=testemail@SERVICE.domain.com>, size=4815, nrcpt=1 (queue active)
Feb 26 09:36:53 infilter1 pmg-smtp-filter[28888]: 2007195E568285C87D9: new mail message-id=<CAPvnPVQLA3=p0PVKXU9hCXkoV5miYanS6EhnYUwLixD060dqsg@mail.gmail.com>#012
Feb 26 09:36:53 infilter1 postfix/smtpd[29052]: disconnect from m.externalmx.com[1.2.3.4] ehlo=2 starttls=1 mail=1 rcpt=1 data=1 quit=1 commands=7
Feb 26 09:36:54 infilter1 pmg-smtp-filter[28888]: 2007195E568285C87D9: SA score=0/5 time=0.895 bayes=0.00 autolearn=no autolearn_force=no hits=AWL(-0.038),BAYES_00(-1.9),DKIM_SIGNED(0.1),DKIM_VALID(-0.1),DKIM_VALID_AU(-0.1),FREEMAIL_FORGED_FROMDOMAIN(0.001),FREEMAIL_FROM(0.001),HEADER_FROM_DIFFERENT_DOMAINS(0.248),HTML_MESSAGE(0.001),SPF_HELO_NONE(0.001),SPF_PASS(-0.001)
Feb 26 09:36:54 infilter1 postfix/smtpd[29060]: connect from localhost.localdomain[127.0.0.1]
Feb 26 09:36:54 infilter1 postfix/smtpd[29060]: CE86420071A: client=localhost.localdomain[127.0.0.1], orig_client=m.externalmx.com[1.2.3.4]
Feb 26 09:36:54 infilter1 postfix/cleanup[29055]: CE86420071A: message-id=<CAPvnPVQLA3=p0PVKXU9hCXkoV5miYanS6EhnYUwLixD060dqsg@mail.gmail.com>
Feb 26 09:36:54 infilter1 postfix/qmgr[803]: CE86420071A: from=<SRS0=7BIQ=5E=GMAIL.COM=testemail@SERVICE.domain.com>, size=5041, nrcpt=1 (queue active)
Feb 26 09:36:54 infilter1 postfix/smtpd[29060]: disconnect from localhost.localdomain[127.0.0.1] ehlo=1 xforward=1 mail=1 rcpt=1 data=1 commands=5
Feb 26 09:36:54 infilter1 pmg-smtp-filter[28888]: 2007195E568285C87D9: accept mail to <pipe@incoming.domain.com> (CE86420071A) (rule: default-accept)
Feb 26 09:36:54 infilter1 pmg-smtp-filter[28888]: 2007195E568285C87D9: processing time: 1.087 seconds (0.895, 0.064, 0)
Feb 26 09:36:54 infilter1 postfix/lmtp[29056]: A63F62005E4: to=<pipe@incoming.domain.com>, relay=127.0.0.1[127.0.0.1]:10024, delay=1.5, delays=0.32/0/0.01/1.1, dsn=2.5.0, status=sent (250 2.5.0 OK (2007195E568285C87D9))
Feb 26 09:36:54 infilter1 postfix/qmgr[803]: A63F62005E4: removed
Feb 26 09:36:55 infilter1 postfix/smtp[29061]: CE86420071A: to=<pipe@incoming.domain.com>, relay=int.servers.com[2.3.4.5]:25, delay=0.69, delays=0.06/0/0.34/0.29, dsn=2.0.0, status=sent (250 OK id=1j6xnz-000Kfy-Fu)
Feb 26 09:36:55 infilter1 postfix/qmgr[803]: CE86420071A: removed

Here is the config

Code:
composed.wl_bounce_relays = infilter1.baseservers.com
dns.domain = whitelabel.com
dns.fqdn = infilter1.whitelable.com
dns.hostname = infilter1
ipconfig.int_ip = 7.8.9.0
pmg.admin.advfilter = 1
pmg.admin.avast = 0
pmg.admin.clamav = 1
pmg.admin.custom_check = 0
pmg.admin.custom_check_path = /usr/local/bin/pmg-custom-check
pmg.admin.dailyreport = 1
pmg.admin.demo = 0
pmg.admin.dkim_selector =
pmg.admin.dkim_sign = 0
pmg.admin.dkim_sign_all_mail = 0
pmg.admin.email = na@na.com
pmg.admin.http_proxy =
pmg.admin.statlifetime = 7
pmg.clamav.archiveblockencrypted = 0
pmg.clamav.archivemaxfiles = 1000
pmg.clamav.archivemaxrec = 5
pmg.clamav.archivemaxsize = 25000000
pmg.clamav.dbmirror = database.clamav.net
pmg.clamav.maxcccount = 0
pmg.clamav.maxscansize = 100000000
pmg.clamav.safebrowsing = 1
pmg.mail.banner = ESMTP Inbound Filter
pmg.mail.before_queue_filtering = 0
pmg.mail.conn_count_limit = 50
pmg.mail.conn_rate_limit = 0
pmg.mail.dnsbl_sites = xbl.spamhaus.org,sbl.spamhaus.org,bl-ns.rbl.scrolloutf1.com,bl-ip.rbl.scrolloutf1.com
pmg.mail.dnsbl_threshold = 1
pmg.mail.dwarning = 4
pmg.mail.ext_port = 25
pmg.mail.greylist = 0
pmg.mail.helotests = 0
pmg.mail.hide_received = 0
pmg.mail.int_port = 26
pmg.mail.max_filters = 31
pmg.mail.max_policy = 5
pmg.mail.max_smtpd_in = 100
pmg.mail.max_smtpd_out = 100
pmg.mail.maxsize = 10485760
pmg.mail.message_rate_limit = 0
pmg.mail.ndr_on_block = 0
pmg.mail.rejectunknown = 0
pmg.mail.rejectunknownsender = 0
pmg.mail.relay =
pmg.mail.relaynomx = 0
pmg.mail.relayport = 25
pmg.mail.relayprotocol = smtp
pmg.mail.smarthost =
pmg.mail.smarthostport = 25
pmg.mail.spf = 1
pmg.mail.tls = 1
pmg.mail.tlsheader = 0
pmg.mail.tlslog = 0
pmg.mail.verifyreceivers =
pmg.spam.bounce_score = 0
pmg.spam.clamav_heuristic_score = 3
pmg.spam.languages = all
pmg.spam.maxspamsize = 262144
pmg.spam.rbl_checks = 1
pmg.spam.use_awl = 1
pmg.spam.use_bayes = 1
pmg.spam.use_razor = 1
pmg.spam.wl_bounce_relays =
pmg.spamquar.allowhrefs = 1
pmg.spamquar.authmode = ticket
pmg.spamquar.hostname =
pmg.spamquar.lifetime = 7
pmg.spamquar.mailfrom =
pmg.spamquar.port = 8006
pmg.spamquar.protocol = https
pmg.spamquar.reportstyle = verbose
pmg.spamquar.viewimages = 1
pmg.virusquar.allowhrefs = 1
pmg.virusquar.lifetime = 7
pmg.virusquar.viewimages = 1
postfix.dnsbl_sites = xbl.spamhaus.org,sbl.spamhaus.org,bl-ns.rbl.scrolloutf1.com,bl-ip.rbl.scrolloutf1.com
postfix.dnsbl_threshold = 1
postfix.int_ip = 7.8.9.0
postfix.mynetworks = 127.0.0.0/8 [::1]/128 23.92.210.64/29
postfix.transportnets =
postfix.usepolicy = 1
postgres.version = 11

One interesting thing I find is in the dnsbl config, I removed both entries of scrolloutf1.com from the GUI already yesterday, but it is still showing up with the dump just now.

https://prnt.sc/r809ky
 
One interesting thing I find is in the dnsbl config, I removed both entries of scrolloutf1.com from the GUI already yesterday,
This is strange - is this the same system, and did you click on save?
* is anything in the logs when you change the dnsbl sites?

please also post your /etc/pmg/transports and /etc/pmg/domains
 
Ok, in /etc/pmg/transports, the destination is still set to oldint... So that explains the delivery issue.

I'm running this in a cluster, I can see the Master is Active but the two nodes are in Syncing state forever. Could this be where the issue lies?

On the master's syslog
Code:
Feb 26 10:48:05 filter-backup pmgmirror[1039]: starting cluster syncronization
Feb 26 10:48:06 filter-backup pmgmirror[1039]: cluster syncronization finished  (0 errors, 1.51 seconds (files 0.94, database 0.57, config 0.00))
Feb 26 10:50:05 filter-backup pmgmirror[1039]: starting cluster syncronization
Feb 26 10:50:06 filter-backup pmgmirror[1039]: cluster syncronization finished  (0 errors, 1.19 seconds (files 0.71, database 0.48, config 0.00))
Feb 26 10:52:05 filter-backup pmgmirror[1039]: starting cluster syncronization
Feb 26 10:52:07 filter-backup pmgmirror[1039]: cluster syncronization finished  (0 errors, 1.21 seconds (files 0.71, database 0.50, config 0.00))
Feb 26 10:54:05 filter-backup pmgmirror[1039]: starting cluster syncronization
Feb 26 10:54:06 filter-backup pmgmirror[1039]: cluster syncronization finished  (0 errors, 1.18 seconds (files 0.69, database 0.49, config 0.00))

on the node

Code:
Feb 26 10:47:22 infilter1 pmgmirror[1000]: starting cluster syncronization
Feb 26 10:49:22 infilter1 pmgmirror[1000]: starting cluster syncronization
Feb 26 10:51:22 infilter1 pmgmirror[1000]: starting cluster syncronization
Feb 26 10:53:22 infilter1 pmgmirror[1000]: starting cluster syncronization
Feb 26 10:55:22 infilter1 pmgmirror[1000]: starting cluster syncronization
 
Last edited:
Ok located the issue, seems like rsync is refusing.

Code:
rsync: connection unexpectedly closed (0 bytes received so far) [Receiver]
syncing master configuration from 'masternodeip' failed: rsync error: unexplained error (code 255) at io.c(235) [Receiver=3.1.3]

The Master was missing the ssh keys from the nodes, added it back in and the rsync worked.

However, when I'm trying to sync from second node. I'm getting.

Code:
could not change directory to "/root": Permission denied
could not change directory to "/root": Permission denied
could not change directory to "/root": Permission denied
could not change directory to "/root": Permission denied
could not change directory to "/root": Permission denied
could not change directory to "/root": Permission denied
could not change directory to "/root": Permission denied
could not change directory to "/root": Permission denied
could not change directory to "/root": Permission denied
could not change directory to "/root": Permission denied
could not change directory to "/root": Permission denied
could not change directory to "/root": Permission denied
 
Last edited:
So is the "could not change directory to "/root": Permission denied" normal for when running a pmgcm sync?

I get that error but in the GUI says all 3 members are active.
 
I'm running this in a cluster, I can see the Master is Active but the two nodes are in Syncing state forever. Could this be where the issue lies?

most likely that's the issue

"could not change directory to "/root": Permission denied"
Try running the command while you're not in '/root'
i.e.: `cd tmp; pmgcm sync`
 

About

The Proxmox community has been around for many years and offers help and support for Proxmox VE, Proxmox Backup Server, and Proxmox Mail Gateway.
We think our community is one of the best thanks to people like you!

Get your subscription!

The Proxmox team works very hard to make sure you are running the best software and getting stable updates and security enhancements, as well as quick enterprise support. Tens of thousands of happy customers have a Proxmox subscription. Get yours easily in our online shop.

Buy now!