Creating wrapper to capture pid.

I am in the process to trying to add TeamCity to a running instance on Monit on our server and have encountered a roadblock that I wonder if anybody else had been able to resolve.  In the examples I have seen, when an app does not create a .pid file when being started this can be done using a wrapper that can do this.  The example on the Monit site are ok, but I wanted to see if anybody had a good TeamCity specific example that I could run with.  Any help on this would be greatly appreciated.

Thanks,
- John Orlandella Jr.

3 comments
Comment actions Permalink

John,

Do you want to monitor TeamCity server? If yes, then it is actually a Tomcat server and you can probably search for the solution applicable to Tomcat.

0
Comment actions Permalink

I was figuring that might be the solution to work toward, and have started digging in that direction, but the problem still is that the implementation of Tomcat with TeamCity does not set up a tomcat.pid file under /var/run.  I noticed that the teamcity-server.sh file points to catalina.sh, which in turn points to tomcat.  Also, I when looking at running the top command, I only see java running and no instance of tomcat or catalina.  Once I have the pid file created (of whatever process that should be monitered), I can take the next step of starting and stopping the app.

Thanks,
- John

0
Comment actions Permalink

John,

Tomcat web server is a java process, so it is the one you need. Also, there are lots of posting on this, e.g. try first severl links.

> Once I have the pid file created (of whatever process that should be  monitered), I can take the next step of starting and stopping the app.

Please note that it is recommended to use supplied teamcity-server script to run and stop TeamCity.

0

Please sign in to leave a comment.