Return-Path: Delivered-To: apmail-logging-log4net-user-archive@www.apache.org Received: (qmail 40678 invoked from network); 5 Sep 2006 13:53:06 -0000 Received: from hermes.apache.org (HELO mail.apache.org) (209.237.227.199) by minotaur.apache.org with SMTP; 5 Sep 2006 13:53:05 -0000 Received: (qmail 39137 invoked by uid 500); 5 Sep 2006 13:53:02 -0000 Delivered-To: apmail-logging-log4net-user-archive@logging.apache.org Received: (qmail 39113 invoked by uid 500); 5 Sep 2006 13:53:02 -0000 Mailing-List: contact log4net-user-help@logging.apache.org; run by ezmlm Precedence: bulk list-help: list-unsubscribe: List-Post: Reply-To: "Log4NET User" List-Id: Delivered-To: mailing list log4net-user@logging.apache.org Received: (qmail 39100 invoked by uid 99); 5 Sep 2006 13:53:02 -0000 Received: from asf.osuosl.org (HELO asf.osuosl.org) (140.211.166.49) by apache.org (qpsmtpd/0.29) with ESMTP; Tue, 05 Sep 2006 06:53:02 -0700 X-ASF-Spam-Status: No, hits=1.4 required=10.0 tests=DNS_FROM_RFC_ABUSE,HTML_10_20,HTML_MESSAGE,SPF_PASS X-Spam-Check-By: apache.org Received-SPF: pass (asf.osuosl.org: domain of michellebweber@gmail.com designates 66.249.92.170 as permitted sender) Received: from [66.249.92.170] (HELO ug-out-1314.google.com) (66.249.92.170) by apache.org (qpsmtpd/0.29) with ESMTP; Tue, 05 Sep 2006 06:53:00 -0700 Received: by ug-out-1314.google.com with SMTP id m3so1988292uge for ; Tue, 05 Sep 2006 06:52:38 -0700 (PDT) DomainKey-Signature: a=rsa-sha1; q=dns; c=nofws; s=beta; d=gmail.com; h=received:message-id:date:from:to:subject:in-reply-to:mime-version:content-type:references; b=Dh6S/XsO7q4UMDrGezOPUYKM8jj4m8hGOk6a2BcTGJE7wZgV3We3Ijv/YTqt7Y2GfV3bjxqTzftm4l00+Yv69vMNeuRNZtE54oZK9OTP5a707ciwVwHU/MAuXF/auBoK1eBlI9ctWLLT+nm0zy8LjEpJPLg6H1N/y0nIG+vz/3A= Received: by 10.66.222.9 with SMTP id u9mr3627170ugg; Tue, 05 Sep 2006 06:52:38 -0700 (PDT) Received: by 10.67.26.16 with HTTP; Tue, 5 Sep 2006 06:52:38 -0700 (PDT) Message-ID: <5fca47f10609050652l14efd49ej329bab728e8e70dc@mail.gmail.com> Date: Tue, 5 Sep 2006 09:52:38 -0400 From: "Michelle Weber" To: "Log4NET User" Subject: Re: Uncaught exception: System.IndexOutOfRangeException In-Reply-To: <41C163ED0194EF459DB8409FD8B7164069F253@waldorf.esendex.com> MIME-Version: 1.0 Content-Type: multipart/alternative; boundary="----=_Part_113678_4655972.1157464358346" References: <41C163ED0194EF459DB8409FD8B7164069F253@waldorf.esendex.com> X-Virus-Checked: Checked by ClamAV on apache.org X-Spam-Rating: minotaur.apache.org 1.6.2 0/1000/N ------=_Part_113678_4655972.1157464358346 Content-Type: text/plain; charset=ISO-8859-1; format=flowed Content-Transfer-Encoding: quoted-printable Content-Disposition: inline Ok thanks. Then upgrading to 1.2.10 will fix it. On 9/5/06, Ian Dykes wrote: > > In addition I received this reply from Nicko Cadell that may help too: > > ----------- > This is a known issue fixed in log4net 1.2.10. Please download the latest > version from http://logging.apache.org/log4net/downloads.html > > The exception is actually coming from an internal error handler. The > Appender must have thrown an exception for this code path to be activated= . > The log4net.Util.LogLog.Error is used to log internal errors. > > The log4net.Util.LogLog.Error writes to the console, and the > System.Diagnostics.Trace handler. It looks like Console code isn't workin= g > correctly. > > > This is not recommended but If you must use log4net 1.2.9 then you can > disable the internal error logging by setting the following = in > your application's .config file: > > > > > Cheers, > Nicko > ----------- > > > Regards > Ian Dykes > > - > > Software Developer > Esendex Ltd > 49 Stoney Street > Nottingham NG1 1LX > > http://www.esendex.com > > Tel: +44 (0) 115 959 7962 > Fax: +44 (0) 115 959 7966 > > Recommend Esendex's Business SMS service to a friend or colleague and you > can earn up to =A3100 in High Street Gift Vouchers when they sign up. > > Go online to make your recommendation today. > https://www.esendex.com/uk/recommend/recommend.aspx > -----Original Message----- > From: Michelle Weber [mailto:michellebweber@gmail.com] > Sent: 05 September 2006 14:43 > To: log4net-user@logging.apache.org > Subject: Uncaught exception: System.IndexOutOfRangeException > > I'm using log4net 1.2.9 and got these uncaught exceptions thrown from my > application causing it to crash this past weekend: > > System.IndexOutOfRangeException: Probable I/O race condition detected > while copying memory. > > I am using log4net with an asp.net 1.1 web service, and am writing entrie= s > to the log for every request. This is on a windows 2003 server, using iis= 6, > and web gardening is turned on, so multiple instances of w3wp.exe are > running and processing requests. > > Here is the full stack trace: > System.Web.Services.Protocols.SoapException: Server was unable to process > request. ---> System.IndexOutOfRangeException: Probable I/O race conditio= n > detected while copying memory. The I/O package is not thread safe by > default. In multithreaded applications, a stream must be accessed in a > thread-safe way, such as a thread-safe wrapper returned by TextReader's o= r > TextWriter's Synchronized methods. This also applies to classes like > StreamWriter and StreamReader. at System.Buffer.InternalBlockCopy(Array > src, Int32 srcOffset, Array dst, > Int32 dstOffset, Int32 count) at System.IO.StreamWriter.Write(Char[] > buffer, Int32 index, Int32 count) at > System.IO.TextWriter.WriteLine(String value) at > System.IO.SyncTextWriter.WriteLine(String value) at > log4net.Util.LogLog.Error(String message, Exception exception) at > log4net.Util.AppenderAttachedImpl.AppendLoopOnAppenders(LoggingEvent > loggingEvent) at > log4net.Repository.Hierarchy.Logger.CallAppenders(LoggingEvent > loggingEvent) at log4net.Repository.Hierarchy.Logger.ForcedLog(Type > callerStackBoundaryDeclaringType, Level level, Object message, Exception > exception) at log4net.Repository.Hierarchy.Logger.Log(Type > callerStackBoundaryDeclaringType, Level level, Object message, Exception > exception) at log4net.Core.LogImpl.Error(Object message) at > My.Online.App.Logger.Error(String msg) at > My.Online.App.ComcastMSOOffersService..ctor() --- End of inner exception > stack trace --- > > > Thanks, > Michelle Weber > ------=_Part_113678_4655972.1157464358346 Content-Type: text/html; charset=ISO-8859-1 Content-Transfer-Encoding: quoted-printable Content-Disposition: inline Ok thanks. Then upgrading to 1.2.10 will fix it.

On 9/5/06, I= an Dykes <ian.dykes@esendex= .com> wrote:
In addition I received this repl= y from Nicko Cadell that may help too:

-----------
This is a know= n issue fixed in log4net=20 1.2.10. Please download the latest version from http://logging.apache.org/log4net/downloa= ds.html

The exception is actually coming from an internal error = handler. The Appender must have thrown an exception for this code path to b= e activated. The=20 log4net.Util.LogLog.Error is used to log internal errors.

The log4ne= t.Util.LogLog.Error writes to the console, and the System.Diagnostics.Trace= handler. It looks like Console code isn't working correctly.


This is not recommended but If you must use log4net 1.2.9 then you can disa= ble the internal error logging by setting the following <appSettings>= in your application's .config file:

<appSettings>
<add = key=3D" log4net.Internal.Quiet" value=3D"true" /> </appSetting= s>

Cheers,
Nicko
-----------


Regards
Ian Dyke= s

-

Software Developer
Esendex Ltd
49 Stoney Street
Nottingham NG1 1LX

http://www.ese= ndex.com

Tel: +44 (0) 115 959 7962
Fax: +44 (0) 115 959 7966<= br>
Recommend Esendex's Business SMS service to a friend or colleague an= d you can earn up to =A3100 in High Street Gift Vouchers when they sign up.

Go online to make your recommendation today. https://www.esendex.com/uk/recomm= end/recommend.aspx
-----Original Message-----
From: Michelle Webe= r [mailto: michellebweber@gmail.com]Sent: 05 September 2006 14:43
To: log4net-user@logging.apache.org
Subject: Uncaught exc= eption:=20 System.IndexOutOfRangeException

I'm using log4net 1.2.9 and got thes= e uncaught exceptions thrown from my application causing it to crash this p= ast weekend:

System.IndexOutOfRangeException: Probable I/O race cond= ition detected while copying memory.

I am using log4net with an asp.net 1= .1 web service, and am writing entries to the log for every request. This i= s on a windows 2003 server, using iis6, and web gardening is turned on, so = multiple instances of=20 w3wp.exe are running and processing requests.

Here is the full stack= trace:
System.Web.Services.Protocols.SoapException: Server was unable t= o process request. ---> System.IndexOutOfRangeException: Probable I/O ra= ce condition detected while copying memory. The I/O package is not thread s= afe by default. In multithreaded applications, a stream must be accessed in= a thread-safe way, such as a thread-safe wrapper returned by TextReader's = or TextWriter's Synchronized methods. This also applies to classes like Str= eamWriter and StreamReader. at=20 System.Buffer.InternalBlockCopy(Array src, Int32 srcOffset, Array dst,
I= nt32 dstOffset, Int32 count) at System.IO.StreamWriter.Write(Char[]
buff= er, Int32 index, Int32 count) at
System.IO.TextWriter.WriteLine(String v= alue) at=20 System.IO.SyncTextWriter.WriteLine(String value) at log4net.Util.LogLog.Err= or(String message, Exception exception) at log4net.Util.AppenderAttachedImp= l.AppendLoopOnAppenders(LoggingEvent
loggingEvent) at
log4net.Reposit= ory.Hierarchy.Logger.CallAppenders (LoggingEvent
loggingEvent) at log4net.Repository.Hierarchy.Logger.Force= dLog(Type
callerStackBoundaryDeclaringType, Level level, Object message,= Exception exception) at log4net.Repository.Hierarchy.Logger.Log(Type
callerStackBoundaryDeclaringType, Level level, Object message, Exception ex= ception) at log4net.Core.LogImpl.Error(Object message) at My.Online.App.Log= ger.Error(String msg) at
My.Online.App.ComcastMSOOffersService..ctor () --- End of inner exception stack trace ---


Thanks,
Michell= e Weber

------=_Part_113678_4655972.1157464358346--