From d1f659689ed6e1109554750336b00250040a91b6 Mon Sep 17 00:00:00 2001 From: abdosi <58047199+abdosi@users.noreply.github.com> Date: Tue, 14 Sep 2021 17:39:02 -0700 Subject: [PATCH] Logrotate for wtmp and btmp files to fix size getting too large. (#8744) Signed-off-by: Abhishek Dosi --- files/build_templates/sonic_debian_extension.j2 | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/files/build_templates/sonic_debian_extension.j2 b/files/build_templates/sonic_debian_extension.j2 index 8920b4409c..ecff1b014e 100644 --- a/files/build_templates/sonic_debian_extension.j2 +++ b/files/build_templates/sonic_debian_extension.j2 @@ -247,7 +247,8 @@ sudo mkdir -p $FILESYSTEM_ROOT/etc/systemd/system/syslog.socket.d sudo cp $IMAGE_CONFIGS/syslog/override.conf $FILESYSTEM_ROOT/etc/systemd/system/syslog.socket.d/override.conf sudo cp $IMAGE_CONFIGS/syslog/host_umount.sh $FILESYSTEM_ROOT/usr/bin/ -# Copy logrotate.d configuration files +# Copy logrotate.conf and logrotate.d configuration files +sudo cp -f $IMAGE_CONFIGS/logrotate/logrotate.conf $FILESYSTEM_ROOT/etc/logrotate.conf sudo cp -f $IMAGE_CONFIGS/logrotate/logrotate.d/* $FILESYSTEM_ROOT/etc/logrotate.d/ # Copy systemd-journald configuration files