Jeremiah Voris | 1 Aug 01:30 2005
Picon

Re: How do I set Category/Event in EventLogAppender?

On 7/30/05, Ron Grabowski <rongrabowski <at> yahoo.com> wrote:
> (You probably already know this) You don't need the .snk file to build
> in Release mode. If you comment out these lines from the
> AssemblyInfo.cs file:
> 
>  #if STRONG
>  [assembly: AssemblyDelaySign(false)]
>  [assembly: AssemblyKeyFile( <at> "..\..\..\log4net.snk")]
>  #endif
> 
> You can build in Release mode.

Yeah, I did know that but I figured I might as well get it working
with the signed key since the ultimate goal is to install it as a
shared assembly in the gac.
> 
> Where did you end up putting the .snk file to get it to build? It
> sounds like the .snk file needs to be in two different locations
> depending on whether you're building the complete source or just the
> extensions. Is that the case?

That is not the case. Oddly enough, where I ended up placing it was
one directory higher than the base log4net directory. So let's say I
have the log4net directory which, in turn, contains all the
extensions, src, bin, etc. directories in a directory called
"usefull_stuff"... well I ended up putting the key file in that
"usefull_stuff" directory! It was totally odd that it could find it
there without the assembly file pointing there (which it is most
definitely not).

(Continue reading)

Jeff Hughes | 1 Aug 08:10 2005

RE: How do I set Category/Event in EventLogAppender?

I usually just create a folder on my c drive called keys and dump all
assembly key files in there then just reference the key location when
compiling.

[assembly: AssemblyKeyFile("c:\\keys\\log4net.snk")]

-----Original Message-----
From: Jeremiah Voris [mailto:jeremiahv <at> gmail.com] 
Sent: Sunday, July 31, 2005 4:31 PM
To: Log4NET User
Subject: Re: How do I set Category/Event in EventLogAppender?

On 7/30/05, Ron Grabowski <rongrabowski <at> yahoo.com> wrote:
> (You probably already know this) You don't need the .snk file to build
> in Release mode. If you comment out these lines from the
> AssemblyInfo.cs file:
> 
>  #if STRONG
>  [assembly: AssemblyDelaySign(false)]
>  [assembly: AssemblyKeyFile( <at> "..\..\..\log4net.snk")]
>  #endif
> 
> You can build in Release mode.

Yeah, I did know that but I figured I might as well get it working
with the signed key since the ultimate goal is to install it as a
shared assembly in the gac.
> 
> Where did you end up putting the .snk file to get it to build? It
> sounds like the .snk file needs to be in two different locations
(Continue reading)

Charles Carroll | 3 Aug 05:08 2005
Picon

What is wrong with Log4Net web.config?

http://www.learnasp.com/freebook/learn/log4net1.aspx

when we run that program it should output to trace.write the Log.Info
statements.

Thibaut Barrère | 3 Aug 08:19 2005
Picon

Re: What is wrong with Log4Net web.config?

Not sure to understand what you mean exactly, but I noticed that your handler type in the section declaration looks like :
" log4net.Config.Log4NetConfigurationSectionHandler, log4net-net-1.0"
where we usually write:
"log4net.Config.Log4NetConfigurationSectionHandler, log4net" Is it what is intented ?


regards

Thibaut Barrère
--
[blog] http://www.dotnetguru2.org/tbarrere

2005/8/3, Charles Carroll <charlesmarkcarroll <at> gmail.com >:
http://www.learnasp.com/freebook/learn/log4net1.aspx

when we run that program it should output to trace.write the Log.Info
statements.




Russell Haley | 6 Aug 01:23 2005

Appenders current file path?

Is there a way of getting the current filename (preferably the whole path)
of a rolling file appender? I'm using a file appender that rolls on date and
creates specific paths for each month and year and I'd like to have my
application bring up the current log file in notepad without having the user
look for it.

Cheers!
Russ

Saurabh Dani | 7 Aug 23:30 2005

Keeping old log files in RollingAppender

I have following configuration for RollingFIleAppender, but it does not save my old logs. Every night the log file is overwritten. Can someon epoint to me that what needs to be changed to keep the old logs.

<log4net>

<appender name="RollingLogFileAppender" type="log4net.Appender.RollingFileAppender">

<file value="Logs\l4net.log" />

<appendToFile value="true" />

<rollingStyle value="Date" />

<datePattern value="yyyyMMdd" />

<lockingModel type="log4net.Appender.RollingFileAppender+MinimalLock" />

<layout type="log4net.Layout.PatternLayout">

<conversionPattern value="%date|[%thread]|%-5level|%logger|%l|[%property{NDC}]|- %message%newline" />

</layout>

</appender>

<root>

<level value="INFO" />

<level value="DEBUG" />

<appender-ref ref="RollingLogFileAppender" />

</root>

</log4net>



Thanks
Saurabh
Helbig, Dirk (EXTERN: HUD | 8 Aug 10:54 2005
Picon

AW: Keeping old log files in RollingAppender

Hi,
 
I have the same problem!!!
In my DEBUG-Log you can see why the files could not be rolled.
 
Thanks
Dirk
-----Ursprüngliche Nachricht-----
Von: Saurabh Dani [mailto:saurabh <at> danicorp.com]
Gesendet: Sonntag, 7. August 2005 23:30
An: log4net-user <at> logging.apache.org
Betreff: Keeping old log files in RollingAppender

I have following configuration for RollingFIleAppender, but it does not save my old logs. Every night the log file is overwritten. Can someon epoint to me that what needs to be changed to keep the old logs.

<log4net>

<appender name="RollingLogFileAppender" type="log4net.Appender.RollingFileAppender">

<file value="Logs\l4net.log" />

<appendToFile value="true" />

<rollingStyle value="Date" />

<datePattern value="yyyyMMdd" />

<lockingModel type="log4net.Appender.RollingFileAppender+MinimalLock" />

<layout type="log4net.Layout.PatternLayout">

<conversionPattern value="%date|[%thread]|%-5level|%logger|%l|[%property{NDC}]|- %message%newline" />

</layout>

</appender>

<root>

<level value="INFO" />

<level value="DEBUG" />

<appender-ref ref="RollingLogFileAppender" />

</root>

</log4net>



Thanks
Saurabh
Picon
From: Helbig, Dirk (EXTERN: HUD <extern.dirk.helbig <at> volkswagen.de>
Subject: RollingFileAppender does sometimes not work
Date: 2005-07-29 07:20:54 GMT

Hi,

I have the latest version of log4net from cvs, but the RollingFileAppender
does sometimes not roll the logfiles.
Here is the debug-log:
log4net: RollingFileAppender: Moving
[D:\Projekte\CarConfigurators\CC5\LogFiles\cc5-trace.txt] ->
[..\\LogFiles\\cc5-trace.txt.20050728]
log4net:ERROR [RollingFileAppender] Exception while rolling file
[D:\Projekte\CarConfigurators\CC5\LogFiles\cc5-trace.txt] ->
[..\\LogFiles\\cc5-trace.txt.20050728]
System.IO.DirectoryNotFoundException: Ein Teil des Pfades
..\\LogFiles\\cc5-trace.txt.20050728 konnte nicht gefunden werden.
   at System.IO.__Error.WinIOError(Int32 errorCode, String str)
   at System.IO.File.Move(String sourceFileName, String destFileName)
   at log4net.Appender.RollingFileAppender.RollFile(String fromFile, String
toFile)
log4net: FileAppender: Opening file for writing
[D:\Projekte\CarConfigurators\CC5\LogFiles\cc5-trace.txt] append [False]
log4net: RollingFileAppender: Moving
[D:\Projekte\CarConfigurators\CC5\LogFiles\cc5-error.txt] ->
[..\\LogFiles\\cc5-error.txt.20050728]
log4net:ERROR [RollingFileAppender] Exception while rolling file
[D:\Projekte\CarConfigurators\CC5\LogFiles\cc5-error.txt] ->
[..\\LogFiles\\cc5-error.txt.20050728]
System.IO.DirectoryNotFoundException: Ein Teil des Pfades
..\\LogFiles\\cc5-error.txt.20050728 konnte nicht gefunden werden.
   at System.IO.__Error.WinIOError(Int32 errorCode, String str)
   at System.IO.File.Move(String sourceFileName, String destFileName)
   at log4net.Appender.RollingFileAppender.RollFile(String fromFile, String
toFile)
log4net: FileAppender: Opening file for writing
[D:\Projekte\CarConfigurators\CC5\LogFiles\cc5-error.txt] append [False]
log4net: RollingFileAppender: Moving
[D:\Projekte\CarConfigurators\CC5\LogFiles\cc5-info.txt] ->
[..\\LogFiles\\cc5-info.txt.20050728]
log4net:ERROR [RollingFileAppender] Exception while rolling file
[D:\Projekte\CarConfigurators\CC5\LogFiles\cc5-info.txt] ->
[..\\LogFiles\\cc5-info.txt.20050728]
System.IO.DirectoryNotFoundException: Ein Teil des Pfades
..\\LogFiles\\cc5-info.txt.20050728 konnte nicht gefunden werden.
   at System.IO.__Error.WinIOError(Int32 errorCode, String str)
   at System.IO.File.Move(String sourceFileName, String destFileName)
   at log4net.Appender.RollingFileAppender.RollFile(String fromFile, String
toFile)
log4net: FileAppender: Opening file for writing
[D:\Projekte\CarConfigurators\CC5\LogFiles\cc5-info.txt] append [False]
log4net: Hierarchy: Shutdown called on Hierarchy
[log4net-default-repository]

I have an ASP.NET-application with .NET 1.1 SP 1

I hope you could fix the bug as soon as possible.

Thanks, Dirk

Helbig, Dirk (EXTERN: HUD | 8 Aug 10:56 2005
Picon

AW: Keeping old log files in RollingAppender

Hi, 
 
I have the same problem!!! 
In my DEBUG-Log you can see why the files could not be rolled. 
 
Thanks 
Dirk
-----Ursprüngliche Nachricht-----
Von: Saurabh Dani [mailto:saurabh <at> danicorp.com]
Gesendet: Sonntag, 7. August 2005 23:30
An: log4net-user <at> logging.apache.org
Betreff: Keeping old log files in RollingAppender

I have following configuration for RollingFIleAppender, but it does not save my old logs. Every night the log file is overwritten. Can someon epoint to me that what needs to be changed to keep the old logs.

<log4net>

<appender name="RollingLogFileAppender" type="log4net.Appender.RollingFileAppender">

<file value="Logs\l4net.log" />

<appendToFile value="true" />

<rollingStyle value="Date" />

<datePattern value="yyyyMMdd" />

<lockingModel type="log4net.Appender.RollingFileAppender+MinimalLock" />

<layout type="log4net.Layout.PatternLayout">

<conversionPattern value="%date|[%thread]|%-5level|%logger|%l|[%property{NDC}]|- %message%newline" />

</layout>

</appender>

<root>

<level value="INFO" />

<level value="DEBUG" />

<appender-ref ref="RollingLogFileAppender" />

</root>

</log4net>



Thanks
Saurabh
Picon
From: Helbig, Dirk (EXTERN: HUD <extern.dirk.helbig <at> volkswagen.de>
Subject: RollingFileAppender does sometimes not work
Date: 2005-07-29 07:20:54 GMT

Hi,

I have the latest version of log4net from cvs, but the RollingFileAppender
does sometimes not roll the logfiles.
Here is the debug-log:
log4net: RollingFileAppender: Moving
[D:\Projekte\CarConfigurators\CC5\LogFiles\cc5-trace.txt] ->
[..\\LogFiles\\cc5-trace.txt.20050728]
log4net:ERROR [RollingFileAppender] Exception while rolling file
[D:\Projekte\CarConfigurators\CC5\LogFiles\cc5-trace.txt] ->
[..\\LogFiles\\cc5-trace.txt.20050728]
System.IO.DirectoryNotFoundException: Ein Teil des Pfades
..\\LogFiles\\cc5-trace.txt.20050728 konnte nicht gefunden werden.
   at System.IO.__Error.WinIOError(Int32 errorCode, String str)
   at System.IO.File.Move(String sourceFileName, String destFileName)
   at log4net.Appender.RollingFileAppender.RollFile(String fromFile, String
toFile)
log4net: FileAppender: Opening file for writing
[D:\Projekte\CarConfigurators\CC5\LogFiles\cc5-trace.txt] append [False]
log4net: RollingFileAppender: Moving
[D:\Projekte\CarConfigurators\CC5\LogFiles\cc5-error.txt] ->
[..\\LogFiles\\cc5-error.txt.20050728]
log4net:ERROR [RollingFileAppender] Exception while rolling file
[D:\Projekte\CarConfigurators\CC5\LogFiles\cc5-error.txt] ->
[..\\LogFiles\\cc5-error.txt.20050728]
System.IO.DirectoryNotFoundException: Ein Teil des Pfades
..\\LogFiles\\cc5-error.txt.20050728 konnte nicht gefunden werden.
   at System.IO.__Error.WinIOError(Int32 errorCode, String str)
   at System.IO.File.Move(String sourceFileName, String destFileName)
   at log4net.Appender.RollingFileAppender.RollFile(String fromFile, String
toFile)
log4net: FileAppender: Opening file for writing
[D:\Projekte\CarConfigurators\CC5\LogFiles\cc5-error.txt] append [False]
log4net: RollingFileAppender: Moving
[D:\Projekte\CarConfigurators\CC5\LogFiles\cc5-info.txt] ->
[..\\LogFiles\\cc5-info.txt.20050728]
log4net:ERROR [RollingFileAppender] Exception while rolling file
[D:\Projekte\CarConfigurators\CC5\LogFiles\cc5-info.txt] ->
[..\\LogFiles\\cc5-info.txt.20050728]
System.IO.DirectoryNotFoundException: Ein Teil des Pfades
..\\LogFiles\\cc5-info.txt.20050728 konnte nicht gefunden werden.
   at System.IO.__Error.WinIOError(Int32 errorCode, String str)
   at System.IO.File.Move(String sourceFileName, String destFileName)
   at log4net.Appender.RollingFileAppender.RollFile(String fromFile, String
toFile)
log4net: FileAppender: Opening file for writing
[D:\Projekte\CarConfigurators\CC5\LogFiles\cc5-info.txt] append [False]
log4net: Hierarchy: Shutdown called on Hierarchy
[log4net-default-repository]

I have an ASP.NET-application with .NET 1.1 SP 1

I hope you could fix the bug as soon as possible.

Thanks, Dirk

Johann Rutnam | 9 Aug 06:44 2005
Picon

log4net CF question

Hi,

Is it posible to configure log4net to reference it's dll from a
Directory. I have various applications running on a Handheld,
and to save space I would like to avoid having multiple copies
of log4net in each Directory of the application.
Thx,

Johann

________________________________________________
Get your own "800" number
Voicemail, fax, email, and a lot more
http://www.ureach.com/reg/tag

Thibaut Barrère | 9 Aug 10:01 2005
Picon

Re: log4net CF question

Hi Johann

what about placing the shared log4net dll into the GAC on your device ?

howto : http://msdn.microsoft.com/library/default.asp?url=/library/en-us/dncfhowto/html/HOWTOGAC.asp

kind regards

Thibaut Barrère
--
[blog] http://www.dotnetguru2.org/tbarrere

2005/8/9, Johann Rutnam <johann <at> ureach.com>:
Hi,

Is it posible to configure log4net to reference it's dll from a
Directory. I have various applications running on a Handheld,
and to save space I would like to avoid having multiple copies
of log4net in each Directory of the application.
Thx,

Johann

________________________________________________
Get your own "800" number
Voicemail, fax, email, and a lot more
http://www.ureach.com/reg/tag





Gmane