Mail server connection failed with SMTP
Platform Notice: Data Center Only - This article only applies to Atlassian products on the Data Center platform.
Note that this KB was created for the Data Center version of the product. Data Center KBs for non-Data-Center-specific features may also work for Server versions of the product, however they have not been tested. Support for Server* products ended on February 15th 2024. If you are running a Server product, you can visit the Atlassian Server end of support announcement to review your migration options.
*Except Fisheye and Crucible
Problem
After configuring the mail server in Confluence to use SMTP with port 465, sending a test email fails with the following log:
The following appears in the Atlassian-Confluence.log
1
2
2016-02-02 02:57:04,496 ERROR [http-nio-8090-exec-1] [atlassian.confluence.jmx.JmxUtil] unregisterBean Unable to unregister object with name [ Confluence:name=MailServer-SMTP Сервер ] due to : javax.management.InstanceNotFoundException: Confluence:name=MailServer-SMTP Сервер
-- referer: http://109.206.188.107/confluence/admin/mail/editmailserver.action?id=1454367622001 | url: /confluence/admin/mail/doeditmailserver.action | userName: cnf | action: doeditmailserver
Affects Confluence 7.16.x and earlier.
Cause
Port 465 shows up in Appendix A of the 1996 non-standard The SSL Protocol Version 3.0 as "Simple Mail Transfer Protocol with SSL". Unfortunately, it's not registered for SMTPs. It's registered for URD - "URL Rendezvous Directory for SSL" by Cisco. The recommended approach, at least for authentication, is to use STARTTLS encryption on port 587.
Port 25 can be used but it is for server to relay messages to one another. Port 587 is recommended because this way ISPs can block outgoing SMTP on their networks but still allow users to send email to another mail server.
Resolution
Was this helpful?