First yous need to run: jboss_home/standalone/bin/jboss-cli.sh together with connect.
//remove the default file handler /subsystem=logging/periodic-rotating-file-handler=FILE:remove //create the novel file handler /subsystem=logging/size-rotating-file-handler=FILE:add(file={"path"=>"server.log", "relative-to"=>"jboss.server.log.dir"}) /subsystem=logging/size-rotating-file-handler=FILE:write-attribute(name="autoflush", value="true") /subsystem=logging/size-rotating-file-handler=FILE:write-attribute(name="level", value="WARN") /subsystem=logging/size-rotating-file-handler=FILE:write-attribute(name="append", value="true") /subsystem=logging/size-rotating-file-handler=FILE:write-attribute(name="max-backup-index", value="10") /subsystem=logging/size-rotating-file-handler=FILE:write-attribute(name="rotate-size", value="5000k")
References:
https://access.redhat.com/site/documentation/en-US/JBoss_Enterprise_Application_Platform/6/html/Administration_and_Configuration_Guide/Configure_a_Periodic_Log_Handler_in_the_CLI1.html
https://access.redhat.com/site/documentation/en-US/JBoss_Enterprise_Application_Platform/6/html/Administration_and_Configuration_Guide/Sample_XML_Configuration_for_a_Size_Log_Handler.html
0 komentar:
Please comment if there are any that need to be asked.