From 4a6f4c64806675fe27ec24187923428fd1c5d7f0 Mon Sep 17 00:00:00 2001 From: lxpzero Date: Mon, 16 Jun 2025 13:39:20 +0800 Subject: [PATCH] compress log files --- 1002-logrotate-compress-log-files.patch | 14 ++++++++++++++ logrotate.spec | 7 ++++++- 2 files changed, 20 insertions(+), 1 deletion(-) create mode 100644 1002-logrotate-compress-log-files.patch diff --git a/1002-logrotate-compress-log-files.patch b/1002-logrotate-compress-log-files.patch new file mode 100644 index 0000000..440df43 --- /dev/null +++ b/1002-logrotate-compress-log-files.patch @@ -0,0 +1,14 @@ + logrotate-default | 2 +- + 1 files changed, 1 insertions(+), 1 deletion(-) + +--- a/examples/logrotate-default 2025-06-16 11:36:19.283045412 +0800 ++++ b/examples/logrotate-default 2025-06-16 11:36:27.881038157 +0800 +@@ -12,7 +12,7 @@ create + dateext + + # uncomment this if you want your log files compressed +-#compress ++compress + + # RPM packages drop log rotation information into this directory + include /etc/logrotate.d diff --git a/logrotate.spec b/logrotate.spec index 46cf743..7e1d8b1 100644 --- a/logrotate.spec +++ b/logrotate.spec @@ -1,4 +1,4 @@ -%define anolis_release .0.1 +%define anolis_release .0.2 Summary: Rotates, compresses, removes and mails system log files Name: logrotate Version: 3.14.0 @@ -40,6 +40,8 @@ Patch6: 0006-logrotate-3.14.0-stricter-config-parser.patch Patch1001: 1001-logrotate-3.15.1-gcc-10-build-fix.patch # End: Anolis customized patches +Patch1002: 1002-logrotate-compress-log-files.patch + %description The logrotate utility is designed to simplify the administration of log files on a system which generates a lot of log files. Logrotate @@ -125,6 +127,9 @@ fi %config(noreplace) %{_sysconfdir}/rwtab.d/logrotate %changelog +* Mon Jun 16 2025 Xiaoping Liu 3.14.0-6.0.2 +- compress log files + * Fri May 26 2023 Weitao Zhou 3.14.0-6.0.1 - Fix gcc10 -fno-common compile issue for compatible with gcc10 build -- Gitee