jira发送邮件的报错

jira发送邮件的报错【传送门:https://www.cnblogs.com/heyongboke/p/9307433.html

1.安装完jira后,配置发送邮件出错具体报错如下:

复制代码

An error has occurred with sending the test email:
com.atlassian.mail.MailException: javax.mail.MessagingException: Exception reading response;
  nested exception is:
    java.net.SocketTimeoutException: Read timed out
    at com.atlassian.mail.server.impl.SMTPMailServerImpl.sendWithMessageId(SMTPMailServerImpl.java:225)
    at com.atlassian.mail.server.impl.SMTPMailServerImpl.send(SMTPMailServerImpl.java:162)
    at com.atlassian.jira.plugins.mail.webwork.SendTestMail.doExecute(SendTestMail.java:107)
    at webwork.action.ActionSupport.execute(ActionSupport.java:165)
    at com.atlassian.jira.action.JiraActionSupport.execute(JiraActionSupport.java:63)
    at webwork.interceptor.DefaultInterceptorChain.proceed(DefaultInterceptorChain.java:39)
    at webwork.interceptor.NestedInterceptorChain.proceed(NestedInterceptorChain.java:31)
    at webwork.interceptor.ChainedInterceptor.intercept(ChainedInterceptor.java:16)
    at webwork.interceptor.DefaultInterceptorChain.proceed(DefaultInterceptorChain.java:35)
    at webwork.dispatcher.GenericDispatcher.executeAction(GenericDispatcher.java:225)
.....
错误较多省略....
.....
Caused by: java.net.SocketTimeoutException: Read timed out
    at java.net.SocketInputStream.socketRead0(Native Method)
    at java.net.SocketInputStream.socketRead(SocketInputStream.java:116)
    at java.net.SocketInputStream.read(SocketInputStream.java:170)
    at java.net.SocketInputStream.read(SocketInputStream.java:141)
    at com.sun.mail.util.TraceInputStream.read(TraceInputStream.java:124)
    at java.io.BufferedInputStream.fill(BufferedInputStream.java:246)
    at java.io.BufferedInputStream.read(BufferedInputStream.java:265)
    at com.sun.mail.util.LineInputStream.readLine(LineInputStream.java:92)
    at com.sun.mail.smtp.SMTPTransport.readServerResponse(SMTPTransport.java:2349)
    ... 256 more

复制代码

 2.排查方法

(1)网上搜索的解决办法中大部分都没有用,好多都是使用网易163邮箱做的配置,而我使用的邮箱是腾讯企业邮箱配置,测试一直发送不了,下面是第一个报错信息

AuthenticationFailedException: 535 Error: authentication failed

这个错误主要是我太粗心,没有配置发送的邮件密码,后面添加密码后这个错误解决。

(2)第二个报错信息

  不幸的是, 没有连接是可能的。审查以下错误并纠正:

  • SocketTimeoutException: Read timed out

这里主要是端口问题,为465,测试报错,截图如下:

 

 在这里修改端口成功解决,端口号可以是25,也可以是587,就是465会报错。

 

-----------------------------------------要克服生活的焦虑和沮丧,得先学会做自己的主人-----------------------------------------

评论
添加红包

请填写红包祝福语或标题

红包个数最小为10个

红包金额最低5元

当前余额3.43前往充值 >
需支付:10.00
成就一亿技术人!
领取后你会自动成为博主和红包主的粉丝 规则
hope_wisdom
发出的红包
实付
使用余额支付
点击重新获取
扫码支付
钱包余额 0

抵扣说明:

1.余额是钱包充值的虚拟货币,按照1:1的比例进行支付金额的抵扣。
2.余额无法直接购买下载,可以购买VIP、付费专栏及课程。

余额充值