emailpentahokettledata-integration

Send Email with pentaho PDI


I want to sent an email using PDI. I created an job and added the 'Mail' element. There are my parameters.

Server smtp.gmail.com
Port: 587
Use Authentication
User : mygmailusername
Pass : mygmailpass
Secure Con Type : TLS

When I run the job I get the error :Problem while sending message : javax.mail.AuthenticationFailedException

When I changed the port to 465 gmail rejected the message and sent an email to mygmailusername indicating unauthorised login attempt.

However I have changed the port for my BI server to 9090. I dont know if this is also a reason. Am assuming PDI is to communicate somehow with BI server if it is the BI server which is to send the email. How do I get this to work please ?


Solution

  • I was finally able to get this to work. I changed my config to :

    Server smtp.gmail.com
    Port: 465
    Use Authentication
    User : mygmailusername
    Pass : mygmailpass
    Secure Con Type : SSL
    

    Then I run the PDI job and this caused google to send a Suspicious sign-in prevented email to mygmailusername account. I opened the email and clicked on the http://support.google.com/mail?p=client_login. at the bottom of the email. This took me to a troubleshooting page.

    Under the section Now, please follow the steps below to resolve the problem: I clicked on the link at the third option http://www.google.com/accounts/DisplayUnlockCaptcha and then clicked continue. Now it works perfectly now.