0

In pentaho [PDI(Kettle)] 5.1 version after scheduling job i have set email to the transformation in job if job fails email has send to the mail where the error occured.If i want to see detailed log information what happening during scheduling. How to set that please help me in this issue

E:\PENTAHO\data-integration\Kitchen.bat /file:E:\PENTAHO\rml_app_profile.kjb ./rml_app_profile.kjb.log

SRI
  • 531
  • 1
  • 4
  • 11

1 Answers1

1

There are two ways of getting the logging level:

  1. Using the level argument:: /level:Detailed like:

    kitchen.bat /file:E:\someKettleJob.kjb /level:Detailed

  2. You can use the Kettle logging system itself to get the detailed logging (in the Transformation settings). Check the image below

enter image description here

In your case, you can modify your code as below:

E:\PENTAHO\data-integration\Kitchen.bat /file:E:\PENTAHO\rml_app_profile.kjb /level:Detailed >> E:\rml_app_profile.log

Hope it helps :)

Rishu Shrivastava
  • 3,745
  • 1
  • 20
  • 41
  • For above it is attaching the log information in mail. With out attachment if i want to get log information to my mail.Is any another way. – SRI Nov 24 '14 at 08:50
  • One possible way is to schedule a different Job (once the master job is over), which would read all the log files (error ones) and do a substring of the error section (if there is any error). Send this string section as a Mail Body to your mail address. You can even do the same using either shell or bat scripts. – Rishu Shrivastava Nov 24 '14 at 09:23
  • Can u explain me it more detail please – SRI Nov 24 '14 at 09:37
  • Read all the log files which your Job is generating. Search for String "Error". If you find any Error, do a string of some desired length (may be of some 100 characters). Next assign a variable to this result and use the Mail body step to send it in a mail comment section. If you need, i can share some sample code :) – Rishu Shrivastava Nov 24 '14 at 09:57
  • I have done a sample code. Its in the link : https://drive.google.com/open?id=0B6NvpRn8XxcFem9UcGRvWkNjMk0&authuser=0 .I have coded for a single log file. Start from the "ErrorLogCheckerMasterJob.kjb". Please let me know if you are not able to view the code. – Rishu Shrivastava Nov 24 '14 at 17:17
  • @Rishu your ktr read this file ${Internal.Transformation.Filename.Directory}/log.log Is a defult file created by pentaho or another ktr must create it? – JRichardsz Jun 25 '20 at 23:07
  • @JRichardsz it is not created by ktr and is a user specific log file name – Rishu Shrivastava Jun 26 '20 at 09:24