From what I have read, and seen on the server SMTP is setup and running. I cannot send an email using my server. Prior to today, I had just used my ISP’s smtp server. Now I have a client that needs to send mail through my server. So, I am using Thunderbird to test my mail server. I read my logs and found a problem and got that fixed. Now, it just times out. The error is that it has timed out.
I have setup smtp.myservername.com in DNS as an A record. Should it be something else?
As far as I know, port 25 is not blocked. I have a business account which allows me to run web and mail servers, so it should not be blocked.
Thanks for the response Eric. No, the server and the computer are on different networks. As far as I can tell, the server is setup for SMTP. Like I had mentioned, I was just using my ISP’s outgoing server, but now I have a client that needs to use my server for outgoing mail. I was just testing from my computer.
Many ISP’s allow you to get to their own mail server, but not port 25 on other servers on the Internet. So it’s possible that the ISP for your desktop computer is blocking SMTP connections to your server.
If you let me know the hostname for your server, I can tell you if port 25 is active on it or not. If you’re concerned about posting that on the forums here, you can always edit your post after we get this working to remove the hostname
My client tried smtp.pixelmountainstudio.com for their outgoing mail and they said it didn’t work. So maybe their ISP is blocking port 25. The trouble with that is that they had used their previous hosts email server to send their mail. We know the port is open, so what else could be the problem?
Well, if they enabled SSL or TLS for their authentication, it may be trying to use SMTPS or Submission… my recommendation would be to enable those in the /etc/postfix/master.cf file, and then restart Postfix.
If that doesn’t work, we’ll need to know the error your client is receiving.
Also, you’ll want to look at the logs for any clues to what’s going on.
The exact logs to look at depends on your distro, but you’ll want to look at the authentication logs in either /var/log/auth.log or /var/log/secure, and also the mail logs, which would be either /var/log/maillog or /var/log/mail.log.
I tried a few other things, but have now, I think, switched to SMTPS. I have tried it on my end, but it errors. I get Outlook is unable to connect to your outgoing mail server. That could be a blocked port on my end. I am having the client try it now.
I did open up port 465 on the firewall on the server.
There is nothing in the secure and mail logs. It seems like it is not going to the server at all.
In order to enable SMTPS in Postfix, you need to go into the Postfix master.cf file, and uncomment the lines near the top of the file beginning with “smtps”.
Once you do that, it should automatically listen on port 465.
You can verify that it’s listening on port 465 by running this command:
netstat -an | grep :465
If that doesn’t return anything, SMTPS isn’t enabled quite right
And things are looking up. But, I got a relay access denied when sending to one of my other accounts. Do I need to setup relaying in Postfix? I have seen that on the Postfix config pages.
Found this in the log
fatal: parameter “smtpd_recipient_restrictions”: specify at least one working instance of: check_relay_domains, reject_unauth_destination, reject, defer or defer_if_permit
After enabling, I did the netstat and got a response, plus I was able to telnet to it.
Glad you got that part working! That’s the hard part
But, I got a relay access denied when sending to one of my other accounts
That often means that in Outlook, it’s not trying to authenticate outgoing smtp connections. So although it may be using port 465, it’s not actually setup to pass in a username and password.
Make sure Outlook is authenticating outgoing smtp connections, as that’s typically not done by default.
fatal: parameter “smtpd_recipient_restrictions”: specify at least one working instance of: check_relay_domains, reject_unauth_destination, reject, defer or defer_if_permit
Hrm, that could be a problem too. Edit your /etc/postfix/main.cf file, find the line beginning with "smtpd_recipient_restrictions, and make sure the last parameter on that line is “reject_unauth_destination”. Then restart Postfix.
That’s in there by default, but it may have gotten lost in all the tweaking
I added reject_unauth_destination, but that didn’t help. It is the only entry there right now. I had Thunderbird set to use a username to login before sending. When I first tried this morning, after getting smtps set right, it asked for the password, which I gave it.
An error occurred while sending mail. The mail server responded: 4.3.5 Server configuration error. Please check the message recipient user@user.com and try again.
That was after adding those lines and restarting postfix.
It sounds like something may be wrong with your main.cf file.
It’s unusual that you wouldn’t see an error in the mail logs for an error like you’re seeing there… if you just go and restart Postfix without attempting to connect, does that show any errors?
Also, what output do you get if you type this on the command line: