[ https://issues.apache.org/jira/browse/AMBARI-18002?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=15408786#comment-15408786 ]
Masahiro Tanaka commented on AMBARI-18002: ------------------------------------------ Hi [~oleewere], [~swagle], [~ncole], [~jonathan.hurley], [~afernandez] I would like to ask you the policy. For now, the date format of ambari-server.log is this. {code} 04 Aug 2016 20:48:13,298 INFO [main] Configuration:1013 - Generation of file with password 04 Aug 2016 20:48:13,962 INFO [main] ViewExtractor:86 - Creating archive folder /var/lib/ambari-server/resources/views/work/ADMIN_VIEW{2.0.0.0}. 04 Aug 2016 20:48:13,963 INFO [main] ViewExtractor:93 - Extracting files from ambari-admin-2.0.0.0-SNAPSHOT.jar. 04 Aug 2016 20:48:15,154 INFO [main] Configuration:1026 - Reading password from existing file {code} But in other LANG (e.g. LANG=ja_JP.UTF-8) environment, the format of Month has changed. {code} 28 7 2016 12:52:57,207 INFO [main] Configuration:1009 - Generation of file with password 28 7 2016 12:52:58,893 INFO [main] Configuration:1022 - Reading password from existing file 28 7 2016 12:53:00,389 INFO [main] Configuration:1022 - Reading password from existing file {code} I think log4j changes output according to the LANG environment, and Grok (used by LogSearch) doesn't change like that. I think we should change date format in ambari-server.log to ISO8601 for consistency, and to avoid the problems like this. But it's a big change. So my question is: Should I change date format in ambari-server.log to fix this problem or not? FYI: The date format is defined in {{ambari/ambari-server/conf/unix/log4j.properties}} {code} # Direct log messages to a log file log4j.appender.file=org.apache.log4j.RollingFileAppender log4j.appender.file.File=${ambari.log.dir}/${ambari.log.file} log4j.appender.file.MaxFileSize=80MB log4j.appender.file.MaxBackupIndex=60 log4j.appender.file.layout=org.apache.log4j.PatternLayout log4j.appender.file.layout.ConversionPattern=%d{DATE} %5p [%t] %c{1}:%L - %m%n {code} %d{DATE} is same as {{"dd MMM yyyy HH:mm:ss,SSS"}} > Parse Error in ambari-server.log with LogSearch > ----------------------------------------------- > > Key: AMBARI-18002 > URL: https://issues.apache.org/jira/browse/AMBARI-18002 > Project: Ambari > Issue Type: Bug > Affects Versions: 2.4.0 > Environment: CentOS7.2, Ambari2.4.0 (trunk), LANG=ja_JP.UTF-8 > Reporter: Masahiro Tanaka > Assignee: Masahiro Tanaka > Attachments: AMBARI-18002.patch > > > In Ambari Server with LogSearch environment, we got a lot of errors like below > {code} > 2016-08-03 13:51:36,146 WARN file=ambari-server.log > org.apache.ambari.logfeeder.filter.FilterGrok LogFeederUtil.java:350 - Error > parsing string. length=182, input=input:source=file, > path=/var/log/ambari-server/ambari-server.log. First upto 100 characters=03 8 > 2016 13:51:29,606 INFO [ambari-heartbeat-processor-0] HeartbeatProcessor:505 > - Updating applie. Messages suppressed before: 3 > {code} > ambari-server.log is below > {code} > 28 7 2016 12:52:57,207 INFO [main] Configuration:1009 - Generation of file > with password > 28 7 2016 12:52:58,893 INFO [main] Configuration:1022 - Reading password > from existing file > 28 7 2016 12:53:00,389 INFO [main] Configuration:1022 - Reading password > from existing file > 28 7 2016 12:53:01,885 INFO [main] Configuration:1022 - Reading password > from existing file > 28 7 2016 12:53:03,423 INFO [main] Configuration:1022 - Reading password > from existing file > 28 7 2016 12:53:04,947 INFO [main] Configuration:1022 - Reading password > from existing file > 28 7 2016 12:53:06,503 INFO [main] Configuration:1022 - Reading password > from existing file > 28 7 2016 12:53:08,038 INFO [main] Configuration:1022 - Reading password > from existing file > {code} -- This message was sent by Atlassian JIRA (v6.3.4#6332)