1

I'm new to Tomcat server.

I'm designing a tool that provides the statistics of hits(page views) in a tomcat server.
i.e . I want to design a monitoring tool that gives the data of hits from a customized particular time to present time(Drop down).

I'm using Jquery bar chart plugin to design the graphs based on hits w.r.t time.

How can I do this?

I'm doing it for a Ubuntu server (10.04). Java version -6 and Tomcat version 6.

Vasili Syrakis
  • 4,435
  • 3
  • 21
  • 29
user3004356
  • 111
  • 1
  • 2
  • You are looking for activating JMX mBeans (the Java counterpart to PerfMon) in your Tomcat. It takes a bit of googling to figure out activation and what mBean counter you need to pull statistics from. Try running VisualVM (bundled with Java JDK) locally for an easy start, then go remote JMX. Pathing is a bitch but you'll figure it out. – ErikE Feb 07 '14 at 06:01

2 Answers2

1

Tomcat can be configured to expose a jmx interface. Although I am not sure you would find Apache like access log files (note you can do it with an AccessLog valve in tomcat configuration), you would find a lot of useful information's like connector stats, JVM stats, etc

Take a look at this page for instance: http://tomcat.apache.org/tomcat-7.0-doc/monitoring.html

alxgomz
  • 1,600
  • 1
  • 10
  • 14
0

What you should probably do is configure Tomcat to write an access log, then read that log in with your reporting system.

There's plenty of software out there already that can handle reporting from web server logs well, so it may not be necessary to implement something from scratch for this.

Shane Madden
  • 112,982
  • 12
  • 174
  • 248