logging-log4j-user mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Chaohua Wang" <chaohua.w...@premierdata.com>
Subject RE: How to get remote log info with chainsaw?
Date Mon, 27 Feb 2006 18:41:30 GMT
Hi, Scott,

The PatternLayout is ConversionPattern. I use %-p, before was %-5p.
But problem is still there. All Levels are DEBUG.
Please see me log4j.xml below this message.
Thank you.

Chaohua


   <appender name="MYLogJBoss" class="org.apache.log4j.FileAppender">
      <errorHandler
class="org.apache.log4j.helpers.OnlyOnceErrorHandler"/> 
      <param name="File" value="D:/Outputs/logs/MYJBoss.log"/>
      <param name="Append" value="false"/>


      <layout class="org.apache.log4j.PatternLayout">
         <param name="ConversionPattern" value="%d %-5r %-p [%c] (%t:%x)
%m%n"/>
          
      </layout>
   </appender>



-----Original Message-----
From: Scott Deboy [mailto:sdeboy@comotivsystems.com] 
Sent: Friday, February 24, 2006 4:29 PM
To: Log4J Users List
Subject: RE: How to get remote log info with chainsaw?

What patternLayout are you using to create the log file?  

Folks often truncate the severity using %5p to make the severity entries
in the log line up, which causes a problem in Chainsaw because it's
looking for the full name of the severity to display (use %p if you can
in this case).

Scott Deboy
COMOTIV SYSTEMS
111 SW Columbia Street Ste. 950
Portland, OR  97201

Telephone:      503.224.7496
Cell:           503.997.1367
Fax:            503.222.0185

sdeboy@comotivsystems.com

www.comotivsystems.com



-----Original Message-----
From: Chaohua Wang [mailto:chaohua.wang@premierdata.com]
Sent: Fri 2/24/2006 2:09 PM
To: Log4J Users List
Subject: RE: How to get remote log info with chainsaw?
 
Thank you so much, Great explanation.
I am just going to use http:// to make remote monitoring.
I have a last question. 
>From my event panel, I saw level column, all are "DEBUG". 
I am not sure reason why. I checked my log4j.xml, chainsaw.xml, and my
codes
All I have set is "INFO". And some ERROR from code, showing still
"DEBUG" in event panel. Please help.

Chaohua   
 

-----Original Message-----
From: Scott Deboy [mailto:sdeboy@comotivsystems.com] 
Sent: Friday, February 24, 2006 1:45 PM
To: Log4J Users List
Subject: RE: How to get remote log info with chainsaw?

hIf you are trying to read a log file you have two options:
 - LogFilePatternReceiver if the log file is accessible via a standard 
   URI (file://, http://)
 - VFSlogFilePatternReceiver if the log file is accessible one of
Jakarta 
   commons-vfs supported file systems

See Chainsaw's home page for information on how to configure
VFSLogFilePatternReceiver.

Note: Chainsaw includes Javadoc for all of these receivers.

If you are using log4j 1.2.x, you can use SocketAppender/SocketReceiver
or SocketHubAppender/SocketHubReceiver

If you can use log4j 1.3, you also have
MulticastAppender/MulticastReceiver, UDPAppender/UDPReceiver

Here is an explanation of the two Socket-based options:

These two options assume tcp connections can be initiated from one side
or the other:

1. SocketAppender & SocketReceiver
 - server config includes a SocketAppender section -per Chainsaw client-
  (specify Chainsaw client ip and port)
 - Chainsaw client config includes a single SocketReceiver section
  (specify port only)

Drawbacks:
The server has to know the IP address and ports of target Chainsaw
clients (must change configuration on server to run Chainsaw from a
different machine and receive events).

Pros:
If you are firewalled in such a way that the server can make outgoing
connections but incoming connections aren't allowed from the machines
using Chainsaw, this may work

2. SocketHubAppender & SocketHubReceiver
 - server config includes a -single- SocketHubAppender configuration 
   (specify port only)
 - Chainsaw client config includes SocketHubReceiver section
   (specify server ip and port)

Drawbacks:
May not work if client can't initiate connections to server

Pros:
You can debug from a different machine only by configuring Chainsaw on
the new machine.


Hope this helps,


Scott Deboy
COMOTIV SYSTEMS
111 SW Columbia Street Ste. 950
Portland, OR  97201

Telephone:      503.224.7496
Cell:           503.997.1367
Fax:            503.222.0185

sdeboy@comotivsystems.com

www.comotivsystems.com



-----Original Message-----
From: Chaohua Wang [mailto:chaohua.wang@premierdata.com]
Sent: Fri 2/24/2006 9:29 AM
To: Log4J Users List
Subject: How to get remote log info with chainsaw?
 

Hi,

We have a couple of developers, would like to monitor remote server log
info. I am not sure which receiver (MulticastReceiver, Socketreceiver)I
need to use and setup.

Currently I know how to set up from localhost (Thank you, Scott). 
>From chainsaw.xml file, I can point to my log file. 
But from remote, do I need to do that?

I check File menu.
There is four item, load log4j, load Java Util File, load Remote log4j,
load remote util file, what are these files I need to load? 
Thank you very much for your help!

Chaohua
 

 



---------------------------------------------------------------------
To unsubscribe, e-mail: log4j-user-unsubscribe@logging.apache.org
For additional commands, e-mail: log4j-user-help@logging.apache.org




---------------------------------------------------------------------
To unsubscribe, e-mail: log4j-user-unsubscribe@logging.apache.org
For additional commands, e-mail: log4j-user-help@logging.apache.org




---------------------------------------------------------------------
To unsubscribe, e-mail: log4j-user-unsubscribe@logging.apache.org
For additional commands, e-mail: log4j-user-help@logging.apache.org


Mime
View raw message