First off, I am a newbie to this but my goals are simple: host a single website and have a single functioning email address that forwards to gmail or I can add as a POP3 to gmail.
What I've done so far: -Started with a fresh CentOS 6.5 VPS (on digitalocean if that's relevant). -Updated, and installed perl. -Installed virtualmin via the script. -Added DNS records on digitalocean and turned off bind. -Added user "support" which is the email address I need functioning. -I've not changed any settings in postfix or dovecot.
What hasn't worked -Send a test email to support@mydomain.com (nothing in maildir). -Send a test email to root@mydomain.com (nothing in maildir). -Send a test email to support@server.mydomain.com (bounced back). -I successfully added "support@mydomain.com" as a POP3 in gmail, but it gave me an error when it tried to fetch. -telnet to port 25 yielded connection refused.
Outgoing mail sent from CLI works, but comes from "support@server.mydomain.com". Netstat shows dovecot listening on all relevant ports. I don't see anything in maillog regarding the failed incoming emails.
Any help or suggestions appreciated.
So I tried restarting postfix. After which I was able to telnet port 25. So I tried to send a test email again from gmail and delivery failed with this message:
Technical details of permanent failure: Google tried to deliver your message, but it was rejected by the server for the recipient domain domain.com by mail.domain.com. [XX.XX.XX.XX].
The error that the other server returned was: 554 5.7.1 support@domain.com: Relay access denied
Howdy,
Is the "Mail for Domain" feature enabled for that domain in Virtualmin? You can verify that by going into Edit Virtual Server -> Enabled Features.
That's an example of something that could cause the problem you're seeing, as that feature would need to be enabled.
-Eric
I didn't create a virtual server, i just used the defaults.
I was able to fix this by adding "thedomain.com" to mydestination in main.cf.
I'm not sure that is the correct fix but everything is working.