-----BEGIN PGP SIGNED MESSAGE----- Hash: SHA256 David,
On 4/9/13 3:18 PM, David kerber wrote: > My system has several instances of TC 7.0.22, running on windows > server 2008 R2, and JRE 6.0.27. And yes, I know both TC and Java > could use an update... > > The TC instances are all running the same webapp, as a Windows > service, though not all have the exact same version of the webapp. > Each is running from its own catalina.base directory, but all have > the same catalina.home. Each instance is listening on a different > TCP port, and everything is working fine, handling several hundred > requests per second. > > What I'd like to do is develop an easier way of monitoring each > instance than what I have now. In particular, I'd like to get > visibility to a couple of the webapp's internal variables (they're > counters), as well as being able to stop and restart the instances > if necessary. My current method is that the app has a browser page > that I can log into and see the variables of interest, and I use > tomcat7w to control the service instances. Of course, that > requires me to log into each one of them individually to check on > them. That requirement for separate logins is what I'd like to > eliminate if possible. > > Is this even remotely doable from (ideally) another webapp running > on the same server, or maybe an external non-browser app? Or am I > just dreaming? Can JMX allow me to see internal application > variables and control services? Since you've already got your own "snooping" page set up, you might want to stick with that unless it's really not meeting your needs. When we deploy servers, we deploy the manager webapp, lock it down to only allow localhost access, and expose the JMXProxyServlet to allow external processes to peek at the JMX-exposed data from the JVM and Tomcat. We happen to aggregate that data using Nagios, but you could do pretty much anything you wanted to do with that data. I have never written by own JMX bean and published it out to JMX -- not sure how hard that is, but it shouldn't be too difficult. See http://wiki.apache.org/tomcat/FAQ/Monitoring for more information about monitoring the JVM and Tomcat itself. If that kind of thing looks attractive to you, perhaps exposing some application data via JMX will be the most convenient for you. - -chris -----BEGIN PGP SIGNATURE----- Version: GnuPG/MacGPG2 v2.0.17 (Darwin) Comment: GPGTools - http://gpgtools.org Comment: Using GnuPG with Thunderbird - http://www.enigmail.net/ iQIcBAEBCAAGBQJRZZQ8AAoJEBzwKT+lPKRYonIP/0ljMeZVcfH4yrAVT7PvGL2/ pm2SlbefY7biXqyFcTTihPIhM64gL1WIVY1N5XoRkvOf8C34jPOSUd4n3bz2KmKD zE6t5pR/OQxKwC2cblqir5i0e9n723i2Ej1zSOFiU3OMDak5u6EA6csF4On645jv W/PQMNIm2VQfpUgBvS5AC0sT2P332DCJuIbLTeFnWTUgVfk3Bi/AQZ4IqC061r7k 79o6J8YRaMlCS3R/3kLaC3/QMy8j9ri2nTy27SIJGKjUXM28OPr56volCSrwj7U9 JTSFZ3bAZtcn4gH6hLVG1XZBC3TXx0VRDFkJm+pNOlno4gXF/YoTP3tU20I25AIR T2tN8Bia+LjrNrNAr4mklfkOFsforhaYhnPIzIUBOeI6SaSekaWWzP+9fz2YgV34 gXaanC3CORZyfjEuN1WOA6H5ZYkeasJqNYpzOHXdanLHAZIX9P6SgXom6AkaHEQr Fcuj1jHy/yMEpRqw0hhHpSQIJm1ONAbLs7q6hLaxiUeJHuTtTmfiIe0OBLCanS8w 21sagVepNqZswv/GlEVAQ6UobEo3MLmx3uZkcxrLoNJ6BlKAHCm2FiWkRGmgGmSn qMPBmAV8MBTS+1qO3Hv9kOb0IinLNxwzDWim7PTmVBZdInKIue6zEBqt06uedEQP Db5jZBmlMgp+IERb+4bF =ma3B -----END PGP SIGNATURE----- --------------------------------------------------------------------- To unsubscribe, e-mail: users-unsubscr...@tomcat.apache.org For additional commands, e-mail: users-h...@tomcat.apache.org