title: WCF FileNotFoundException
body: <p>I am running WCF inside a Windows service. The service starts and runs fine, and I can access the service and call the WCF methods from the same machine, (using LocalHost as wcf server name),  but after a recent change, when I try to call one of the WCF methods from another workstation I am getting a System.IO.FileNotFoundException and WCF Service crashes.  Before that it was working fine.  </p>
  
  <p>The error in the Application log on wcf server is as shown below: There is no indication as to what file it is unable to load.</p>
  
  
  
  <pre><code>&lt;Event xmlns="http://schemas.microsoft.com/win/2004/08/events/event"&gt;
  - &lt;System&gt;
    &lt;Provider Name=".NET Runtime" /&gt; 
    &lt;EventID Qualifiers="0"&gt;1026&lt;/EventID&gt; 
    &lt;Level&gt;2&lt;/Level&gt; 
    &lt;Task&gt;0&lt;/Task&gt; 
    &lt;Keywords&gt;0x80000000000000&lt;/Keywords&gt; 
    &lt;TimeCreated SystemTime="2014-12-29T18:33:27.000Z" /&gt; 
    &lt;EventRecordID&gt;3292&lt;/EventRecordID&gt; 
    &lt;Channel&gt;Application&lt;/Channel&gt; 
    &lt;Computer&gt;LASAPPTEST.rose.portland.local&lt;/Computer&gt; 
    &lt;Security /&gt; 
    &lt;/System&gt;
  - &lt;EventData&gt;
    &lt;Data&gt;Application: CoP.Enterprise.ServiceHost.exe Framework Version: v4.0.30319 Description: The process was terminated due to an unhandled exception. Exception Info:   
  System.IO.FileNotFoundException Stack: at CoP.LAS.LASServiceHostProcessManager.StartProcess() at  
  System.Threading.ExecutionContext.RunInternal(System.Threading.ExecutionContext,  
  System.Threading.ContextCallback, System.Object, Boolean) at System.Threading.ExecutionContext.Run  
  (System.Threading.ExecutionContext, System.Threading.ContextCallback, System.Object, Boolean) at   
  System.Threading.ExecutionContext.Run(System.Threading.ExecutionContext,   
  System.Threading.ContextCallback, System.Object) at System.Threading.ThreadHelper.ThreadStart()  
  &lt;/Data&gt; 
    &lt;/EventData&gt;
    &lt;/Event&gt;
  </code></pre>
  
  <p>ideas? is there any way to debug this and figure out where to go next? What file is it trying to load? </p>
  
  <p>With hint from @seymour, FOUND THE ANSWER: Use the Wcf Trace Log capability 
  (add following to web.config/app.config )   </p>
  
  <pre><code>&lt;system.diagnostics&gt;
        &lt;sources&gt;
              &lt;source name="System.ServiceModel" 
                      switchValue="Information, ActivityTracing"
                      propagateActivity="true"&gt;
              &lt;listeners&gt;
                 &lt;add name="traceListener" 
                     type="System.Diagnostics.XmlWriterTraceListener" 
                     initializeData= "C:\LASServices\LAS\Logs\Traces.svclog" /&gt;
              &lt;/listeners&gt;
           &lt;/source&gt;
        &lt;/sources&gt;
   &lt;/system.diagnostics&gt;
  </code></pre>
  
  <p>and use Wcf Trace Log Viewer (SvcTraceViewer.exe), to read the details for the FileNotFoundException.</p>