Log4j problem.

classic Classic list List threaded Threaded
3 messages Options
Reply | Threaded
Open this post in threaded view
|

Log4j problem.

Doug Tanner-2
Heading One

I have read the different threads dealing with Log4j problems, but none of them seem to have posted the fix/conclusion to the problem.

 

Here is my wrapper.log file:

 

STATUS | wrapper  | 2006/01/30 08:42:25 | --> Wrapper Started as Service

DEBUG  | wrapper  | 2006/01/30 08:42:25 | Using system timer.

DEBUG  | wrapperp | 2006/01/30 08:42:25 | server listening on port 32000.

STATUS | wrapper  | 2006/01/30 08:42:25 | Launching a JVM...

DEBUG  | wrapper  | 2006/01/30 08:42:25 | command: "C:\oracle\ora92\jre\1.4.2\bin\java.exe" -Dlog4j.configuration=log4j.xml -Dconnection.properties=relatl.connection.properties -Xms256m -Xmx256m -Djava.library.path="../lib;C:/bea81/jdk142_08/bin;C:/oracle/ora92/bin" -classpath "../lib/bsh-1.3b2.jar;../lib/coremessaging-client.jar;../lib/coremessaging.jar;../lib/junit-3_8_1.jar;../lib/wrapper.jar;../lib/wrappertest.jar;../lib/xalan.jar;../lib/xerces.jar;../lib/bf/cbm-client.jar;../lib/bf/cbm-support.jar;../lib/jakarta/commons-beanutils-1.7.0.jar;../lib/jakarta/commons-codec-1.3.jar;../lib/jakarta/commons-collections-3.1.jar;../lib/jakarta/commons-dbutils-1.0.jar;../lib/jakarta/commons-digester-1.5.jar;../lib/jakarta/commons-io-1.0.jar;../lib/jakarta/commons-lang-2.0.jar;../lib/jakarta/commons-logging-1.0.4.jar;../lib/jakarta/jakarta-oro-2.0.8.jar;../lib/jakarta/log4j-1_2_8.jar;../lib/security/BfRdbmsAuthenticator.jar;../lib/security/SecurityActionInterface.jar;../lib/security/SecurityAdapters.jar;../lib/security/SecurityCommon.jar;../lib/quartz/commons-dbcp-1.1.jar;../lib/quartz/commons-pool-1.1.jar;../lib/quartz/jdbc2_0-stdext.jar;../lib/quartz/quartz.jar" -Dwrapper.key="YGAyFo_tJZF4dQUs" -Dwrapper.port=32000 -Dwrapper.debug="TRUE" -Dwrapper.use_system_time="TRUE" -Dwrapper.version="3.1.2" -Dwrapper.native_library="wrapper" -Dwrapper.service="TRUE" -Dwrapper.cpu.timeout="10" -Dwrapper.jvmid=1 org.tanukisoftware.wrapper.WrapperSimpleApp bf.cbm.util.scheduler.SchedulerManager addSampleJob

DEBUG  | wrapper  | 2006/01/30 08:42:25 | JVM started (PID=1200)

INFO   | jvm 1    | 2006/01/30 08:42:25 | WrapperManager class initialized by thread: main  Using classloader: sun.misc.Launcher$AppClassLoader@e80a59

INFO   | jvm 1    | 2006/01/30 08:42:25 | Wrapper Manager: JVM #1

INFO   | jvm 1    | 2006/01/30 08:42:25 | Wrapper Manager: Registering shutdown hook

INFO   | jvm 1    | 2006/01/30 08:42:25 | Wrapper Manager: Using wrapper

INFO   | jvm 1    | 2006/01/30 08:42:25 | Loaded native library: wrapper.dll

INFO   | jvm 1    | 2006/01/30 08:42:25 | Calling native initialization method.

INFO   | jvm 1    | 2006/01/30 08:42:25 | Initializing WrapperManager native library.

INFO   | jvm 1    | 2006/01/30 08:42:25 | Java Executable: C:\oracle\ora92\jre\1.4.2\bin\java.exe

INFO   | jvm 1    | 2006/01/30 08:42:25 | Windows version: 5.1.2600

INFO   | jvm 1    | 2006/01/30 08:42:25 | Java Version   : 1.4.2_03-b02 Java HotSpot(TM) Client VM

INFO   | jvm 1    | 2006/01/30 08:42:25 | Java VM Vendor : Sun Microsystems Inc.

INFO   | jvm 1    | 2006/01/30 08:42:25 |

INFO   | jvm 1    | 2006/01/30 08:42:25 | Wrapper (Version 3.1.2) http://wrapper.tanukisoftware.org

INFO   | jvm 1    | 2006/01/30 08:42:25 |

INFO   | jvm 1    | 2006/01/30 08:42:25 | WrapperManager.start(org.tanukisoftware.wrapper.WrapperSimpleApp@1e51060, args["addSampleJob"]) called by thread: main

INFO   | jvm 1    | 2006/01/30 08:42:25 | Open socket to wrapper...

INFO   | jvm 1    | 2006/01/30 08:42:25 | Opened Socket

INFO   | jvm 1    | 2006/01/30 08:42:25 | Send a packet KEY : YGAyFo_tJZF4dQUs

INFO   | jvm 1    | 2006/01/30 08:42:25 | handleSocket(Socket[addr=/127.0.0.1,port=32000,localport=4427])

DEBUG  | wrapperp | 2006/01/30 08:42:25 | accepted a socket from 127.0.0.1 on port 4427

DEBUG  | wrapperp | 2006/01/30 08:42:25 | read a packet KEY : YGAyFo_tJZF4dQUs

DEBUG  | wrapper  | 2006/01/30 08:42:25 | Got key from JVM: YGAyFo_tJZF4dQUs

DEBUG  | wrapperp | 2006/01/30 08:42:25 | send a packet LOW_LOG_LEVEL : 1

DEBUG  | wrapperp | 2006/01/30 08:42:25 | send a packet PING_TIMEOUT : 30

DEBUG  | wrapper  | 2006/01/30 08:42:25 | Start Application.

DEBUG  | wrapperp | 2006/01/30 08:42:25 | send a packet START : start

INFO   | jvm 1    | 2006/01/30 08:42:25 | Received a packet LOW_LOG_LEVEL : 1

INFO   | jvm 1    | 2006/01/30 08:42:25 | Wrapper Manager: LowLogLevel from Wrapper is 1

INFO   | jvm 1    | 2006/01/30 08:42:25 | Received a packet PING_TIMEOUT : 30

INFO   | jvm 1    | 2006/01/30 08:42:25 | Wrapper Manager: PingTimeout from Wrapper is 30000

INFO   | jvm 1    | 2006/01/30 08:42:25 | Received a packet START : start

INFO   | jvm 1    | 2006/01/30 08:42:25 | calling listener.start()

INFO   | jvm 1    | 2006/01/30 08:42:25 | WrapperSimpleApp: start(args)

INFO   | jvm 1    | 2006/01/30 08:42:25 | WrapperSimpleApp: invoking main method

INFO   | jvm 1    | 2006/01/30 08:42:25 | log4j:WARN No appenders could be found for logger (bf.cbm.util.io.Loader).

INFO   | jvm 1    | 2006/01/30 08:42:25 | log4j:WARN Please initialize the log4j system properly.

INFO   | jvm 1    | 2006/01/30 08:42:27 | WrapperSimpleApp: main method completed

INFO   | jvm 1    | 2006/01/30 08:42:27 | WrapperSimpleApp: start(args) end.  Main Completed=true, exitCode=null

INFO   | jvm 1    | 2006/01/30 08:42:27 | returned from listener.start()

INFO   | jvm 1    | 2006/01/30 08:42:27 | Send a packet STARTED :

DEBUG  | wrapperp | 2006/01/30 08:42:27 | read a packet STARTED :

DEBUG  | wrapper  | 2006/01/30 08:42:27 | JVM signalled that it was started.

DEBUG  | wrapperp | 2006/01/30 08:42:29 | send a packet PING : ping

INFO   | jvm 1    | 2006/01/30 08:42:29 | Received a packet PING : ping

INFO   | jvm 1    | 2006/01/30 08:42:29 | Send a packet PING : ok

DEBUG  | wrapperp | 2006/01/30 08:42:29 | read a packet PING : ok

DEBUG  | wrapper  | 2006/01/30 08:42:29 | Got ping response from JVM

DEBUG  | wrapper  | 2006/01/30 08:42:29 | ServiceControlHandler(1)

DEBUG  | wrapper  | 2006/01/30 08:42:29 |   SERVICE_CONTROL_STOP

DEBUG  | wrapper  | 2006/01/30 08:42:29 | wrapperStopProcess(0) called.

DEBUG  | wrapper  | 2006/01/30 08:42:29 | Sending stop signal to JVM

DEBUG  | wrapperp | 2006/01/30 08:42:29 | send a packet STOP : NULL

INFO   | jvm 1    | 2006/01/30 08:42:29 | Received a packet STOP :

INFO   | jvm 1    | 2006/01/30 08:42:29 | Thread, Wrapper-Connection, handling the shutdown process.

INFO   | jvm 1    | 2006/01/30 08:42:29 | calling listener.stop()

INFO   | jvm 1    | 2006/01/30 08:42:29 | WrapperSimpleApp: stop(0)

INFO   | jvm 1    | 2006/01/30 08:42:29 | returned from listener.stop()

INFO   | jvm 1    | 2006/01/30 08:42:29 | Send a packet STOPPED : 0

DEBUG  | wrapperp | 2006/01/30 08:42:29 | read a packet STOPPED : 0

DEBUG  | wrapper  | 2006/01/30 08:42:29 | JVM signalled that it was stopped.

INFO   | jvm 1    | 2006/01/30 08:42:30 | Closing socket.

DEBUG  | wrapperp | 2006/01/30 08:42:30 | socket read no code (closed?).

INFO   | jvm 1    | 2006/01/30 08:42:30 | calling System.exit(0)

DEBUG  | wrapper  | 2006/01/30 08:42:30 | JVM process exited with a code of 0, leaving the wrapper exit code set to 0.

DEBUG  | wrapper  | 2006/01/30 08:42:30 | JVM exited normally.

STATUS | wrapper  | 2006/01/30 08:42:30 | <-- Wrapper Stopped

 

And here is my wrapper.conf file:

 

#********************************************************************

# TestWrapper Properties

#

# NOTE - Please use src/conf/wrapper.conf.in as a template for your

#        own application rather than the values used for the

#        TestWrapper sample.

#********************************************************************

# Java Application

wrapper.java.command=java

 

# Java Main class.  This class must implement the WrapperListener interface

#  or guarantee that the WrapperManager class is initialized.  Helper

#  classes are provided to do this for you.  See the Integration section

#  of the documentation for details.

wrapper.java.mainclass=org.tanukisoftware.wrapper.WrapperSimpleApp

 

# Java Classpath (include wrapper.jar)  Add class path elements as

#  needed starting from 1

wrapper.java.classpath.1=../lib/*.jar

wrapper.java.classpath.2=../lib/bf/*.jar

wrapper.java.classpath.3=../lib/jakarta/*.jar

wrapper.java.classpath.4=../lib/security/*.jar

wrapper.java.classpath.5=../lib/quartz/*.jar

 

# Java Library Path (location of Wrapper.DLL or libwrapper.so)

wrapper.java.library.path.1=../lib

wrapper.java.library.path.2=C:/bea81/jdk142_08/bin

wrapper.java.library.path.3=C:/oracle/ora92/bin

 

# Java Additional Parameters

wrapper.java.additional.1=-Dlog4j.configuration=log4j.xml

wrapper.java.additional.2=-Dconnection.properties=relatl.connection.properties

 

 

# Initial Java Heap Size (in MB)

wrapper.java.initmemory=256

 

# Maximum Java Heap Size (in MB)

wrapper.java.maxmemory=256

 

# Application parameters.  Add parameters as needed starting from 1

wrapper.app.parameter.1=bf.cbm.util.scheduler.SchedulerManager

wrapper.app.parameter.2=addSampleJob

 

 

 

#********************************************************************

# Wrapper Logging Properties

#********************************************************************

# Format of output for the console.  (See docs for formats)

wrapper.console.format=PM

 

# Log Level for console output.  (See docs for log levels)

wrapper.console.loglevel=debug

 

# Log file to use for wrapper output logging.

wrapper.logfile=../logs/wrapper.log

 

# Format of output for the log file.  (See docs for formats)

wrapper.logfile.format=LPTM

 

# Log Level for log file output.  (See docs for log levels)

wrapper.logfile.loglevel=debug

 

# Maximum size that the log file will be allowed to grow to before

#  the log is rolled. Size is specified in bytes.  The default value

#  of 0, disables log rolling.  May abbreviate with the 'k' (kb) or

#  'm' (mb) suffix.  For example: 10m = 10 megabytes.

wrapper.logfile.maxsize=0

 

# Maximum number of rolled log files which will be allowed before old

#  files are deleted.  The default value of 0 implies no limit.

wrapper.logfile.maxfiles=0

 

# Log Level for sys/event log output.  (See docs for log levels)

wrapper.syslog.loglevel=NONE

 

wrapper.debug=true

 

#********************************************************************

# Wrapper Windows Properties

#********************************************************************

# Title to use when running as a console

wrapper.console.title=Quartz Job Scheduler

 

#********************************************************************

# Wrapper Windows NT/2000/XP Service Properties

#********************************************************************

# WARNING - Do not modify any of these properties when an application

#  using this configuration file has been installed as a service.

#  Please uninstall the service before modifying this section.  The

#  service can then be reinstalled.

 

# Name of the service

wrapper.ntservice.name=SchedulerManager

 

# Display name of the service

wrapper.ntservice.displayname=SchedulerManager

 

# Description of the service

wrapper.ntservice.description=SchedulerManager Test

 

# Service dependencies.  Add dependencies as needed starting from 1

wrapper.ntservice.dependency.1=

 

# Mode in which the service is installed.  AUTO_START or DEMAND_START

wrapper.ntservice.starttype=AUTO_START

 

# Allow the service to interact with the desktop.

wrapper.ntservice.interactive=false

 

Can anyone tell me if they see a problem with this setup?  I cannot seem to get the wrapper to use the log4j.xml file so that I can monitor the output of the java program that it is running.

 

Thanks,

 

Doug Tanner

 

***************************************************************************************
BENEFITFOCUS.COM CONFIDENTIALITY NOTICE: This electronic message is intended only for the individual or entity to which it is addressed and may contain information that is confidential and protected by law. Unauthorized review, use, disclosure, or dissemination of this communication or its contents in any way is prohibited and may be unlawful. If you are not the intended recipient or a person responsible for delivering this message to an intended recipient, please notify the original sender immediately by e-mail or telephone, return the original message to the original sender or to [hidden email], and destroy all copies or derivations of the original message. Thank you. (BFeComNote Rev. 08/01/2005)
***************************************************************************************

Reply | Threaded
Open this post in threaded view
|

Re: Log4j problem.

Leif Mortenson-2
Doug,
    I 'm not a bit log4j user myself.  I had to read over the log to
even see what
your problem is.  I assume it is the following two lines?

INFO   | jvm 1    | 2006/01/30 08:42:25 | log4j:WARN No appenders could
be found for logger (bf.cbm.util.io.Loader).
INFO   | jvm 1    | 2006/01/30 08:42:25 | log4j:WARN Please initialize
the log4j system properly.

    This is most likely because of a log4j configuration problem.  Ie
the configuration
is invalid or more likely, the config file is not being found.   Log4j
can locate its
configuration on the classpath or in your case by specifying a specific
log file
using a system property.

    I assume that the -Dlog4j.configuration=log4j.xml syntax is
correct.  This will be
looking for a file ./log4j.xml in the same directory as your
wrapper.exe.   Is that where
it is located?  Remember that all relative paths are relative to the
location of the
wrapper.exe.

Cheers,
Leif

Doug Tanner wrote:
>
> I have read the different threads dealing with Log4j problems, but
> none of them seem to have posted the fix/conclusion to the problem.
>
>  
>
> Here is my wrapper.log file:
>
<snip log file>
>
>  
> Can anyone tell me if they see a problem with this setup?  I cannot
> seem to get the wrapper to use the log4j.xml file so that I can
> monitor the output of the java program that it is running.
>



-------------------------------------------------------
This SF.net email is sponsored by: Splunk Inc. Do you grep through log files
for problems?  Stop!  Download the new AJAX search engine that makes
searching your log files as easy as surfing the  web.  DOWNLOAD SPLUNK!
http://sel.as-us.falkag.net/sel?cmd=lnk&kid=103432&bid=230486&dat=121642
_______________________________________________
Wrapper-user mailing list
[hidden email]
https://lists.sourceforge.net/lists/listinfo/wrapper-user
Reply | Threaded
Open this post in threaded view
|

RE: Log4j problem.

Doug Tanner-2
In reply to this post by Doug Tanner-2
Leif,

Yes, my log4j.xml is in the same folder as the wrapper.exe.  I know the
-Dlog4j.configuration=log4j.xml is correct b/c if I try to run my
program without the wrapper, it runs just fine.

Here is the command I use to run my program:

Java -Dlog4j.configuration=log4j.xml -Dlog4j.debug=true
-Dconnection.properties=test.connection.properties -classpath=[insert
all jars that I have included in the wrapper.conf file] -Xmx256m
bf.cbm.util.shecduler.SchedulerManager

I actually have a .bat file that runs the command.

Also, while trying to figure out this log4j problem, I have encountered
a new error.  Please see attachment for this new error.

Thanks for the help,

Doug Tanner

-----Original Message-----
From: [hidden email]
[mailto:[hidden email]] On Behalf Of Leif
Mortenson
Sent: Monday, January 30, 2006 9:35 PM
To: [hidden email]
Subject: Re: [Wrapper-user] Log4j problem.

Doug,
    I 'm not a bit log4j user myself.  I had to read over the log to
even see what
your problem is.  I assume it is the following two lines?

INFO   | jvm 1    | 2006/01/30 08:42:25 | log4j:WARN No appenders could
be found for logger (bf.cbm.util.io.Loader).
INFO   | jvm 1    | 2006/01/30 08:42:25 | log4j:WARN Please initialize
the log4j system properly.

    This is most likely because of a log4j configuration problem.  Ie
the configuration
is invalid or more likely, the config file is not being found.   Log4j
can locate its
configuration on the classpath or in your case by specifying a specific
log file
using a system property.

    I assume that the -Dlog4j.configuration=log4j.xml syntax is
correct.  This will be
looking for a file ./log4j.xml in the same directory as your
wrapper.exe.   Is that where
it is located?  Remember that all relative paths are relative to the
location of the
wrapper.exe.

Cheers,
Leif

Doug Tanner wrote:
>
> I have read the different threads dealing with Log4j problems, but
> none of them seem to have posted the fix/conclusion to the problem.
>
>  
>
> Here is my wrapper.log file:
>
<snip log file>
>
>  
> Can anyone tell me if they see a problem with this setup?  I cannot
> seem to get the wrapper to use the log4j.xml file so that I can
> monitor the output of the java program that it is running.
>



-------------------------------------------------------
This SF.net email is sponsored by: Splunk Inc. Do you grep through log
files
for problems?  Stop!  Download the new AJAX search engine that makes
searching your log files as easy as surfing the  web.  DOWNLOAD SPLUNK!
http://sel.as-us.falkag.net/sel?cmd=lnk&kid=103432&bid=230486&dat=121642
_______________________________________________
Wrapper-user mailing list
[hidden email]
https://lists.sourceforge.net/lists/listinfo/wrapper-user


****************************************************************************************
BENEFITFOCUS.COM CONFIDENTIALITY NOTICE: This electronic message is intended only for the individual or entity to which it is addressed and may contain information that is confidential and protected by law. Unauthorized review, use, disclosure, or dissemination of this communication or its contents in any way is prohibited and may be unlawful. If you are not the intended recipient or a person responsible for delivering this message to an intended recipient, please notify the original sender immediately by e-mail or telephone, return the original message to the original sender or to [hidden email], and destroy all copies or derivations of the original message. Thank you.  (BFeComNote Rev. 08/01/2005)
***************************************************************************************

wrappererror.txt (2K) Download Attachment