To configure the general logging settings using the Admin Console:
For the developer profile, go to Application Server -> Logging -> General
For the cluster and enterprise profiles, go to Configurations -> Configuration -> Logging Settings -> General
On the General page, enter appropriate values to customize logging to your requirements. Stop and restart the Enterprise Server.
For details on setting the various configuration parameters, click Help in the Admin Console.
To configure these log settings in asadmin, use the get and set commands.
You can use the com.sun.enterprise.server.logging.max_history_files system property to limit the number of rotated log files for both access logging and the server log. The property specifies the maximum number of access log files to keep, starting with the most recent ones.
If the property is not set, then no history files cleanup is done.
If the property is set and it's either an invalid number or null, then a default of 10 history files is kept.
If the property is set to 0, then no history files are kept.
In the Admin Console, access the config/server that this system property needs to be set for. On the command line, use the create-jvm-option command.