From: Adrian Tarjoianu on
Hi,

I have a WCF webservice hosted in IIS 7. The OS is Windows Server 2008
Standard.

The binding of this web service is netTcp.

This webservice works fine for 20-30 minutes, but after that I receive this
error message:
"Server Application Unavailable
The web application you are attempting to access on this web server is
currently unavailable. Please hit the "Refresh" button in your web browser
to retry your request.

Administrator Note: An error message detailing the cause of this specific
request failure can be found in the application event log of the web server.
Please review this log entry to discover what caused this error to occur.
"

If I recycle the application pool everything comes back to normal.


In the event viewer I see the below exception message:
"Failed to execute request because the App-Domain could not be created.
Error: 0x8000ffff Catastrophic failure "

Help pls.

Thank you,
Adrian
From: "Steven Cheng" on
Hi Adrian,

Based on your description, the WCF service unavailable error is likely due
to the IIS applicaiton pool(of your WCF service application virtual
directory) has encounter some unhandled exception(and crashed). And it
seems the windows eventlog doesn't provide any detailed error info and
cause.

Is your service using any special component or code logic that may raise
some unhandled exception(like COM interop or unamanged API). Generally, we
can first start troubleshooting from code review level before try some low
level debugging approahes. Also, if the error is WCF specific, turn on the
WCF event trace might also help on capturing underlying error info:

#Configuring Tracing
http://msdn.microsoft.com/en-us/library/ms733025.aspx

Sincerely,

Steven Cheng

Microsoft MSDN Online Support Lead


Delighting our customers is our #1 priority. We welcome your comments and
suggestions about how we can improve the support we provide to you. Please
feel free to let my manager know what you think of the level of service
provided. You can send feedback directly to my manager at:
msdnmg(a)microsoft.com.

--------------------
>From: =?Utf-8?B?QWRyaWFuIFRhcmpvaWFudQ==?= <tarjoadi(a)nospam.nospam>
>Subject: hosting WCF service - netTcp binding - Server Application Unavaila
>Date: Fri, 30 Apr 2010 14:25:01 -0700

>Hi,
>
>I have a WCF webservice hosted in IIS 7. The OS is Windows Server 2008
>Standard.
>
>The binding of this web service is netTcp.
>
>This webservice works fine for 20-30 minutes, but after that I receive
this
>error message:
>"Server Application Unavailable
>The web application you are attempting to access on this web server is
>currently unavailable. Please hit the "Refresh" button in your web browser
>to retry your request.
>
>Administrator Note: An error message detailing the cause of this specific
>request failure can be found in the application event log of the web
server.
>Please review this log entry to discover what caused this error to occur.
>"
>
>If I recycle the application pool everything comes back to normal.
>
>
>In the event viewer I see the below exception message:
>"Failed to execute request because the App-Domain could not be created.
>Error: 0x8000ffff Catastrophic failure "
>
>Help pls.
>
>Thank you,
>Adrian
>

From: Adrian Tarjoianu on
Hi Steven,

I switched back the WCF service to use http prototcol.
Everything is fine now.

The problem is only when we configure it to use net.tcp protocol.

Could you pls tell me what other data you need in order to troubleshoot this
issue?

Thank you,
Adrian

""Steven Cheng"" <stcheng(a)online.microsoft.com> wrote in message
news:JrNONZq6KHA.2348(a)TK2MSFTNGHUB02.phx.gbl...
> Hi Adrian,
>
> Based on your description, the WCF service unavailable error is likely due
> to the IIS applicaiton pool(of your WCF service application virtual
> directory) has encounter some unhandled exception(and crashed). And it
> seems the windows eventlog doesn't provide any detailed error info and
> cause.
>
> Is your service using any special component or code logic that may raise
> some unhandled exception(like COM interop or unamanged API). Generally, we
> can first start troubleshooting from code review level before try some low
> level debugging approahes. Also, if the error is WCF specific, turn on the
> WCF event trace might also help on capturing underlying error info:
>
> #Configuring Tracing
> http://msdn.microsoft.com/en-us/library/ms733025.aspx
>
> Sincerely,
>
> Steven Cheng
>
> Microsoft MSDN Online Support Lead
>
>
> Delighting our customers is our #1 priority. We welcome your comments and
> suggestions about how we can improve the support we provide to you. Please
> feel free to let my manager know what you think of the level of service
> provided. You can send feedback directly to my manager at:
> msdnmg(a)microsoft.com.
>
> --------------------
>>From: =?Utf-8?B?QWRyaWFuIFRhcmpvaWFudQ==?= <tarjoadi(a)nospam.nospam>
>>Subject: hosting WCF service - netTcp binding - Server Application
>>Unavaila
>>Date: Fri, 30 Apr 2010 14:25:01 -0700
>
>>Hi,
>>
>>I have a WCF webservice hosted in IIS 7. The OS is Windows Server 2008
>>Standard.
>>
>>The binding of this web service is netTcp.
>>
>>This webservice works fine for 20-30 minutes, but after that I receive
> this
>>error message:
>>"Server Application Unavailable
>>The web application you are attempting to access on this web server is
>>currently unavailable. Please hit the "Refresh" button in your web browser
>>to retry your request.
>>
>>Administrator Note: An error message detailing the cause of this specific
>>request failure can be found in the application event log of the web
> server.
>>Please review this log entry to discover what caused this error to occur.
>>"
>>
>>If I recycle the application pool everything comes back to normal.
>>
>>
>>In the event viewer I see the below exception message:
>>"Failed to execute request because the App-Domain could not be created.
>>Error: 0x8000ffff Catastrophic failure "
>>
>>Help pls.
>>
>>Thank you,
>>Adrian
>>
>

From: "Steven Cheng" on
Hi Adrian,

Thanks for reply Adrian.
So the problem is specific to netTcpBinding scenario, I think it still
possible that the service process encounter some exception or hang
situation which makes the service unavailable to client.

For WCF service, have you tried turned on service tracing at the
service-side to see whether you can get any error information? The
following reference shows how to configure WCF tracing.

#Configuring Tracing
http://msdn.microsoft.com/en-us/library/ms733025.aspx?PHPSESSID=50d760d9b862
023e2c39e99ef0c83e42

or you can also use the service configuration editor provided in windows
sdk to enable tracing:

#Configuration Editor Tool (SvcConfigEditor.exe)
http://msdn.microsoft.com/en-us/library/ms732009.aspx

Sincerely,

Steven Cheng

Microsoft MSDN Online Support Lead


Delighting our customers is our #1 priority. We welcome your comments and
suggestions about how we can improve the support we provide to you. Please
feel free to let my manager know what you think of the level of service
provided. You can send feedback directly to my manager at:
msdnmg(a)microsoft.com.



--------------------
>From: "Adrian Tarjoianu" <adrian(a)usoffice.fareportal.com>
>Subject: Re: hosting WCF service - netTcp binding - Server Application
Unavaila
>Date: Wed, 12 May 2010 09:03:15 -0400

>
>Hi Steven,
>
>I switched back the WCF service to use http prototcol.
>Everything is fine now.
>
>The problem is only when we configure it to use net.tcp protocol.
>
>Could you pls tell me what other data you need in order to troubleshoot
this
>issue?
>
>Thank you,
>Adrian
>
>""Steven Cheng"" <stcheng(a)online.microsoft.com> wrote in message
>news:JrNONZq6KHA.2348(a)TK2MSFTNGHUB02.phx.gbl...
>> Hi Adrian,
>>
>> Based on your description, the WCF service unavailable error is likely
due
>> to the IIS applicaiton pool(of your WCF service application virtual
>> directory) has encounter some unhandled exception(and crashed). And it
>> seems the windows eventlog doesn't provide any detailed error info and
>> cause.
>>
>> Is your service using any special component or code logic that may raise
>> some unhandled exception(like COM interop or unamanged API). Generally,
we
>> can first start troubleshooting from code review level before try some
low
>> level debugging approahes. Also, if the error is WCF specific, turn on
the
>> WCF event trace might also help on capturing underlying error info:
>>
>> #Configuring Tracing
>> http://msdn.microsoft.com/en-us/library/ms733025.aspx
>>
>> Sincerely,
>>
>> Steven Cheng
>>
>> Microsoft MSDN Online Support Lead
>>
>>

From: Adrian Tarjoianu on
Hi Steven,

I have enabled the tracing but the issue is not reproducing anymore. Strange
enough.

I have one more question:
I have converted a web service with WCF and I have configured it to work on
net.tcp, but it takes longer to transfer the same amount of data.
Before it took it around 10 sec and now it takes it around 17.

Here is the web.config file content. Could you please tell me what should I
disable/enable in order the data to be transfered faster?

<?xml version="1.0" encoding="UTF-8"?>
<!--
Note: As an alternative to hand editing this file you can use the
web admin tool to configure settings for your application. Use
the Website->Asp.Net Configuration option in Visual Studio.
A full list of settings and comments can be found in
machine.config.comments usually located in
\Windows\Microsoft.Net\Framework\v2.x\Config
-->
<configuration>
<configSections>
<sectionGroup name="system.web.extensions"
type="System.Web.Configuration.SystemWebExtensionsSectionGroup,
System.Web.Extensions, Version=3.5.0.0, Culture=neutral,
PublicKeyToken=31BF3856AD364E35">
<sectionGroup name="scripting"
type="System.Web.Configuration.ScriptingSectionGroup, System.Web.Extensions,
Version=3.5.0.0, Culture=neutral, PublicKeyToken=31BF3856AD364E35">
<section name="scriptResourceHandler"
type="System.Web.Configuration.ScriptingScriptResourceHandlerSection,
System.Web.Extensions, Version=3.5.0.0, Culture=neutral,
PublicKeyToken=31BF3856AD364E35" requirePermission="false"
allowDefinition="MachineToApplication" />
<sectionGroup name="webServices"
type="System.Web.Configuration.ScriptingWebServicesSectionGroup,
System.Web.Extensions, Version=3.5.0.0, Culture=neutral,
PublicKeyToken=31BF3856AD364E35">
<section name="jsonSerialization"
type="System.Web.Configuration.ScriptingJsonSerializationSection,
System.Web.Extensions, Version=3.5.0.0, Culture=neutral,
PublicKeyToken=31BF3856AD364E35" requirePermission="false"
allowDefinition="Everywhere" />
<section name="profileService"
type="System.Web.Configuration.ScriptingProfileServiceSection,
System.Web.Extensions, Version=3.5.0.0, Culture=neutral,
PublicKeyToken=31BF3856AD364E35" requirePermission="false"
allowDefinition="MachineToApplication" />
<section name="authenticationService"
type="System.Web.Configuration.ScriptingAuthenticationServiceSection,
System.Web.Extensions, Version=3.5.0.0, Culture=neutral,
PublicKeyToken=31BF3856AD364E35" requirePermission="false"
allowDefinition="MachineToApplication" />
<section name="roleService"
type="System.Web.Configuration.ScriptingRoleServiceSection,
System.Web.Extensions, Version=3.5.0.0, Culture=neutral,
PublicKeyToken=31BF3856AD364E35" requirePermission="false"
allowDefinition="MachineToApplication" />
</sectionGroup>
</sectionGroup>
</sectionGroup>
</configSections>
<system.diagnostics>
<sources>
<source name="System.ServiceModel" switchValue="Off,ActivityTracing"
propagateActivity="true">
<listeners>
<add type="System.Diagnostics.DefaultTraceListener" name="Default">
<filter type="" />
</add>
<add name="ServiceModelTraceListener">
<filter type="" />
</add>
</listeners>
</source>
</sources>
<sharedListeners>
<add initializeData="C:\wwwroot\FP-WebServices\Operations
WSs\PrecompiledWCF\Portals\web_tracelog.svclog"
type="System.Diagnostics.XmlWriterTraceListener, System,
Version=2.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089"
name="ServiceModelTraceListener" traceOutputOptions="Timestamp">
<filter type="" />
</add>
</sharedListeners>
</system.diagnostics>
<appSettings>
<add key="PortalId" value="92" />
<add key="ExceptionRecepient" value="XXXX" />
<add key="SmtpServer" value="XXXX" />
<add key="AdminAccessIPList" value="XXXX" />
</appSettings>
<connectionStrings>
<add name="DatabaseToRead" connectionString="XXXX"/>
<add name="LogDatabaseToRead" connectionString="XXXX"/>
</connectionStrings>
<system.web>
<!--
Set compilation debug="true" to insert debugging
symbols into the compiled page. Because this
affects performance, set this value to true only
during development.
-->
<compilation debug="true" defaultLanguage="c#">
<assemblies>
<add assembly="System.Core, Version=3.5.0.0, Culture=neutral,
PublicKeyToken=B77A5C561934E089" />
<add assembly="System.Web.Extensions, Version=3.5.0.0, Culture=neutral,
PublicKeyToken=31BF3856AD364E35" />
</assemblies>
</compilation>
<!--
The <authentication> section enables configuration
of the security authentication mode used by
ASP.NET to identify an incoming user.
-->
<authentication mode="Windows" />
<!--
The <customErrors> section enables configuration
of what to do if/when an unhandled error occurs
during the execution of a request. Specifically,
it enables developers to configure html error pages
to be displayed in place of a error stack trace.

<customErrors mode="RemoteOnly"
defaultRedirect="GenericErrorPage.htm">
<error statusCode="403" redirect="NoAccess.htm" />
<error statusCode="404" redirect="FileNotFound.htm" />
</customErrors>
-->
<pages>
<controls>
<add tagPrefix="asp" namespace="System.Web.UI"
assembly="System.Web.Extensions, Version=3.5.0.0, Culture=neutral,
PublicKeyToken=31BF3856AD364E35" />
</controls>
</pages>
<httpHandlers>
<remove verb="*" path="*.asmx" />
<add verb="*" path="*.asmx" validate="false"
type="System.Web.Script.Services.ScriptHandlerFactory,
System.Web.Extensions, Version=3.5.0.0, Culture=neutral,
PublicKeyToken=31BF3856AD364E35" />
<add verb="*" path="*_AppService.axd" validate="false"
type="System.Web.Script.Services.ScriptHandlerFactory,
System.Web.Extensions, Version=3.5.0.0, Culture=neutral,
PublicKeyToken=31BF3856AD364E35" />
<add verb="GET,HEAD" path="ScriptResource.axd"
type="System.Web.Handlers.ScriptResourceHandler, System.Web.Extensions,
Version=3.5.0.0, Culture=neutral, PublicKeyToken=31BF3856AD364E35"
validate="false" />
</httpHandlers>
<httpModules>
<add name="ScriptModule" type="System.Web.Handlers.ScriptModule,
System.Web.Extensions, Version=3.5.0.0, Culture=neutral,
PublicKeyToken=31BF3856AD364E35" />
</httpModules>
</system.web>
<system.codedom>
<compilers>
<compiler language="c#;cs;csharp" extension=".cs" warningLevel="4"
type="Microsoft.CSharp.CSharpCodeProvider, System, Version=2.0.0.0,
Culture=neutral, PublicKeyToken=b77a5c561934e089">
<providerOption name="CompilerVersion" value="v3.5" />
<providerOption name="WarnAsError" value="false" />
</compiler>
</compilers>
</system.codedom>
<!--
The system.webServer section is required for running ASP.NET AJAX
under Internet
Information Services 7.0. It is not necessary for previous version
of IIS.
-->
<system.webServer>
<validation validateIntegratedModeConfiguration="false" />
<modules>
<add name="ScriptModule" preCondition="integratedMode"
type="System.Web.Handlers.ScriptModule, System.Web.Extensions,
Version=3.5.0.0, Culture=neutral, PublicKeyToken=31BF3856AD364E35" />
</modules>
<handlers>
<remove name="WebServiceHandlerFactory-Integrated" />
<add name="ScriptHandlerFactory" verb="*" path="*.asmx"
preCondition="integratedMode"
type="System.Web.Script.Services.ScriptHandlerFactory,
System.Web.Extensions, Version=3.5.0.0, Culture=neutral,
PublicKeyToken=31BF3856AD364E35" />
<add name="ScriptHandlerFactoryAppServices" verb="*"
path="*_AppService.axd" preCondition="integratedMode"
type="System.Web.Script.Services.ScriptHandlerFactory,
System.Web.Extensions, Version=3.5.0.0, Culture=neutral,
PublicKeyToken=31BF3856AD364E35" />
<add name="ScriptResource" preCondition="integratedMode" verb="GET,HEAD"
path="ScriptResource.axd" type="System.Web.Handlers.ScriptResourceHandler,
System.Web.Extensions, Version=3.5.0.0, Culture=neutral,
PublicKeyToken=31BF3856AD364E35" />
</handlers>
</system.webServer>
<system.serviceModel>
<serviceHostingEnvironment aspNetCompatibilityEnabled="true" />
<bindings>
<netTcpBinding>
<binding name="tcpBinding" transactionFlow="true"
maxReceivedMessageSize="655360000"
portSharingEnabled="true">
<reliableSession enabled="true" />
<security mode="None">
<message clientCredentialType="None" />
</security>
</binding>
</netTcpBinding>
</bindings>
<services>
<service behaviorConfiguration="ConfigurationManagerWCF"
name="ConfigurationManagerWCF.Service.ConfigurationProvider">
<endpoint address="mex" binding="mexHttpBinding" bindingConfiguration=""
name="mex" contract="IMetadataExchange" />
<endpoint address="basic" binding="basicHttpBinding" name="basic"
contract="ConfigurationManagerWCF.Contract.IConfigurationProvider"
/>
<endpoint address="net" binding="netTcpBinding"
bindingConfiguration="tcpBinding"
name="netTcp"
contract="ConfigurationManagerWCF.Contract.IConfigurationProvider" />
</service>
</services>
<behaviors>
<serviceBehaviors>
<behavior name="ConfigurationManagerWCF">
<serviceDebug includeExceptionDetailInFaults="true" />
<serviceMetadata httpGetEnabled="true" />
<serviceTimeouts />
</behavior>
</serviceBehaviors>
</behaviors>
</system.serviceModel>
</configuration>


Thank you,
Adrian


""Steven Cheng"" <stcheng(a)online.microsoft.com> wrote in message
news:llU7aVo8KHA.6008(a)TK2MSFTNGHUB02.phx.gbl...
> Hi Adrian,
>
> Thanks for reply Adrian.
> So the problem is specific to netTcpBinding scenario, I think it still
> possible that the service process encounter some exception or hang
> situation which makes the service unavailable to client.
>
> For WCF service, have you tried turned on service tracing at the
> service-side to see whether you can get any error information? The
> following reference shows how to configure WCF tracing.
>
> #Configuring Tracing
> http://msdn.microsoft.com/en-us/library/ms733025.aspx?PHPSESSID=50d760d9b862
> 023e2c39e99ef0c83e42
>
> or you can also use the service configuration editor provided in windows
> sdk to enable tracing:
>
> #Configuration Editor Tool (SvcConfigEditor.exe)
> http://msdn.microsoft.com/en-us/library/ms732009.aspx
>
> Sincerely,
>
> Steven Cheng
>
> Microsoft MSDN Online Support Lead
>
>
> Delighting our customers is our #1 priority. We welcome your comments and
> suggestions about how we can improve the support we provide to you. Please
> feel free to let my manager know what you think of the level of service
> provided. You can send feedback directly to my manager at:
> msdnmg(a)microsoft.com.
>
>
>
> --------------------
>>From: "Adrian Tarjoianu" <adrian(a)usoffice.fareportal.com>
>>Subject: Re: hosting WCF service - netTcp binding - Server Application
> Unavaila
>>Date: Wed, 12 May 2010 09:03:15 -0400
>
>>
>>Hi Steven,
>>
>>I switched back the WCF service to use http prototcol.
>>Everything is fine now.
>>
>>The problem is only when we configure it to use net.tcp protocol.
>>
>>Could you pls tell me what other data you need in order to troubleshoot
> this
>>issue?
>>
>>Thank you,
>>Adrian
>>
>>""Steven Cheng"" <stcheng(a)online.microsoft.com> wrote in message
>>news:JrNONZq6KHA.2348(a)TK2MSFTNGHUB02.phx.gbl...
>>> Hi Adrian,
>>>
>>> Based on your description, the WCF service unavailable error is likely
> due
>>> to the IIS applicaiton pool(of your WCF service application virtual
>>> directory) has encounter some unhandled exception(and crashed). And it
>>> seems the windows eventlog doesn't provide any detailed error info and
>>> cause.
>>>
>>> Is your service using any special component or code logic that may raise
>>> some unhandled exception(like COM interop or unamanged API). Generally,
> we
>>> can first start troubleshooting from code review level before try some
> low
>>> level debugging approahes. Also, if the error is WCF specific, turn on
> the
>>> WCF event trace might also help on capturing underlying error info:
>>>
>>> #Configuring Tracing
>>> http://msdn.microsoft.com/en-us/library/ms733025.aspx
>>>
>>> Sincerely,
>>>
>>> Steven Cheng
>>>
>>> Microsoft MSDN Online Support Lead
>>>
>>>
>