cancel
Showing results for 
Search instead for 
Did you mean: 
cancel
1081
Views
0
Helpful
4
Replies

sending through our mail server using user names and password

ScottHowison
Level 1
Level 1

Hi support

 

We are trying to use eem script and have issue with sending through our mail server

 

We are using a external mail server which uses a user name and password

 

we need information on the syntax  of passing username and password to the external mail server so we can send alerts below

 

 

event manager environment _email_from router@domain.com.au

event manager environment _email_to scott@domain.com.au

event manager environment _email_server #### : ****

 

 

event manager applet ISPCheck

event ipsla operation-id 1 reaction-type timeout

action 1.0 if $_ipsla_conditon eq "occurred"

action 1.1  wait 3

action 1.2  syslog msg "Primary Internet Circuit Down"

action 1.3  mail server "$_email_server" to "$_email_to" from "$_email_from" subject "circuit down" body "Primary Internet Circuit Down"

action 1.4 else

action 1.5  syslog msg "Primary Internet Circuit UP"

action 1.6  mail server "$_email_server" to "$_email_to" from "$_email_from" subject "Circuit up" body "Primary internet circuit up"

action 1.7 end

4 Replies 4

Philip D'Ath
VIP Alumni
VIP Alumni

Change your email server to (instead of just specifying the server to send via):

username:password@server

As  I am New  to this could  you show example please0

we are getting this error

can some help us with this 

 %HA_EM-3-FMPD_SMTP: Error occurred when sending mail to SMTP server: emailsend:emailsend4510*@domain.com : timeout error$ailsend:paswword@domain : timeout error


event manager environment _email_from router@domain.com
event manager environment _email_to scotthowison@domain.com
event manager environment _email_server username:password@itontapnetworks
event manager applet ISPCheck

event track 1 state down maxrun 60
event ipsla operation-id 1 reaction-type timeout
action 1.0 if $_ipsla_conditon eq "occurred"
action 1.1 wait 3
action 1.2 syslog msg "Primary Internet Circuit Down"
action 1.3 mail server "$_email_server" to "$_email_to" from "$_email_from" subject "circuit down" body "Primary Internet Circuit Down"
action 1.4 else
action 1.5 syslog msg "Primary Internet Circuit UP"
action 1.6 mail server "$_email_server" to "$_email_to" from "$_email_from" subject "Circuit up" body "Primary internet circuit up"
action 1.7 end

It looks like you have no connectivity to your mail server.  if you are connecting to it via DNS, can you ping that server name from the router?

Can you telnet from the router to port 25 on that mail server?