I am trying to logrotate every 15 minutes a CDR file consisting of multiple CDR records, where each CDR record is present in a new line, all works fine but logrotate truncates the file in the middle of last CDR record which results in breaking latest CDR record across 2 files.Is there a way/option to tell logrotate to only truncate the file after it sees the newline character so that no CDR record is truncated in the middle?Thanks
How to make logrotate to copytruncate the original file only after a newline
logrotate