I’ve inherited some FreePBX systems(14, 15, & 16) that are able to send email… somehow…
/var/log/maillog suggests it’s beeing sent via postfix but I cannot find the postfix config file.
Here’s output from /var/log/maillog:
Jan 12 23:32:54 sub.dom.mydomain.com postfix/smtpd[25894]: connect from sub.dom.mydomain.com[::1]
Jan 12 23:32:55 sub.dom.mydomain.com postfix/smtpd[25894]: 0C1ABBF7A0: client=sub.dom.mydomain.com[::1]
Jan 12 23:32:55 sub.dom.mydomain.com postfix/cleanup[25897]: 0C1ABBF7A0: message-id=<[email protected]>
Jan 12 23:32:55 sub.dom.mydomain.com postfix/smtpd[25894]: disconnect from sub.dom.mydomain.com[::1]
Jan 12 23:32:55 sub.dom.mydomain.com postfix/qmgr[1097]: 0C1ABBF7A0: from=<[email protected]>, size=87927, nrcpt=1 (queue active)
Jan 12 23:32:55 sub.dom.mydomain.com postfix/smtp[25898]: 0C1ABBF7A0: to=<[email protected]>, relay=aspmx.l.google.com[142.250.114.26]:25, delay=0.55, delays=0.08/0.06/0.08/0.34, dsn=2.0.0, status=sent (250 2.0.0 OK 1736746375 46e09a7af769-7231864a298si6252728a34.180 - gsmtp)
Jan 12 23:32:55 sub.dom.mydomain.com postfix/qmgr[1097]: 0C1ABBF7A0: removed
I’ve searched for any gmail configuration in every single file in /etc/postfix (started with main.cf) as well as:
/usr/libexec/postfix
/var/spool/postfix
/var/lib/postfix
Is there another directory somewhere that I would find the configuration? I have scoured the internet to the best of my ability and am here as a last resort. I would deeply appreciate any and all help anyone has to offer
The server having a subdomain doesn’t really come into play here as far as your logs. It looks as if the server is setup to deliver mail directly over the Internet (i.e. no SMTP relay) and your domain in question is hosted by Google. So it’s going to send mail to Google to try to deliver it to the email account, which is hosted at Google.
Wouldn’t there be a configuration setting somewhere to instruct it to send the mail to google? The only setting I’ve been able to find is the From Address in the GUI at Admin → System Admin → Notification settings
The system is setup to send mail directly from the system to the destinations. It’s how SMTP works by default. So when it is sending email to [email protected] it’s going to lookup the MX records for mydomain.com, those resolve to Google’s SMTP servers. So it will now attempt to deliver the email to the destination servers. Which it is doing.
If you were to move the email hosting of the domain from Google to another provider or your own system, the mail logs would show it being sent to the new destination once the MX records were updated.
It doesn’t matter if it is Postfix, Exim, Sendmail, etc. the default is direct communication unless you configure the SMTP agent to use SMTP Reply. This system is using the default configuration of direct sending/communication.