Question & Answer
Question
Since the log4j2 fix applied to Modeler environments to mitigate the log4j vulnerability issues, the configuration file for Modeler logs changed from log4j.properties to log4j2.xml.
In the old log4j version, setting a parameter ${PROCESS_ID} in log4j.properties enabled Modeler to fetch a process ID and added it to the file name of trace log. However, the same usage of ${PROCESS_ID} does not work for a new log4j2 version with log4j2.xml configuration.
What is the correct usage for log4j2.xml configuration?
For instance, the parameter in the old log4j (log4j.properties) was set by default and worked.
For instance, the parameter in the old log4j (log4j.properties) was set by default and worked.
log4j.properties
log4j.appender.TraceLog.File=${ALLUSERSPROFILE}/IBM/SPSS/Modeler Batch/<version>/log/batch_tracing_${PROCESS_ID}.log
However, in the log4j2.xml it didn't work even if the same parameter was used.
log4j2.xml
<RollingFile name="traceLog" fileName="${LOG_ROOT}/batch_tracing_${PROCESS_ID}.log"
filePattern="${LOG_ROOT}/client_tracing-%d{yyyy-MM-dd}-%i.log" >
[{"Type":"MASTER","Line of Business":{"code":"LOB76","label":"Data Platform"},"Business Unit":{"code":"BU048","label":"IBM Software"},"Product":{"code":"SS3RA7","label":"IBM SPSS Modeler"},"ARM Category":[{"code":"a8m0z0000000Ca2AAE","label":"AAJapanese-\u003EModeler"}],"ARM Case Number":"","Platform":[{"code":"PF025","label":"Platform Independent"}],"Version":"18.2.1;18.2.2;18.3.0"}]
Log InLog in to view more of this document
This document has the abstract of a technical article that is available to authorized users once you have logged on. Please use Log in button above to access the full document. After log in, if you do not have the right authorization for this document, there will be instructions on what to do next.
Was this topic helpful?
Document Information
Modified date:
05 April 2022
UID
ibm16569135