Posted on 2005-03-24
Medium Priority
Last Modified: 2008-01-09

I have several java applivation working in the network and am now looking for a good maintenance method to it.
I thought of using SNMP to be independent. As i am new to SNMP i might have some conceptional erros, that' s why i am asking if my idea sounds good....

I decided on SNMP as all mangement tools i know support this (e.g. HP, MON,...)

As far as I know SNMP supports two kinds of logging.

SNMP Trap means sending unasked information in the network? Of course there should be a snmp service collecting it...

interaction with program to get status and logging information or recieve events.

As all my java apps use java.util.logging
I thought of implementing a new LogHandler who does nothing then piping the java.util.logger. messages to the SNMP Server via SNMP so a SNMPHandler for java.util.logging

Additional I wanted to add the functionality to this loghandler to filter all logmessages for predefined keywords. and upon occurence of one of those fire an event for the SNMP Management. As I have limited all Logmessages to special ErrorCodes this will mean no change to the code of any of my apps.

for this task i found two open source libs:

second seems to be the better.

Can anyone help me fullfilling my task (implementing a SnmpLogHandler) with the following fetaures:
1.) dump logmessages to snmp Management
2.) fire events to snmp Management

All hints and explanation and of course code snippets are welcome

Question by:mightyone
Welcome to Experts Exchange

Add your voice to the tech community where 5M+ people just like you are talking about what matters.

  • Help others & share knowledge
  • Earn cash & points
  • Learn & ask questions
  • 3

Author Comment

ID: 13621019
another idea would be to set up a new JavaBased Server witch accepts continious logging from the java apps by configuring the logging to be of type java.util.logging.SocketHandler but then same problem with the snmp connection..

Assisted Solution

ucool earned 400 total points
ID: 13621950
By the way, to manage Java applications, you can use JMX. More info can be seen from: http://java.sun.com/products/JavaManagement/
LVL 15

Accepted Solution

aozarov earned 1600 total points
ID: 13623428
>> I thought of implementing a new LogHandler who does nothing then piping the java.util.logger. messages to the SNMP Server via SNMP so a SNMPHandler for java.util.logging
You can use this known appender for that: http://www.m2technologies.net/asp/snmpTrapAppender.asp
This appender will send Traps to an NMS based on your log4j messages.

I recommend using www.sf.net/projects/joesnmp which is an easy to use LGPL Java based snmp stack for any other snmp requirements: like collecting data from agents.
BTW, the above appender is using joesnmp as well.

I agree with ucool that JMX with an rmi connector (or similar) can provide the means to manage Java applications remotely.

Author Comment

ID: 13624038
Thanks so far will start checking your hints after easter.....

happy easter folks!

Author Comment

ID: 13650086
Wow that is what I was looking for,

thanks !

Featured Post

Independent Software Vendors: We Want Your Opinion

We value your feedback.

Take our survey and automatically be enter to win anyone of the following:
Yeti Cooler, Amazon eGift Card, and Movie eGift Card!

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

After being asked a question last year, I went into one of my moods where I did some research and code just for the fun and learning of it all.  Subsequently, from this journey, I put together this article on "Range Searching Using Visual Basic.NET …
Java had always been an easily readable and understandable language.  Some relatively recent changes in the language seem to be changing this pretty fast, and anyone that had not seen any Java code for the last 5 years will possibly have issues unde…
This tutorial covers a step-by-step guide to install VisualVM launcher in eclipse.
This tutorial will introduce the viewer to VisualVM for the Java platform application. This video explains an example program and covers the Overview, Monitor, and Heap Dump tabs.
Suggested Courses
Course of the Month14 days, 3 hours left to enroll

801 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question