Smtp authentication error

I am trying to send emails

email {
port => 587
address => "smtp.gmail.com"
username => "@gmail.com"
password => "
"
authentication => "plain"
use_tls => true
from => "
@gmail.com"
subject => "logstash alert"
to => "
*@gmail.com"
via => "smtp"
body => "here is the event line that occured"
debug => true
}

{:timestamp=>"2017-03-22T16:27:28.409000-0400", :message=>"Something happen while delivering an email", :exception=>#<Net::SMTPAuthenticationError: 454 4.7.0 Too many login attempts, please try again later. b126sm1719947qka.26 - gsmtp

, :level=>:error}

As the error message indicates Gmail thinks you have provided bad credentials too many times so your account has been blacklisted for a while.

I have changed my password , restarted logstash and now i am getting this error, not sure what could be this issue be? any suggestions would be helpful.
{:timestamp=>"2017-03-23T10:17:47.235000-0400", :message=>"Something happen while delivering an email", :exception=>#<EOFError: End of file reached>, :level=>:error}

Please format log snippets as preformatted text. I want to know what comes after ":exception=>#".

I am using vi editor and so i am not sure on how i should change the log snippets as preformatted text.
Also here is my configuration
input {
file {
path => "/var/log/logstash/logstash.log"
start_position => beginning
}
}
output {
file {
path => "/var/log/logstash/iis-%{+YYYY-MM-dd}" }
email {
port => 587
address => "smtp.gmail.com"
username => "###@gmail.com"
password => "@@@@"
authentication => "plain"
use_tls => true
from => "###@gmail.com"
subject => "logstash alert"
to => "###@gmail.com"
via => "smtp"
body => "here is the event line that occured"
debug => true
}
}

This has nothing to do with your use of vim. Use the </> toolbar button in the discuss.elastic.co interface above the text box where you, presumably, are writing your posts. If you prefer using Markdown directly that's fine too.

Again, I want to know what comes after ":exception=>#".

    {:timestamp=>"2017-03-23T14:00:03.784000-0400", :message=>"Something happen while delivering an email", :exception=>#<EOFError: End of file reached>, :level=>:error}

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