Per workflow logging on KNIME server

I want to enable per-workflow logging on our KNIME server so that I can retrieve executor logs for individual workflows that have been run as jobs. I have added the following line to the preferences file:

/instance/org.knime.workbench.core/logging.logfile.location=true

This has the desired effect in my local installation – that is, a separate log file gets saved in each workflow’s folder. But I cannot find the workflow-specific logs on the server. I can verify that the preferences file does indeed affect the logging behaviour, as I can control the detail level by adding ‘/instance/org.knime.workbench.core/logging.loglevel.logfile=DEBUG’.

I have located the executor’s log file, but there are no additional files or folders for other workflows there, as the workflow repository is in a different location. Nor are there new log files within the wokflow folders in the repository after I have run the workflows as jobs.

Is the per-workflow logging supposed to work the same way on a server as it does locally? Is there somewhere else I should be looking to find the files?

Hi @AngusVeitch1,

Thanks for reaching out at KNIME forum and sorry for the delayed response.

On KNIME AP once we enable per workflow logging there are folders created inside the workspace folder with logs from each workflow.

However on KNIME server, if you add the following line in your executor.epf file(‘/instance/org.knime.workbench.core/logging.loglevel.logfile=DEBUG’.) then the logs are created inside the jobs folder instead of creating the logs under workflows folder.

So you have to navigate to (workflow_repository-> jobs ->jobs folder) on Knime server to check the workflow specific logs.

Inside the jobs you would see workflow related folder created with knime.log file which contains the logs for the particular workflow.

I hope this help in answering your question.

Regards,
Nagarjun S

Thanks @nagarjun36, I’ve found them where you described. Just a few clarifying questions:

  1. Did you mean to add the line ‘/instance/org.knime.workbench.core/logging.logfile.location=true’ to the preferences file rather than the one ending in ‘logfile=DEBUG’? Or is the debugging level somehow connected with the local logging? (I already had both lines in my preferences, so I haven’t yet seen what happens when the debug level is set to something else.)

  2. Is there any way to retrieve these separate files via an API call, as per the rest of the logs, or must they be retrieved manually? I ask because my initial motivation for creating separate executor logs was to make it easier to match them up to jobs in the server log, which I retrieve via an API call before parsing. After looking closely I see that there is a job ID in most lines of the centralised executor logs anyway, but it would be nice to know if this is an option.

Thanks again.

Hi @AngusVeitch1,

Sorry for the delayed response.

  1. My bad, Yes we need to add the following line /instance/org.knime.workbench.core/logging.logfile.location=true to the preferences file.
  2. Currently it’s not possible to retrieve the logs via REST.

Let us know if there are further clarifications.

Regards,
Nagarjun S

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