Home All Groups Group Topic Archive Search About

Enterprise Library Configuration failure

Author
7 Jun 2006 10:58 AM
Hodge
Logger.Write fails with the message :-
"The entry 'Category' has already been added.
(C:\\inetpub\\wwwroot\\SIMWebClient\\web.config line 152)" string
Source "System.Configuration"    string

line 152 is the <add line in
  <loggingConfiguration tracingEnabled="true"
defaultCategory="General">
    <logFilters>
      <add
    name="Category"

type="Microsoft.Practices.EnterpriseLibrary.Logging.Filters.CategoryFilter,
Microsoft.Practices.EnterpriseLibrary.Logging"
    categoryFilterMode="AllowAllExceptDenied">

The exact configuration file has worked on another machine.
Unfortunately I don't understand the failure.
John
P.S. I have a full stack trace if it would help.

Author
22 Jun 2006 8:28 AM
xplainenator
Hodge schreef:

Show quote
> Logger.Write fails with the message :-
> "The entry 'Category' has already been added.
> (C:\\inetpub\\wwwroot\\SIMWebClient\\web.config line 152)" string
> Source "System.Configuration"    string
>
> line 152 is the <add line in
>   <loggingConfiguration tracingEnabled="true"
> defaultCategory="General">
>     <logFilters>
>       <add
>     name="Category"
>
> type="Microsoft.Practices.EnterpriseLibrary.Logging.Filters.CategoryFilter,
> Microsoft.Practices.EnterpriseLibrary.Logging"
>     categoryFilterMode="AllowAllExceptDenied">
>
> The exact configuration file has worked on another machine.
> Unfortunately I don't understand the failure.
> John
> P.S. I have a full stack trace if it would help.

Hi Hodge,

I had the exact same problem when I deployed an update of our
webservice on our development server. I did it like 50 times and it
worked every time, and now suddenly I got that freakin' exception.
But i solved it!

Good to know:
On our webserver we made a subdirectory in c:\Inetpub
(C:\Inetpub\Company), which is also a website in IIS, so not under
Default website. In that directory we deployed our webservices.

Solution:
I did 2 things:
1) I deleted all the subfolders of C:\Inetpub\Company which had hidden
cache folders and stuff
2) I ran the ASP.NET IIS Registration Tool (Aspnet_regiis.exe) for the
..NET 2.0 framework to re-registrate the .NET 2.0 framework in IIS. You
just run the tool in your command window:
C:\WINDOWS\Microsoft.NET\Framework\v2.0.50727\Aspnet_regiis.exe -i

I don't know which part made it work again. It could be just one of
them or the both of them. All I know is that it worked for me and I'm
super happy!

Hope this helps you!

Kind regards,

xplain.

AddThis Social Bookmark Button