I am using tomcat to run jsp file,
my question is how can force my server to create log file ?

I'm new into tomcat, so please be gentle.


You can use the JAVA_OPTS environment variable.
It is similar to enabling gc logging for a normal JVM just pass the same options in JAVA_OPTS and restart tomcat.

example on Linux:-

export JAVA_OPTS=-verbose:gc -Xloggc:logfile

the above should work, but remember the 'logfile' will be cleared at every JVM restart.

Be a part of the DaniWeb community

We're a friendly, industry-focused community of 1.20 million developers, IT pros, digital marketers, and technology enthusiasts learning and sharing knowledge.