-
Notifications
You must be signed in to change notification settings - Fork 1.7k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Logs Truncated and Subsequent Entries Appended in Log Files #3408
Comments
|
Thank you for your response. We are currently using Log4j version 2.17.2. The issue occurs exclusively in our production clusters running on AWS EKS. We attempted to reproduce the problem in a controlled environment by generating dummy logs in a multi-threaded setup using the same Log4j2 configuration and version but were unable to replicate the behavior. |
Did you exactly replicate your production environment, including the Java system properties and JRE? I would double check if the garbage-free properties are the same in the two environments. Can you add |
This issue is stale because it has been waiting for your feedback for more than 60 days. The Apache Logging Services community values every submitted issue, but without additional information from you, we are unable to provide a solution to your problem. |
Description
We are encountering an issue where some log entries within our log files are being truncated. These truncated logs are directly followed by the subsequent log entry, leading to a single, combined log line. This situation also raises concerns about the potential for data loss, as log entries may be missing between those that have been merged. We are also using Log Redactor for masking logs.
Configuration
JDK Version: 21
OS: Linux
Rolling File Appender configuration:
<RollingFile name="File" fileName="${logFile}.log" filePattern="${logbackupdirectory}/${podName}_${sys:port}-%i.log.gz"> <PatternLayout> <Pattern>%d{DATE}{GMT+5:30} %5p %t %X{Id} %c{1}:%L - %m%n %xEx</Pattern> </PatternLayout> <Policies> <SizeBasedTriggeringPolicy size="${sys:LOGSIZE:-50} MB" /> </Policies> <DefaultRolloverStrategy max="${sys:MAXLOGS:-300}" /> </RollingFile>
Logs
Expected Behaviour :
2025-01-03 12:34:56 INFO [Module] Operation completed successfully
2025-01-03 12:34:57 ERROR [Module] An error occurred
Actual behaviour :
2025-01-03 12:34:56 INFO [Module] Operation completed successfu2025-01-03 12:34:57 ERROR [Module] An error occurred
The text was updated successfully, but these errors were encountered: