MyBB Community Forums

Full Version: resolving smtp hostname issue?
You're currently viewing a stripped down version of our content. View the full version with proper formatting.
Hi, I am running tuxlite on a Ubuntu 12.10 64bit server, Running a mybb forum it seems I'm getting this error when trying to send email via mybb to our smtp server, The smtp server is configured correctly but I get this error

Unable to connect to the mail server with the given details. Reason: 0: php_network_getaddresses: getaddrinfo failed: Name or service not known

Seems like it can't resolve the SMTP servers hostname even though its the correct one, /etc/resolv.conf looks fine using googles dns, Anyone got any ideas?
Is the SMTP server localhost?

Also if it's new then it needs time to propagate.

From inside the server what do you get when you dig the SMTP?

dig smtp.server.name
Im using an external mail server for security, and results from dig

root@srv1:~# dig smtp

; <<>> DiG 9.8.1-P1 <<>> smtp.srv1.sitename.com
;; global options: +cmd
;; Got answer:
;; ->>HEADER<<- opcode: QUERY, status: NXDOMAIN, id: 54621
;; flags: qr rd ra; QUERY: 1, ANSWER: 0, AUTHORITY: 1, ADDITIONAL: 0

;; QUESTION SECTION:
;smtp.srv1.????.com. IN A

;; AUTHORITY SECTION:
????.com. 1800 IN SOA amy.ns.cloudflare.com. dns.cloudflare.com. 2013080417 10000 2400 604800 3600

;; Query time: 229 msec
;; SERVER: 8.8.8.8#53(8.8.8.8)
;; WHEN: Mon Aug 5 23:49:30 2013
;; MSG SIZE rcvd: 100


Also if I use the IP of the email server i get this error:
"Unable to connect to the mail server with the given details. Reason: 0:" and all the details are correct for the mail server and on our dns records as we use cloudflare for our dns.
You have to get rid of the Cloudflare to use the SMTP. They do not forward SMTP packets on port 25.
(2013-08-05, 11:01 PM)labrocca Wrote: [ -> ]You have to get rid of the Cloudflare to use the SMTP. They do not forward SMTP packets on port 25.

Even though I'm using an external mail provider? As I don't want to give the server IP's on our cloudfalre records were using the external mail provider. <snip> everything is setup to use the mail server on the dns side.
(2013-08-05, 11:12 PM)_MonsteR_ Wrote: [ -> ]
(2013-08-05, 11:01 PM)labrocca Wrote: [ -> ]You have to get rid of the Cloudflare to use the SMTP. They do not forward SMTP packets on port 25.

Even though I'm using an external mail provider? As I don't want to give the server IP's on our cloudfalre records were using the external mail provider. <snip> everything is setup to use the mail server on the dns side.

What you can do is that go to Cloudflare and edit your websites DNS settings. For the mail records, just disable the protection while keeping the protecting on for all the other records. This would allow your mail to go through and so-called hide your websites IP from whois searches.
Our Mail servers IPs aren't protected by cloudflare,

<snip>

Its setup to use our mail provider witch is shown at https://www.namecheap.com/support/knowle...-party-dns
So I don't think its a cloudflare issue, This is why I'm not sure why the emails are not working on mybb.

(2013-08-05, 11:31 PM)Arbaz Wrote: [ -> ]
(2013-08-05, 11:12 PM)_MonsteR_ Wrote: [ -> ]
(2013-08-05, 11:01 PM)labrocca Wrote: [ -> ]You have to get rid of the Cloudflare to use the SMTP. They do not forward SMTP packets on port 25.

Even though I'm using an external mail provider? As I don't want to give the server IP's on our cloudfalre records were using the external mail provider. <snip> everything is setup to use the mail server on the dns side.

What you can do is that go to Cloudflare and edit your websites DNS settings. For the mail records, just disable the protection while keeping the protecting on for all the other records. This would allow your mail to go through and so-called hide your websites IP from whois searches.

Thanks for the help, I got it sorted in the end it was some missing files so I re-uploaded the default core of mybb, also in General configurations the return/sender address was different I was trying to send mails from no.reply for General System emails to users but I guess I can't do that? Either way changed them all to the same email and it works fine now.
Hi,

The MyBB group offers support under the conditions of our Support Eligibility policy. It is apparent that one or more of your forums do not meet the conditions of our policy and therefore you are ineligible for support. This could be because of adult, piracy or hacking related content or because your forum does not display the minimum “Powered by MyBB” notice.

If you have any questions regarding this policy please post in the Private Inquiries forum.

Regards,
The MyBB group.