怎么修改jboss-eap-6.1中jboss自身的server.log文件按指定大小产生,而不是按天?

发布于 2021-11-22 16:02:15 字数 461 浏览 893 评论 1

jboss-eap-6.1中jboss 的standalone日志地址为/jboss/standalone/log/server.log,配置文件为/jboss/standalone/configuration/standalone.xml,配置log如下:


<subsystem xmlns="urn:jboss:domain:logging:1.2">
            <console-handler name="CONSOLE">
                <level name="INFO"/>
                <formatter>
                    <pattern-formatter pattern="%K{level}%d{HH
              

如果你对这篇内容有疑问,欢迎到本站社区发帖提问 参与讨论,获取更多帮助,或者扫码二维码加入 Web 技术交流群。

扫码二维码加入Web技术交流群

发布评论

需要 登录 才能够评论, 你可以免费 注册 一个本站的账号。

评论(1

反话 2021-11-23 14:47:48

size-rotating-file-handler

Defines a handler which writes to a file, rotating the log after a the size of the file grows beyond a certain point and keeping a fixed number of backups. 

AttributeDescriptionTypeAllow NullExpression AllowedAccess TypeRestart RequiredDefault ValueAllowed Values
enabledIf set to true the handler is enabled and functioning as normal, if set to false the handler is ignored when processing log messages.BOOLEANtruetrueread-writeno-servicestrueAny
appendSpecify whether to append to the target file.BOOLEANtruetrueread-writeresource-servicestrueAny
autoflushAutomatically flush after each write.BOOLEANtruetrueread-writeno-servicestrueAny
rotate-sizeThe size at which to rotate the log file.STRINGfalsetrueread-writeno-services2mAny
formatterDefines a pattern for the formatter.STRINGtruetrueread-writeno-services%d{HH:mm:ss,SSS} %-5p [%c] (%t) %s%E%nAny
filter-specA filter expression value to define a filter. Example for a filter that does not match a pattern: not(match("JBAS.*"))STRINGtruetrueread-writeno-servicesnullSee Filter Expression
levelThe log level specifying which message levels will be logged by this logger. Message levels lower than this value will be discarded.STRINGtruetrueread-writeno-servicesALL
  • ALL 
  • FINEST 
  • FINER 
  • TRACE 
  • DEBUG 
  • FINE 
  • CONFIG 
  • INFO 
  • WARN 
  • WARNING
  • ERROR 
  • FATAL 
  • OFF
max-backup-indexThe maximum number of backups to keep.INTtruetrueread-writeno-services1Any
fileThe file description consisting of the path and optional relative to path.OBJECTtruefalseread-writeno-servicesnullAny
nameThe handler's name.STRINGtruefalseread-only nullAny
encodingThe character encoding used by this Handler.STRINGtruetrueread-writeno-servicesnullAny
~没有更多了~
我们使用 Cookies 和其他技术来定制您的体验包括您的登录状态等。通过阅读我们的 隐私政策 了解更多相关信息。 单击 接受 或继续使用网站,即表示您同意使用 Cookies 和您的相关数据。
原文