Elasticsearch email alert question

Hi
When I tried the x-pack alarm function, I had a problem. Kibana told me Failed to send e-mail to songzhao@union400.com. Below is the log I found in elasticsearch. I don't quite understand the problem. Where is it because I am a newbie

[2018-11-20T17:21:33,244][ERROR][o.e.x.w.a.e.ExecutableEmailAction] [O_lrvKb] failed to execute action [_inlined_/email_1]
    javax.mail.MessagingException: failed to send email with subject [Watch [ceshi] has exceeded the threshold] via account [exchange_account]
    	at org.elasticsearch.xpack.watcher.notification.email.EmailService.send(EmailService.java:147) ~[?:?]
    	at org.elasticsearch.xpack.watcher.notification.email.EmailService.send(EmailService.java:139) ~[?:?]
    	at org.elasticsearch.xpack.watcher.actions.email.ExecutableEmailAction.execute(ExecutableEmailAction.java:72) ~[?:?]
    	at org.elasticsearch.xpack.core.watcher.actions.ActionWrapper.execute(ActionWrapper.java:144) [x-pack-core-6.3.2.jar:6.3.2]
    	at org.elasticsearch.xpack.watcher.execution.ExecutionService.executeInner(ExecutionService.java:475) [x-pack-watcher-6.3.2.jar:6.3.2]
    	at org.elasticsearch.xpack.watcher.execution.ExecutionService.execute(ExecutionService.java:305) [x-pack-watcher-6.3.2.jar:6.3.2]
    	at org.elasticsearch.xpack.watcher.transport.actions.execute.TransportExecuteWatchAction$1.doRun(TransportExecuteWatchAction.java:154) [x-pack-watcher-6.3.2.jar:6.3.2]
    	at org.elasticsearch.common.util.concurrent.AbstractRunnable.run(AbstractRunnable.java:37) [elasticsearch-6.3.2.jar:6.3.2]
    	at java.util.concurrent.Executors$RunnableAdapter.call(Executors.java:511) [?:1.8.0_181]
    	at java.util.concurrent.FutureTask.run(FutureTask.java:266) [?:1.8.0_181]
    	at org.elasticsearch.common.util.concurrent.ThreadContext$ContextPreservingRunnable.run(ThreadContext.java:626) [elasticsearch-6.3.2.jar:6.3.2]
    	at java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1149) [?:1.8.0_181]
    	at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:624) [?:1.8.0_181]
    	at java.lang.Thread.run(Thread.java:748) [?:1.8.0_181]
    Caused by: javax.mail.MessagingException: Could not connect to SMTP host: smtp.163.com, port: 465, response: -1
    	at com.sun.mail.smtp.SMTPTransport.openServer(SMTPTransport.java:2106) ~[?:?]
    	at com.sun.mail.smtp.SMTPTransport.protocolConnect(SMTPTransport.java:712) ~[?:?]
    	at javax.mail.Service.connect(Service.java:366) ~[?:?]
    	at org.elasticsearch.xpack.watcher.notification.email.Account.lambda$executeConnect$2(Account.java:153) ~[?:?]
    	at java.security.AccessController.doPrivileged(Native Method) ~[?:1.8.0_181]
    	at org.elasticsearch.xpack.watcher.notification.email.Account.executeConnect(Account.java:152) ~[?:?]
    	at org.elasticsearch.xpack.watcher.notification.email.Account.send(Account.java:111) ~[?:?]
    	at org.elasticsearch.xpack.watcher.notification.email.EmailServ> Blockquoteice.send(EmailService.java:145) ~[?:?]

I checked the mail server and it works fine. And I can send mail with mail.rc.
I want to know if there are any modules that are not enabled.

English is not my native language, so the description is not very good, forgive me

See this exception

The elasticsearch node trying to send an email could not connect to this, maybe the full stack trace will reveal more information.

Also, if you test the remote mail server, please make sure you are testing from the elasticsearch system to check if you are maybe running into firewall configurations.

Thanks for your reply, I will continue to try to solve this problem.:笑脸:

This topic was automatically closed 28 days after the last reply. New replies are no longer allowed.