Problem:
- Product Name: Borland AppServer
- Product Version: 5.x, 6.x
- Product Component: Apache, IIOP connector, Web container
- Platform/OS Version: ALL
How to log web application's access record running on BES?
Resolution:
There are three modules you can turn logging on, Apache web server, IIOP connector and tomcat web container.
(1) For Apache web server, you may specify output file name and log format by parameters in CustomLog
directive of configuration file;
/var/domains/base/configurations//mos/apache/conf/httpd.conf
"/var/domains/base/configurations//mos/apache" is the root directory of log file.
If you specify logs/access_log,
/var/domains/base/configurations//mos/apache/logs/access_log
will be generated. There are four pre-defined format:combined, common, referer and agent. For format's details, please refer to the page below:
http://httpd.apache.org/docs/2.2/mod/mod_log_config.html
(2) For IIOP connector, there are two directives, IIopLogFile for specify log file name and directory, IIopLogLevel for specify message's level, i.e., debug, warn, info and error(default is error) in the configuration file;
/var/domains/base/configurations//mos/apache/conf/httpd.conf
(3) For tomcat web container, use AccessLogValve to enable logging by uncomment
Valve classname="org.apache.catalina.valves.AccessLogValve"
in configuration file
/var/domains/base/configurations/mos/adm/tomcat/conf/server.xml
parameters:
- directory - specify log directory, root is
"/var/domains/base/configurations/mos/adm/tomcat"
- prefix - specify fixed part in log file name.
- suffix - specify log file's extention.
- pattern - specify log pattern.
Please refer to the page below for format characters;
https://tomcat.apache.org/tomcat-7.0-doc/api/org/apache/catalina/valves/AccessLogValve.html
- resolveHosts
- true = covert IP into hostname getting from DNS server
- false = not convert IP into hostname
- rotatable - specify whether rotate log or not(default is rotate), not rotate log if set to false.
- fileDateFormat - specify logfile's date format(default is yyyy-MM-dd).
This indicates also rotate interval by the last element of the format. "dd" means rotates by a day. It will rotates by an hour when specify "yyyy-MM-dd.HH".
#Security
#logging
#VisiBroker




