Hello,
Thanks for asking – this is actually a pretty neat topic. The preferences files are an easy way to set up an executor so that it always has an environment configured automatically instead of having to specify it every time.
If you already have AP configured the way you like it, but now you’re adding a KNIME server to the mix and need it to know how to find/configure something (like a database driver, or a Python environment), then you can do like the documentation states:
{
Start KNIME AP (with an arbitrary workspace).
Set all preferences via “File” → “Preferences”) and export the preferences via “File” → “Export Preferences”.
}
This will create a text file with all of AP’s preferences. Obviously, there are a lot of them that you won’t need on the executor, but it’s a good way to get the right format for the few that you will need.
Note that any references in this client-side file will pertain to the directory structure on your client computer; when you make changes to the server side preferences file, make sure you adjust any directory paths so that it points to the proper server-side directory locations.
Where it says something like
{
Open the exported preferences and insert the relevant lines into <server-repository>/config/client-profiles/executor.epf
}
So above is talking about what i mentioned above - the relevant lines are whichever ones you need - you don’t need everything.
the ‘<server-repository>’ portion should be replaced with the directory where you have placed the KNIME server’s workflow repository.
For example, on my test environment server here, my server repository is in /opt/knime/knime_server/workflow_repository.
So I would go to /opt/knime/knime_server/workflow_repository/config/client-profiles and look there.
On 4.11, you should see two subdirectories: default and executor.
Next, it says:
{
We have bundled a file called executor.epf into the <server-repository>/config/client-profiles/executor folder.
}
So if you look in <server-repository>/config/client-profiles, you should see a subdirectory named ‘executor’.
If you go into the executor directory, you will see an executor.epf file.
Note that the file MUST start with:
\!/=
Following that, you can have whatever preferences configurations are needed.
Edit this file with whatever changes you wanted to see applied.
Save and exit, obviously.
Next, to make sure that the executor loads these preference files when it starts, you need to make sure your knime.ini file is set up right.
If you installed the executor as part of the server install (and since you said it was an AWS image, it probably was automatically), the necessary -profileLocation and -profileList lines are probably already in there, but you can check it to make sure.
If they are not there, just place the necessary lines from documentation BEFORE the line that says ‘-vmargs’.
So - you exported the AP preferences;
you snagged the few configuration lines you need to paste on the server;
you found the executor.epf file and placed the lines into it;
you made sure that if they need to be adjusted to point to the right locations on the SERVER, that it is done;
and you made sure the knime.ini is configured correctly to load the preferences each time.
Restart the executor to pick up the changes, and you should be good to go.
Let me know if you have any other questions!
Regards,
Nickolaus