kettlepentaho-data-integrationpdi

My pentaho ETL jobs(.kjb) files are not working after upgrading the pentaho data integeration from 5.3 to 9.2


I used to run the Pentaho ETL jobs in PDI community edition 5.3 with the kitchen like below

./kitchen.sh -rep=repo1 -file=/var/lib/jenkins/project/path/etl/Job1.kjb

after upgrading the PDI community edition to 9.2 the same ETL jobs are showing the below errors

**Error Log:**

2022/03/02 05:00:28 - Job1 - Start of job execution
2022/03/02 05:00:28 - Job1 - Starting entry [sub_job_1]
2022/03/02 05:00:28 - sub_job_1 - ERROR (version 9.2.0.0-290, build 9.2.0.0-290 from 2021-06-02 06.36.08 by buildguy) : Error running job entry 'job' :
2022/03/02 05:00:28 - sub_job_1 - ERROR (version 9.2.0.0-290, build 9.2.0.0-290 from 2021-06-02 06.36.08 by buildguy) : org.pentaho.di.core.exception.KettleException:
**2022/03/02 05:00:28 - sub_job_1 - Unexpected error during job metadata load
2022/03/02 05:00:28 - sub_job_1 -
2022/03/02 05:00:28 - sub_job_1 - Unable to load the job from XML file [/var/lib/jenkins/project/path/etl/sub_job_1.kjb.kjb]**
2022/03/02 05:00:28 - sub_job_1 -
2022/03/02 05:00:28 - sub_job_1 - File [file:///var/lib/jenkins/project/path/etl/sub_job_1.kjb.kjb] does not exists.**
2022/03/02 05:00:28 - sub_job_1 -
2022/03/02 05:00:28 - sub_job_1 -
2022/03/02 05:00:28 - sub_job_1 -
2022/03/02 05:00:28 - sub_job_1 - at org.pentaho.di.job.entries.job.JobEntryJob.getJobMeta(JobEntryJob.java:1467)
2022/03/02 05:00:28 - sub_job_1 - at org.pentaho.di.job.entries.job.JobEntryJob.getJobMeta(JobEntryJob.java:1385)
2022/03/02 05:00:28 - sub_job_1 - at org.pentaho.di.job.entries.job.JobEntryJob.execute(JobEntryJob.java:695)
2022/03/02 05:00:28 - sub_job_1 - at org.pentaho.di.job.Job.execute(Job.java:693)
2022/03/02 05:00:28 - sub_job_1 - at org.pentaho.di.job.Job.execute(Job.java:834)
2022/03/02 05:00:28 - sub_job_1 - at org.pentaho.di.job.Job.execute(Job.java:503)
2022/03/02 05:00:28 - sub_job_1 - at org.pentaho.di.job.Job.run(Job.java:389)
2022/03/02 05:00:28 - sub_job_1 - Caused by: org.pentaho.di.core.exception.KettleXMLException:
2022/03/02 05:00:28 - sub_job_1 - Unable to load the job from XML file [/var/lib/jenkins/project/path/etl/sub_job_1.kjb.kjb]

the error is its additionaly adding the .kjb extension at end of each job


Solution

  • Switching from -file to -job in the kitchen command input and removing the .kjb extension in the job file solved the issue.

    Before:

    ./kitchen.sh -rep=repo1 -file=/var/lib/jenkins/project/path/etl/Job1.kjb
    

    After:

    ./kitchen.sh -rep=repo1 -job=/var/lib/jenkins/project/path/etl/Job1