cancel
Showing results for 
Search instead for 
Did you mean: 
cancel
2677
Views
0
Helpful
2
Replies

EEM Email Script - Error in reply from E-mail Server

Links3000
Level 1
Level 1

Originally there was a problem with connecting to the mail server and the following error would generate as a result of testing the script:

 

*Oct 2 21:34:12.937: %HA_EM-3-FMPD_SMTP: Error occurred when sending mail to SMTP server: smtp.mydomain.com : error in connecting to SMTP server

*Oct 2 21:34:12.937: %HA_EM-3-FMPD_ERROR: Error executing applet Interface_Down statement 2.0

 

 

Afterwards, I asked our e-mail admin to add the device as a trusted mail relay, and sourced the script from a VRF reachable to the mail server, we then began to connect to the server but receive a separate error message:

 

*Oct 2 21:45:54.513: %HA_EM-3-FMPD_SMTP: Error occurred when sending mail to SMTP server: smtp.mydomain.com : error in reply from SMTP server

 

Can someone tell me if there's something wrong with my script, our should I be reaching out to the e-mail admin about something else here?

event manager environment _smtp smtp.mydomain.com
event manager environment _domain mydomain.com
event manager environment _rcpt admin@mydomain.com
event manager environment _send admin:password@mydomain.com


event manager applet Interface_Down
 event syslog pattern "changed state to administratively down"
 action 1.0 info type routername
 action 2.0 mail server "$_smtp" to "$_rcpt" from "$_send" subject "Interface down" body "$_syslog_msg" source-interface Loopback1 vrf Inside

sho event manager history events
No.  Job Id Proc Status   Time of Event            Event Type        Name
1    2      Actv success  Fri Oct 2 15:30:48 2015  syslog            applet: Interface_Down
2    3      Actv success  Fri Oct 2 16:58:51 2015  syslog            applet: Interface_Down
3    4      Actv success  Fri Oct 2 17:12:57 2015  syslog            applet: Interface_Down
4    5      Actv success  Fri Oct 2 17:24:03 2015  syslog            applet: Interface_Down
5    6      Actv success  Fri Oct 2 17:30:49 2015  syslog            applet: Interface_Down
9    10     Actv success  Thu Jan 7 16:51:43 2016  syslog            applet: Interface_Down
10   11     Actv success  Thu Jan 7 17:06:25 2016  syslog            applet: Interface_Down

1 Accepted Solution

Accepted Solutions

Joe Clarke
Cisco Employee
Cisco Employee

Likely the value of _send is not what you want.  Have your password exposed in the from address will do nothing but let the recipients learn your password.

That may or may not be the root of the problem.  Certainly if the mail server does from validation, it will fail.  I would make that a valid email address, then enable "debug event manager action mail" to see what the mail server returns.

View solution in original post

2 Replies 2

Joe Clarke
Cisco Employee
Cisco Employee

Likely the value of _send is not what you want.  Have your password exposed in the from address will do nothing but let the recipients learn your password.

That may or may not be the root of the problem.  Certainly if the mail server does from validation, it will fail.  I would make that a valid email address, then enable "debug event manager action mail" to see what the mail server returns.

Thanks Clarke! It's working! I removed the password from the send field and now it's working!

Review Cisco Networking for a $25 gift card