Email Log Setting

Hey guys,

I am trying to setup my router so it can email me when things go wrong>


do you know if i can use Gmail as my smtp cause it uses secure connection?


I have setup with another email account:

but when the RB logs, it says invalid TO address? do i have to do any thing special under logs where it says email?

i just put the email in there?

please help

Take a look at this:
http://wiki.mikrotik.com/wiki/Email_setup/troubleshooting
If you have any questions after that, I might be able to help.

ADD: Normally, an “Invalid TO address” means you are trying to relay the email. If you use port 25 with gmail, it MUST be a gmail “TO” address.

I already had a look at that?

What must the smtp server address be?

i put in smtp.gmail.com is that right?

i have put in port 465
my user and password:

Does From:" " make any difference? does it matter whats in there?

to test the email i am tryping:
/tool e-mail send to=info@zapotel.co.za subject=“test” body=“test” tls=yes

the email account is with gmail apps:

This is directly from the wiki article. Note the word “must”:

Enter the from address. This must be a valid format and domain. Insure you enter this from address in your address book or friends list in your email reader and provider, or it could be mistaken for spam.

Does it matter if it have to have the < > on ends?

Set your "from" email address to something sensible, but it does not need to be a real email address that exists,

thats also in the wiki?

Only if you use something like this. A Name prior to the email address:
SurferTim <myemail@mydomain.com>
But the domain name must exist. My email server rejects any email with a domain that it cannot resolve.

Ok still not working:

   server: 74.125.91.109:465
      from: "<info@zapotel.co.za>"
  username: "info@zapotel.co.za"
  password: "password"

it says smtp server not ready:

For the server i put in smtp.gmail.com and it dns’d it.

I have a feeling thats the problem?

That username is not a gmail account. Is that how you log in to your gmail account?

This is not from my wiki article, and it is incorrect:

Set your “from” email address to something sensible, but it does not need to be a real email address that exists,

The domain MUST exist and the dns resolves, or almost any email server will reject it.

yea.

if i go to gmail.com

i can login with those.

I am using google apps as a mail server:

but now its giving the error;

SMTP server not ready

Are you using V4.x on this router? Are you adding the “tls=yes” to the end of the test email? If not, the port 465 gmail server will not respond.

4.11

and yes:

[admin@MikroTik] /tool e-mail> /tool e-mail send to=zapotechcomputers@zapotel.co
.za subject="test" body="test" tls=yes

Log Error:

15:16:01 system,e-mail,error Error sending e-mail: abnormal termination (timeout
)

Email code:

[admin@MikroTik] /tool e-mail> print 
    server: 74.125.47.27:465
      from: "<info@zapotel.co.za>"
  username: "info@zapotel.co.za"
  password: "password"

Isnt there like just a open smtp server

that can send any thing:

and then it will just come through to my email from the name i put under from?

I just want it to email.
Does not have to email from gmail. I just want it to email to gmail.

Hi Zapnologica! Try a different port. I just went to the gmail site, and it says if you are using TLS, to use port 587 rather than 465.

I use port 25 to deliver to gmail accounts. If you search the forum, you will find quite a few posts about email from me.

ok i will try both ports:


can i just clarify what ip to use for smtp server?

Here is the link to the setup page at google
http://mail.google.com/support/bin/answer.py?hl=en&answer=13287
It says smtp.gmail.com
It also mentions enabling POP for your account. Try that also.

ADD: I would really like to see this work. I will add it to the wiki when you get it working.
smtp.gmail.com resolves to this ip here: 74.125.65.109

Well done u a star.


Ok for your wiki,

u must not give a ip.
say put in " smtp.gmail.com"
cause mine only worked when i did that,

And it worked on port 587 which makes sense when u read the Google page:


and the from field:
does not work
name@domain does work
anyname works


and enable pop on ur gmail account.

Thanks! But it was you that did the troubleshooting.
I will update the wiki with what you learned from your setup.

One question: where did you use the “smtp.gmail.com”? Was that in “/tool e-mail” or the test email?

wow,

i tried every possibily possible to man.

I was doing this in winbox.

If u put in smtp.gmail.com in smtp server field, it automatically resolves it for you. (where u would usualy put the ip)

OK! That now makes sense! I use the CLI, and it does NOT do the resolution. It requires an ip and port. So each user will need to resolve the local ip for smtp.gmail.com. Good to know.

ADD: The addition has been made to the wiki.
http://wiki.mikrotik.com/wiki/Email_setup/troubleshooting