For easier troubleshooting, you can dictate that certain database requests get logged
in a handy central log file.
For example, database requests that run longer than 10 seconds are likely
candidates for troubleshooting. You can have such requests automatically logged in the
vamessages.log file for your inspection. The exact length of
time after which a request becomes problematic depends on your environment.
How it
works:
- All database queries are logged at DEBUG level by default.
- By default, the vamessages.log file is configured to
include all events logged at the INFO level or higher.
- Database queries that run over a configurable time limit are logged at INFO
rather than DEBUG, which causes them to appear in
vamessages.log.
-
Stop CollabNet
TeamForge.
Note: If your site is running on multiple machines, stop all the
machines.
-
/etc/init.d/collabnet stop all
-
Open the master site configuration file in a text editor.
For example:
-
vi /opt/collabnet/teamforge-installer/5.4.0.0/conf/site-options.conf
-
In the site-options.conf file, change the value of the
LOG_QUERY_TIME_THRESHOLD variable to a value, in
milliseconds, that makes sense for your environment.
-
Rebuild the runtime environment.
-
./install.sh -V -r -d
<SITE_DIR>
-
Start CollabNet
TeamForge.
- On Red Hat or CentOS:
-
/etc/init.d/httpd start (On CentOS, you
may need to start Apache manually: /sbin/chkconfig
--level 2345 httpd on)
-
/etc/init.d/postgresql start
-
/etc/init.d/collabnet start
- On SuSE:
-
/etc/init.d/apache2 start
-
/etc/init.d/postgresql start
-
/etc/init.d/collabnet start