When installing Smart IT using the bundled tomcat option, Tomcat’s Access Log (i.e. ‘<tomcat>\logs\ localhost_access_log.<date>.txt’) would automatically include the following information for each handled request:
This information can be helpful when troubleshooting Smart IT Application issues. The screenshot below shows an example line from the Access Log of such a bundled Tomcat installation: Not all these details may be included in the log in case Smart IT was installed against an existing Tomcat instance that only has the default logging options enabled. Also, as Tomcat is no longer bundled with the Smart IT installer from version 20.02 onwards, how can these extra details be enabled in the Tomcat Access Log? |
This knowledge article may contain information that does not apply to version 21.05 or later which runs in a container environment. Please refer to Article Number 000385088 for more information about troubleshooting BMC products in containers. This can be configured in Tomcat’s ‘server.xml’ file (located in the ‘<tomcat>/conf’ folder). A default Tomcat installation is likely to have the following pattern configured for the Access Logging in that file: <Valve className="org.apache.catalina.valves.AccessLogValve" directory="logs"
prefix="localhost_access_log" suffix=".txt" pattern="%h %l %u %t "%r" %s %b" /> Update the pattern section as indicated below to include the extra details in Tomcat’s Access Log and restart Tomcat: <Valve className="org.apache.catalina.valves.AccessLogValve" directory="logs"
prefix="localhost_access_log" suffix=".txt" pattern="%h %l %u %t "%r" %s %b bytes %D ms %I %S" /> Note: For full details on the supported pattern codes, please refer to the Apache Tomcat Configuration Reference page. |