Salesforce

For Tridion Sites 9.6 and later, how to enable Publisher debugging?

« Go Back

Information

 
Article TypeSolution Article
Scope/EnvironmentTridion Sites 9.6 and later product versions
Symptoms/Context
- Administrator has requirement to enable Publisher debugging.  
- After below referencing KB article, debug logging can be enabled by starting the Publisher in debug mode from console, but not from the Tridion Sites MMC. 
For Tridion Sites, how to enable Publisher debugging?
- When enabling Publisher debugging via the Tridion Sites MMC (Publisher Settings > Activate logging of publisher Actions > True), the tcmPublisher.log file is not written.
- Product version is Tridion Sites 9.6 or later.
Resolution
As of Tridion Sites 9.6 and later product versions, the CM logging mechanism has changed.  Steps to enable Publisher debug are:

In %TRIDION_HOME%/bin/Nlog.config file, add these sections
1. In targets element
<target xsi:type="File"
name="CMlog"
archiveAboveSize="1000000"
fileName="${environment:TRIDION_HOME}/log/CMLog_${shortdate}.log"
bufferSize="4096"
keepFileOpen="true"
autoFlush="false"
openFileFlushTimeout="10"
layout="${longdate}|${level:uppercase=true}|${processid}|${event-properties:item=component}|${message} ${exception:format=tostring:innerFormat=tostring:maxInnerExceptionLevel=10}"/>
2. In rules element
<logger name="*" minlevel="Debug" writeTo="CMLog" />
3. Restart Publisher.
4. Log file will be written to the %TRIDION_HOME%/log folder, with file format CMLog_2024-11-21.log.

Update filepaths and filename as appropriate.

Output will be something like
----------------- HEADERS -----------------
Accept: application/xml; version=1.0
x-sfnt-sha256: null
x-sfnt-date: 1732224136736
Authorization: SCWS 4477269:0YC0memPT66sKZm3ygV5Mkv2lbwevzv9RUQY1kuMa4M=
********************************************
 
2024-11-21 13:22:16.9742|WARN|2280||Empty repository is used.
Process: TcmPublisher. Entry/Calling assembly name: TcmPublisher. 
2024-11-21 13:22:17.0901|DEBUG|2280||Starting 4 worker threads for PublishQueue. 
2024-11-21 13:22:17.1370|DEBUG|2280||Starting 4 worker threads for DeployQueue. 
2024-11-21 13:22:17.1592|DEBUG|2280||Starting Deployment feedback handler thread. 
2024-11-21 13:22:17.1748|INFO|2280||Tridion Sites Content Manager Publisher service started 
2024-11-21 13:22:17.1905|DEBUG|2280||Deployment feedback handler thread started. 
2024-11-21 13:22:17.2752|DEBUG|2280||Received 0 transport feedbacks. 
2024-11-21 13:22:17.6066|DEBUG|2280||Listening for messages on PublishQueue. 
2024-11-21 13:22:17.6066|DEBUG|2280||Listening for messages on DeployQueue. 
2024-11-21 13:22:17.7603|INFO|10292|Tridion.Licensing|Logon feature TCMCores for user W19R205D:Core4 was unsuccessful 
2024-11-21 13:22:18.5077|DEBUG|2280||Received 0 transport feedbacks

 
Root Cause
Reference
Attachment 1 
Attachment 2 
Attachment 3 
Attachment 4 
Attachment 5 

Powered by