I have Postfix on Ubuntu 22.04. I can only receive but not send emails.
I have configured Postfix using How To Install and Configure Postfix on Ubuntu 22.04 tutorial from DigitalOcean.
sudo tail -f /var/log/mail.log gives:
Dec 31 11:26:01 example postfix/smtp[9961]: 58A39D25A: to=<opendkim@example.com>, relay=none, delay=0.01, delays=0.01/0/0/0, dsn=5.4.6, status=bounced (mail for example.com loops back to myself)
Dec 31 11:26:01 example postfix/smtp[8787]: 58103D252: to=<vmail@example.com>, relay=none, delay=0.01, delays=0.01/0/0/0, dsn=5.4.6, status=bounced (mail for example.com loops back to myself)
Dec 31 11:26:01 example postfix/smtp[9593]: 576CAD23A: to=<root@example.com>, relay=none, delay=0.02, delays=0.01/0/0/0, dsn=5.4.6, status=bounced (mail for example.com loops back to myself)
Dec 31 11:26:01 example postfix/qmgr[5301]: 58A39D25A: removed
Dec 31 11:26:01 example postfix/qmgr[5301]: 58103D252: removed
Dec 31 11:26:01 example postfix/qmgr[5301]: 576CAD23A: removed
Dec 31 11:26:25 example postfix/smtp[7272]: connect to alt1.gmail-smtp-in.l.google.com[142.250.150.26]:25: Connection timed out
Dec 31 11:26:44 example postfix/pickup[9439]: 69CE6D23E: uid=1001 from=<founder@example.com>
Dec 31 11:26:44 example postfix/cleanup[8226]: 69CE6D23E: message-id=<20231231112644.pRsVV%founder@example.com>
Dec 31 11:26:44 example postfix/qmgr[5301]: 69CE6D23E: from=<founder@example.com>, size=335, nrcpt=1 (queue active)
Dec 31 11:26:55 example postfix/smtp[7272]: connect to alt2.gmail-smtp-in.l.google.com[2404:6800:4003:c00::1b]:25: Connection timed out
Dec 31 11:26:55 example postfix/smtp[7272]: D1398D22E: to=<examplez@gmail.com>, orig_to=<root>, relay=none, delay=4374, delays=4223/0/150/0, dsn=4.4.1, status=deferred (connect to alt2.gmail-smtp-in.l.google.com[2404:6800:4003:c00::1b]:25: Connection timed out)
What could be the reason I cannot send email?