Return-Path: Delivered-To: apmail-logging-log4j-dev-archive@www.apache.org Received: (qmail 95771 invoked from network); 29 Sep 2004 14:17:50 -0000 Received: from hermes.apache.org (HELO mail.apache.org) (209.237.227.199) by minotaur-2.apache.org with SMTP; 29 Sep 2004 14:17:50 -0000 Received: (qmail 52609 invoked by uid 500); 29 Sep 2004 14:16:49 -0000 Delivered-To: apmail-logging-log4j-dev-archive@logging.apache.org Received: (qmail 52449 invoked by uid 500); 29 Sep 2004 14:16:47 -0000 Mailing-List: contact log4j-dev-help@logging.apache.org; run by ezmlm Precedence: bulk List-Unsubscribe: List-Subscribe: List-Help: List-Post: List-Id: "Log4J Developers List" Reply-To: "Log4J Developers List" Delivered-To: mailing list log4j-dev@logging.apache.org Received: (qmail 52348 invoked by uid 99); 29 Sep 2004 14:16:45 -0000 X-ASF-Spam-Status: No, hits=0.0 required=10.0 tests=NO_REAL_NAME X-Spam-Check-By: apache.org Received-SPF: pass (hermes.apache.org: local policy) Received: from [193.212.240.200] (HELO scan.telenor.net) (193.212.240.200) by apache.org (qpsmtpd/0.28) with ESMTP; Wed, 29 Sep 2004 07:16:43 -0700 Received: from tns-fbu-22-209.corp.telenor.no ([134.47.162.190] [134.47.162.190]) by scan.telenor.net with ESMTP for log4j-dev@logging.apache.org; Wed, 29 Sep 2004 16:16:35 +0200 Received: from tns-fbu-22-212.corp.telenor.no ([134.47.162.91]) by tns-fbu-22-209.corp.telenor.no with Microsoft SMTPSVC(5.0.2195.6713); Wed, 29 Sep 2004 16:16:37 +0200 Received: from TNS-FBU-2E-013.corp.telenor.no ([134.47.163.43]) by tns-fbu-22-212.corp.telenor.no with Microsoft SMTPSVC(5.0.2195.6713); Wed, 29 Sep 2004 16:16:37 +0200 Content-class: urn:content-classes:message X-MimeOLE: Produced By Microsoft Exchange V6.5.7226.0 Subject: RE: Log4J problem with RollingFileAppender and backups Date: Wed, 29 Sep 2004 16:16:37 +0200 Message-Id: <24A8C0F2A0D9564DA5A5EB58D5B3C0D007F6EF@TNS-FBU-2E-013.corp.telenor.no> X-MS-Has-Attach: X-MS-TNEF-Correlator: Thread-Topic: Log4J problem with RollingFileAppender and backups Thread-Index: AcSlL22Y5hqVGNVPTMiCxQSc0RlLMgAE2f2AADZ9L/AAA+edsAAAkXwQ From: To: X-OriginalArrivalTime: 29 Sep 2004 14:16:37.0796 (UTC) FILETIME=[EEC74640:01C4A62E] MIME-Version: 1.0 Content-Type: text/plain; charset="iso-8859-1" Content-Transfer-Encoding: quoted-printable X-Virus-Checked: Checked X-Spam-Rating: minotaur-2.apache.org 1.6.2 0/1000/N My recommendation is that you use the basic WriterAppender / = FileAppender, and handle the rolling outside the application. One solution (which we use) could be to embed a date in the file name, = and have the appender restart at regular intervals. > -----Original Message----- > From: J=E4rkeborn Joacim [mailto:joacim.jarkeborn@volvo.com] > Sent: Wednesday, September 29, 2004 4:01 PM > To: log4j-dev@logging.apache.org > Subject: FW: Log4J problem with RollingFileAppender and backups >=20 >=20 >=20 > Hi, >=20 > We are getting quite desperate about our disappearing=20 > logfiles and I therefore post this issue to the log4j-developer list. >=20 > Can you help me? >=20 >=20 > Regards > Joacim J=E4rkeborn > IT Architect >=20 > > -----Original Message----- > > From: J=E4rkeborn Joacim [mailto:joacim.jarkeborn@volvo.com]=20 > > Sent: den 29 september 2004 14:10 > > To: Log4J Users List > > Subject: RE: Log4J problem with RollingFileAppender and backups > >=20 > > Hi again, > > Doesn't anyone else having this problem?=20 > > Anyone having some solution of this?=20 > >=20 > > OS: Windows 2000/XP > >=20 > > Regards > > Joacim J=E4rkeborn > > IT Architect > >=20 > > =20 > >=20 > > > -----Original Message----- > > > From: J=E4rkeborn Joacim [mailto:joacim.jarkeborn@volvo.com] > > > Sent: den 28 september 2004 12:21 > > > To: Log4J Users List > > > Subject: RE: Log4J problem with RollingFileAppender and backups > > >=20 > > >=20 > > > Some additional notes... > > >=20 > > > The renaming of "mylog.log.x" --> "mylog.log.x+1" works but NOT=20 > > > "mylog.log" --> "mylog.log.1". Therefore the backups rolls=20 > > away after=20 > > > some rolling. > > >=20 > > >=20 > > >=20 > > > Regards > > > Joacim J=E4rkeborn > > > IT Architect > > >=20 > > > =20 > > >=20 > > > > -----Original Message----- > > > > From: J=E4rkeborn Joacim [mailto:joacim.jarkeborn@volvo.com] > > > > Sent: den 28 september 2004 09:48 > > > > To: log4j-user@logging.apache.org > > > > Subject: Log4J problem with RollingFileAppender and backups > > > >=20 > > > > Hi, > > > >=20 > > > >=20 > > > > We are using Log4J in our J2EE application with=20 > > RollingFileAppender=20 > > > > and a number of backups. > > > >=20 > > > > When the appserver and application starts everything seems > > > to work as > > > > it should, it creates the logfile and backups after the max > > > file size > > > > have been reached. When max backup parameters are reached=20 > > the files=20 > > > > rolls away from disk. > > > >=20 > > > > But when restarting the application (ear, not the > > > appserver) it seems > > > > to lost it's track and the the files are removed one by > > > one, starting > > > > with the logfile.log.1. > > > >=20 > > > > The logfiles can not be removed as long as the appserver is > > > started.=20 > > > >=20 > > > > Any ideas?=20 > > > >=20 > > > > Using IBM WebSphere 5.0.2/5.1 and Log4J 1.2.8.=20 > > > > Configuration and trace are avialable below.=20 > > > >=20 > > > > BR > > > > Joacim J > > > >=20 > > > > -------------------------------------------------------------- > > > > ------------ > > > > log4j config > > > > -------------------------------------------------------------- > > > > ------------ > > > > =20 > > > > > > > class=3D"org.apache.log4j.RollingFileAppender">=20 > > > > =20 > > > > > > > >=20 > > > > =20 > > > > > > > >=20 > > > > =20 > > > > > > > >=20 > > > > =20 > > > > =20 > > > > > %-5p %-30c{1}=20 > > > > [%x] %m%n"/> > > > > =20 > > > > > > > >=20 > > > > > > class=3D"org.apache.log4j.ConsoleAppender"> > > > > =20 > > > > =20 > > > > > > [%t] %C{2} > > > > (%F:%L) - %m\n"/> > > > > =20 > > > > > > > >=20 > > > > =20 > > > > =20 > > > > =20 > > > > > > > >=20 > > > > =20 > > > > =20 > > > > =20 > > > > > > > > > > > >=20 > > > >=20 > > > >=20 > > > > -------------------------------------------------------------- > > > > ------------ > > > > The Log4J trace:=20 > > > > -------------------------------------------------------------- > > > > ------------ > > > > log4j: Standard DocumentBuilderFactory search succeded.=20 > > > > log4j: DocumentBuilderFactory is:=20 > > > > org.apache.xerces.jaxp.DocumentBuilderFactoryImpl > > > > log4j: debug attribute=3D "null".=20 > > > > log4j: Ignoring debug attribute.=20 > > > > log4j: Threshold =3D"null".=20 > > > > log4j: Retreiving an instance of org.apache.log4j.Logger.=20 > > > > log4j: Setting [org.apache.log4j.xml] additivity to [true].=20 > > > > log4j: Level value for org.apache.log4j.xml is [info].=20 > > > > log4j: org.apache.log4j.xml level set to INFO > > > > log4j: Class name: [org.apache.log4j.RollingFileAppender] > > > > log4j: Setting property [file] to [logs/pos.log].=20 > > > > log4j: Setting property [append] to [true].=20 > > > > log4j: Setting property [maxFileSize] to [64KB].=20 > > > > log4j: Setting property [maxBackupIndex] to [20].=20 > > > > log4j: Parsing layout of class:=20 > "org.apache.log4j.PatternLayout"=20 > > > > log4j: Setting property [conversionPattern] to [%d %-5p > > > %-30c{1} [%x] > > > > %m%n]. > > > > log4j: setFile called: logs/pos.log, true > > > > log4j: setFile ended > > > > log4j: Adding appender named [A_ROOT] to category=20 > > > > [org.apache.log4j.xml]. > > > > log4j: Level value for root is [debug].=20 > > > > log4j: root level set to DEBUG > > > > log4j: Adding appender named [A_ROOT] to category [root].=20 > > > >=20 > > > > ...=20 > > > >=20 > > > > log4j: rolling over count=3D65682 > > > > log4j: maxBackupIndex=3D20 > > > > log4j: Renaming file logs\pos.log.19 to logs\pos.log.20 > > > > log4j: Renaming file logs\pos.log.18 to logs\pos.log.19 > > > > log4j: Renaming file logs\pos.log.17 to logs\pos.log.18 > > > > log4j: Renaming file logs\pos.log.16 to logs\pos.log.17 > > > > log4j: Renaming file logs\pos.log.15 to logs\pos.log.16 > > > > log4j: Renaming file logs\pos.log.14 to logs\pos.log.15 > > > > log4j: Renaming file logs\pos.log.13 to logs\pos.log.14 > > > > log4j: Renaming file logs\pos.log.12 to logs\pos.log.13 > > > > log4j: Renaming file logs\pos.log.11 to logs\pos.log.12 > > > > log4j: Renaming file logs\pos.log.10 to logs\pos.log.11 > > > > log4j: Renaming file logs\pos.log.9 to logs\pos.log.10 > > > > log4j: Renaming file logs\pos.log.8 to logs\pos.log.9 > > > > log4j: Renaming file logs\pos.log.7 to logs\pos.log.8 > > > > log4j: Renaming file logs\pos.log.6 to logs\pos.log.7 > > > > log4j: Renaming file logs\pos.log.5 to logs\pos.log.6 > > > > log4j: Renaming file logs\pos.log.4 to logs\pos.log.5 > > > > log4j: Renaming file logs\pos.log.3 to logs\pos.log.4 > > > > log4j: Renaming file logs\pos.log.2 to logs\pos.log.3 > > > > log4j: Renaming file logs\pos.log.1 to logs\pos.log.2 > > > > log4j: Renaming file logs\pos.log to logs\pos.log.1 > > > > log4j: setFile called: logs/pos.log, false > > > > log4j: setFile ended > > > >=20 > > > > ... [EAR RESTART] > > > >=20 > > > > log4j: Standard DocumentBuilderFactory search succeded.=20 > > > > log4j: DocumentBuilderFactory is:=20 > > > > org.apache.xerces.jaxp.DocumentBuilderFactoryImpl > > > > log4j: debug attribute=3D "null".=20 > > > > log4j: Ignoring debug attribute.=20 > > > > log4j: Threshold =3D"null".=20 > > > > log4j: Retreiving an instance of org.apache.log4j.Logger.=20 > > > > log4j: Setting [org.apache.log4j.xml] additivity to [true].=20 > > > > log4j: Level value for org.apache.log4j.xml is [info].=20 > > > > log4j: org.apache.log4j.xml level set to INFO > > > > log4j: Class name: [org.apache.log4j.RollingFileAppender] > > > > log4j: Setting property [file] to [logs/pos.log].=20 > > > > log4j: Setting property [append] to [true].=20 > > > > log4j: Setting property [maxFileSize] to [64KB].=20 > > > > log4j: Setting property [maxBackupIndex] to [20].=20 > > > > log4j: Parsing layout of class:=20 > "org.apache.log4j.PatternLayout"=20 > > > > log4j: Setting property [conversionPattern] to [%d %-5p > > > %-30c{1} [%x] > > > > %m%n]. > > > > log4j: setFile called: logs/pos.log, true > > > > log4j: setFile ended > > > > log4j: Adding appender named [A_ROOT] to category=20 > > > > [org.apache.log4j.xml]. > > > > log4j: Level value for root is [debug].=20 > > > > log4j: root level set to DEBUG > > > > log4j: Adding appender named [A_ROOT] to category [root].=20 > > > >=20 > > > > ... [RUNNING APPLICATION TO GENERATE LOGS/ROLLING FILES] > > > >=20 > > > > log4j: rolling over count=3D65663 > > > > log4j: maxBackupIndex=3D20 > > > > log4j: Renaming file logs\pos.log.19 to logs\pos.log.20 > > > > log4j: Renaming file logs\pos.log.18 to logs\pos.log.19 > > > > log4j: Renaming file logs\pos.log.17 to logs\pos.log.18 > > > > log4j: Renaming file logs\pos.log.16 to logs\pos.log.17 > > > > log4j: Renaming file logs\pos.log.15 to logs\pos.log.16 > > > > log4j: Renaming file logs\pos.log.14 to logs\pos.log.15 > > > > log4j: Renaming file logs\pos.log.13 to logs\pos.log.14 > > > > log4j: Renaming file logs\pos.log.12 to logs\pos.log.13 > > > > log4j: Renaming file logs\pos.log.11 to logs\pos.log.12 > > > > log4j: Renaming file logs\pos.log.10 to logs\pos.log.11 > > > > log4j: Renaming file logs\pos.log.9 to logs\pos.log.10 > > > > log4j: Renaming file logs\pos.log.8 to logs\pos.log.9 > > > > log4j: Renaming file logs\pos.log.7 to logs\pos.log.8 > > > > log4j: Renaming file logs\pos.log.6 to logs\pos.log.7 > > > > log4j: Renaming file logs\pos.log.5 to logs\pos.log.6 > > > > log4j: Renaming file logs\pos.log.4 to logs\pos.log.5 > > > > log4j: Renaming file logs\pos.log.3 to logs\pos.log.4 > > > > log4j: Renaming file logs\pos.log.2 to logs\pos.log.3 > > > > log4j: Renaming file logs\pos.log.1 to logs\pos.log.2 > > > > log4j: Renaming file logs\pos.log to logs\pos.log.1 > > > > log4j: setFile called: logs/pos.log, false > > > > log4j: setFile ended > > > >=20 > > > > ... [FILES STARTS TO DISAPPEAR] > > > >=20 > > > > log4j: rolling over count=3D65655 > > > > log4j: maxBackupIndex=3D20 > > > > log4j: Renaming file logs\pos.log.19 to logs\pos.log.20 > > > > log4j: Renaming file logs\pos.log.18 to logs\pos.log.19 > > > > log4j: Renaming file logs\pos.log.17 to logs\pos.log.18 > > > > log4j: Renaming file logs\pos.log.16 to logs\pos.log.17 > > > > log4j: Renaming file logs\pos.log.15 to logs\pos.log.16 > > > > log4j: Renaming file logs\pos.log.14 to logs\pos.log.15 > > > > log4j: Renaming file logs\pos.log.13 to logs\pos.log.14 > > > > log4j: Renaming file logs\pos.log.12 to logs\pos.log.13 > > > > log4j: Renaming file logs\pos.log.11 to logs\pos.log.12 > > > > log4j: Renaming file logs\pos.log.10 to logs\pos.log.11 > > > > log4j: Renaming file logs\pos.log.9 to logs\pos.log.10 > > > > log4j: Renaming file logs\pos.log.8 to logs\pos.log.9 > > > > log4j: Renaming file logs\pos.log.7 to logs\pos.log.8 > > > > log4j: Renaming file logs\pos.log.6 to logs\pos.log.7 > > > > log4j: Renaming file logs\pos.log.5 to logs\pos.log.6 > > > > log4j: Renaming file logs\pos.log.4 to logs\pos.log.5 > > > > log4j: Renaming file logs\pos.log.3 to logs\pos.log.4 > > > > log4j: Renaming file logs\pos.log.2 to logs\pos.log.3 > > > > log4j: Renaming file logs\pos.log to logs\pos.log.1 > > > > log4j: setFile called: logs/pos.log, false > > > > log4j: setFile ended > > > >=20 > > > > ...=20 > > > >=20 > > > > log4j: rolling over count=3D65582 > > > > log4j: maxBackupIndex=3D20 > > > > log4j: Renaming file logs\pos.log.19 to logs\pos.log.20 > > > > log4j: Renaming file logs\pos.log.18 to logs\pos.log.19 > > > > log4j: Renaming file logs\pos.log.17 to logs\pos.log.18 > > > > log4j: Renaming file logs\pos.log.16 to logs\pos.log.17 > > > > log4j: Renaming file logs\pos.log.15 to logs\pos.log.16 > > > > log4j: Renaming file logs\pos.log.14 to logs\pos.log.15 > > > > log4j: Renaming file logs\pos.log.13 to logs\pos.log.14 > > > > log4j: Renaming file logs\pos.log.12 to logs\pos.log.13 > > > > log4j: Renaming file logs\pos.log.11 to logs\pos.log.12 > > > > log4j: Renaming file logs\pos.log.10 to logs\pos.log.11 > > > > log4j: Renaming file logs\pos.log.9 to logs\pos.log.10 > > > > log4j: Renaming file logs\pos.log.8 to logs\pos.log.9 > > > > log4j: Renaming file logs\pos.log.7 to logs\pos.log.8 > > > > log4j: Renaming file logs\pos.log.6 to logs\pos.log.7 > > > > log4j: Renaming file logs\pos.log.5 to logs\pos.log.6 > > > > log4j: Renaming file logs\pos.log.4 to logs\pos.log.5 > > > > log4j: Renaming file logs\pos.log.3 to logs\pos.log.4 > > > > log4j: Renaming file logs\pos.log to logs\pos.log.1 > > > > log4j: setFile called: logs/pos.log, false > > > > log4j: setFile ended > > > >=20 > > > > ...=20 > > > >=20 > > > > log4j: rolling over count=3D65682 > > > > log4j: maxBackupIndex=3D20 > > > > log4j: Renaming file logs\pos.log.19 to logs\pos.log.20 > > > > log4j: Renaming file logs\pos.log.18 to logs\pos.log.19 > > > > log4j: Renaming file logs\pos.log.17 to logs\pos.log.18 > > > > log4j: Renaming file logs\pos.log.16 to logs\pos.log.17 > > > > log4j: Renaming file logs\pos.log.15 to logs\pos.log.16 > > > > log4j: Renaming file logs\pos.log.14 to logs\pos.log.15 > > > > log4j: Renaming file logs\pos.log.13 to logs\pos.log.14 > > > > log4j: Renaming file logs\pos.log.12 to logs\pos.log.13 > > > > log4j: Renaming file logs\pos.log.11 to logs\pos.log.12 > > > > log4j: Renaming file logs\pos.log.10 to logs\pos.log.11 > > > > log4j: Renaming file logs\pos.log.9 to logs\pos.log.10 > > > > log4j: Renaming file logs\pos.log.8 to logs\pos.log.9 > > > > log4j: Renaming file logs\pos.log.7 to logs\pos.log.8 > > > > log4j: Renaming file logs\pos.log.6 to logs\pos.log.7 > > > > log4j: Renaming file logs\pos.log.5 to logs\pos.log.6 > > > > log4j: Renaming file logs\pos.log.4 to logs\pos.log.5 > > > > log4j: Renaming file logs\pos.log to logs\pos.log.1 > > > > log4j: setFile called: logs/pos.log, false > > > > log4j: setFile ended > > > >=20 > > > > =20 > > > > Regards > > > > Joacim J=E4rkeborn > > > > IT Architect > > > >=20 > > > > =20 > > > >=20 > > >=20 > > >=20 > >=20 > --------------------------------------------------------------------- > > > To unsubscribe, e-mail: log4j-user-unsubscribe@logging.apache.org > > > For additional commands, e-mail:=20 > log4j-user-help@logging.apache.org > > >=20 > > >=20 > >=20 > >=20 > --------------------------------------------------------------------- > > To unsubscribe, e-mail: log4j-user-unsubscribe@logging.apache.org > > For additional commands, e-mail: log4j-user-help@logging.apache.org > >=20 > >=20 >=20 > --------------------------------------------------------------------- > To unsubscribe, e-mail: log4j-dev-unsubscribe@logging.apache.org > For additional commands, e-mail: log4j-dev-help@logging.apache.org >=20 >=20 --------------------------------------------------------------------- To unsubscribe, e-mail: log4j-dev-unsubscribe@logging.apache.org For additional commands, e-mail: log4j-dev-help@logging.apache.org