pentaho/pentaho-kettle · error · KettleException

Unable to log the job entries to a database table at the…

Error message

Unable to log the job entries to a database table at the end of the job

What it means

Registered as a jobFinished listener when the job entry log table is defined; if writing job-entry-level log information at job end throws a KettleException, it is re-wrapped with this message. The original database/IO exception is the cause.

Solutions

  1. Inspect the cause chain for the underlying SQL/IO error
  2. Verify the job entry log table schema matches the current Kettle version
  3. Confirm the log DB connection stays alive for the job duration (pool/idle timeouts)
  4. Grant write privileges on the job entry log table
Defensive patterns

Strategy: try-catch

Validate before calling

// before run: verify job entry log table exists
ResultSet rs = conn.getMetaData().getTables(null, null, jobEntryLogTable.getTableName(), null);
if (!rs.next()) throw new IllegalStateException("Job entry log table missing");

Try / catch

try {
  job.run();
} catch (KettleException e) {
  if (e.getMessage().contains("job entries to a database table")) {
    log.error("Job-entry log write failed at job end", e.getCause());
    // job itself may have succeeded; check job result separately
  }
}

Prevention

When it happens

Trigger: At job completion, writeJobEntryLogInformation() fails while inserting job entry log rows into the defined job entry log table.

Common situations: Job entry log table missing or schema outdated; DB connection dropped during long jobs; permissions revoked mid-run; disk full on the log database.

Related errors


AI-assisted analysis of pentaho/pentaho-kettle@f3058517a1 (2026-09-13). Data as JSON: /api/errors/3762c05f3f5143ee. Report an issue: GitHub.

Appendix: source

Thrown at engine/src/main/java/org/pentaho/di/job/Job.java:1123

      } catch ( KettleDatabaseException dbe ) {
        addErrors( 1 ); // This is even before actual execution
        throw new KettleJobException( BaseMessages.getString( PKG, "Job.Log.UnableToProcessLoggingStart", ""
            + tableName ), dbe );
      } finally {
        ldb.close();
      }
    }

    // If we need to write out the job entry logging information, do so at the end of the job:
    //
    JobEntryLogTable jobEntryLogTable = jobMeta.getJobEntryLogTable();
    if ( jobEntryLogTable.isDefined() ) {
      addJobListener( new JobAdapter() {
        @Override public void jobFinished( Job job ) throws KettleException {
          try {
            writeJobEntryLogInformation();
          } catch ( KettleException e ) {
            throw new KettleException( BaseMessages.getString( PKG,
                "Job.Exception.UnableToPerformJobEntryLoggingAtJobEnd" ), e );
          }
        }
      } );
    }

    // If we need to write the log channel hierarchy and lineage information,
    // add a listener for that too...
    //
    ChannelLogTable channelLogTable = jobMeta.getChannelLogTable();
    if ( channelLogTable.isDefined() ) {
      addJobListener( new JobAdapter() {

        @Override public void jobFinished( Job job ) throws KettleException {
          try {
            writeLogChannelInformation();
          } catch ( KettleException e ) {
            throw new KettleException( BaseMessages.getString( PKG, "Job.Exception.UnableToPerformLoggingAtTransEnd" ),

View on GitHub (pinned to f3058517a1)