Search FAQs
Enabling WCF Tracing for WebRealTime Services in Power Monitoring Expert
Issue
Looking to enable WCF [Windows Communication Foundation] Tracing for WebRealTime Services in Power Monitoring Expert
Product Line
StruxureWare Power Monitoring Expert
Environment
Power Monitoring Expert 7.2.x
Power Monitoring Expert 8.x
Internet Explorer 11
Cause
Enabling the WCF Tracing for WebRealTime Service in PME allows the user to collect and analyze diagnostic data from PME web applications in order to resolve technical issues.
Resolution
*Warning: Take backups of any files prior to modifying them. Ensure the backups are in a location that will not be overwritten (i.e. the Desktop).
Enable WCF Tracing
1. Stop the Application Modules CoreServicesHost, DataServicesHost, andProviderEngineHost services.
2. Make a backup copy of the Web.config file for the WebRealTime service, which you can find at the following location: <PME installation folder>\system\WebServices
3. Add the following section to the Web.config file:
<system.diagnostics>
<sources>
<source name="System.ServiceModel"
switchValue="Information, ActivityTracing"
propagateActivity="true">
<listeners>
<add name="traceListener"
type="System.Diagnostics.XmlWriterTraceListener"
initializeData= "C:\Log\WebRealTimeTrace.svclog" />
</listeners>
</source>
</sources>
</system.diagnostics>
NOTE: You can change where the trace file gets saved to on the hard drive by changing the value for initializeData.
4. Enable the IncludeExceptionDetailInFaults by referring to the steps below where minor modification will be performed to the 'Web.config' file for the Web real-time service:
6. Start the ApplicationModules services previously stopped in step 1.
Start a network trace in Internet Explorer by following the instructions below:
1. Log into Web Applications and navigate to the Tables tab.
2. Press the F12 key and a new section will appear at the bottom of the screen as shown below.
![](https://ckm-content.se.com/ckmContent/servlet/servlet.ImageServer?id=0151H000008zqdKQAQ&oid=00DA0000000abSm)
3. Click the "Start capturing" button and diagnostic information will appear in the trace at the bottom of the screen:
![](https://ckm-content.se.com/ckmContent/servlet/servlet.ImageServer?id=0151H000008zqFfQAI&oid=00DA0000000abSm)
To stop tracing, click the "Stop capturing" button.
To stop the tracing, follow the steps below:
1. Stop the three ApplicationModules services
2. Restore the backup copy of the Web.config file for the WebRealTime service which was backed up earlier, to the following location: <PME installation folder>\system\WebServices
-OR-
<sources>
<source name="System.ServiceModel"
switchValue="Information, ActivityTracing"
propagateActivity="true">
<listeners>
<add name="traceListener"
type="System.Diagnostics.XmlWriterTraceListener"
initializeData= "C:\Log\WebRealTimeTrace.svclog" />
</listeners>
</source>
</sources>
</system.diagnostics>
<serviceBehaviors>
<behavior name="">
<serviceMetadata httpGetEnabled="true" />
<serviceDebug includeExceptionDetailInFaults="false" />
</behavior>
<behavior name="metadata">
<serviceMetadata httpsGetEnabled="true" httpGetEnabled="true" />
</behavior>
</serviceBehaviors>
</behaviors>
Looking to enable WCF [Windows Communication Foundation] Tracing for WebRealTime Services in Power Monitoring Expert
Product Line
StruxureWare Power Monitoring Expert
Environment
Power Monitoring Expert 7.2.x
Power Monitoring Expert 8.x
Internet Explorer 11
Cause
Enabling the WCF Tracing for WebRealTime Service in PME allows the user to collect and analyze diagnostic data from PME web applications in order to resolve technical issues.
Resolution
*Warning: Take backups of any files prior to modifying them. Ensure the backups are in a location that will not be overwritten (i.e. the Desktop).
Enable WCF Tracing
1. Stop the Application Modules CoreServicesHost, DataServicesHost, andProviderEngineHost services.
2. Make a backup copy of the Web.config file for the WebRealTime service, which you can find at the following location: <PME installation folder>\system\WebServices
3. Add the following section to the Web.config file:
<system.diagnostics>
<sources>
<source name="System.ServiceModel"
switchValue="Information, ActivityTracing"
propagateActivity="true">
<listeners>
<add name="traceListener"
type="System.Diagnostics.XmlWriterTraceListener"
initializeData= "C:\Log\WebRealTimeTrace.svclog" />
</listeners>
</source>
</sources>
</system.diagnostics>
NOTE: You can change where the trace file gets saved to on the hard drive by changing the value for initializeData.
4. Enable the IncludeExceptionDetailInFaults by referring to the steps below where minor modification will be performed to the 'Web.config' file for the Web real-time service:
- Make a backup copy of the Web.config file for the WebRealTime service, which you can find at the following location: <PME installation folder>\system\WebServices
E.g. C:\Program Files (x86)\Schneider Electric\Power Monitoring Expert\system\WebServices\Web.config
- Perform another modification to the Web.config file in order to include detailed exception information:
Find the <behaviors> section underneath <system.serviceModel>
- Change the includeExceptionDetailInFaults value to "true" as in the following (changes are underined):
- <behaviors>
<serviceBehaviors>
<behavior name="">
<serviceMetadata httpGetEnabled="true" />
<serviceDebug includeExceptionDetailInFaults="true" />
</behavior>
<behavior name="metadata">
<serviceMetadata httpsGetEnabled="true" httpGetEnabled="true" />
</behavior>
</serviceBehaviors>
</behaviors>
- <behaviors>
6. Start the ApplicationModules services previously stopped in step 1.
Start a network trace in Internet Explorer by following the instructions below:
1. Log into Web Applications and navigate to the Tables tab.
2. Press the F12 key and a new section will appear at the bottom of the screen as shown below.
3. Click the "Start capturing" button and diagnostic information will appear in the trace at the bottom of the screen:
To stop tracing, click the "Stop capturing" button.
To stop the tracing, follow the steps below:
1. Stop the three ApplicationModules services
2. Restore the backup copy of the Web.config file for the WebRealTime service which was backed up earlier, to the following location: <PME installation folder>\system\WebServices
-OR-
- Remove the following section to the Web.config file:
<sources>
<source name="System.ServiceModel"
switchValue="Information, ActivityTracing"
propagateActivity="true">
<listeners>
<add name="traceListener"
type="System.Diagnostics.XmlWriterTraceListener"
initializeData= "C:\Log\WebRealTimeTrace.svclog" />
</listeners>
</source>
</sources>
</system.diagnostics>
- Modify the includeExceptionDetailInFaults value to "true" as in the following (changes are underlined):
<serviceBehaviors>
<behavior name="">
<serviceMetadata httpGetEnabled="true" />
<serviceDebug includeExceptionDetailInFaults="false" />
</behavior>
<behavior name="metadata">
<serviceMetadata httpsGetEnabled="true" httpGetEnabled="true" />
</behavior>
</serviceBehaviors>
</behaviors>
Released for:Schneider Electric USA
Explore more
Range:
Explore more
Range: