From 2b21cd5e222fac6df8b8e08321e6edf83a4eae8c Mon Sep 17 00:00:00 2001 From: Jon Goldberg <63672455+jon-nokia@users.noreply.github.com> Date: Wed, 3 May 2023 13:26:41 -0400 Subject: [PATCH] [armhf][Nokia-7215] changes fstrim.timer to daily (#14723) Using timer-override.conf, we modify the fstrim.timer service. For armhf, Nokia-7215 platform, we modify fstrim.timer to run daily instead of weekly. This is required because the size of the SSD on this platform is 16GB, which on average is nearly 10 times smaller than most other sonic platforms. With smaller disk and the ever increasing level of logging done by sonic, this change is required to prevent the SSD from entering a read-only state due to inadequate free blocks. --- .../7215/service/fstrim.timer/timer-override.conf | 5 +++++ .../debian/sonic-platform-nokia-7215.install | 1 + 2 files changed, 6 insertions(+) create mode 100644 platform/marvell-armhf/sonic-platform-nokia/7215/service/fstrim.timer/timer-override.conf diff --git a/platform/marvell-armhf/sonic-platform-nokia/7215/service/fstrim.timer/timer-override.conf b/platform/marvell-armhf/sonic-platform-nokia/7215/service/fstrim.timer/timer-override.conf new file mode 100644 index 0000000000..0456c60d42 --- /dev/null +++ b/platform/marvell-armhf/sonic-platform-nokia/7215/service/fstrim.timer/timer-override.conf @@ -0,0 +1,5 @@ +[Unit] +Description=Discard unused blocks daily + +[Timer] +OnCalendar=daily diff --git a/platform/marvell-armhf/sonic-platform-nokia/debian/sonic-platform-nokia-7215.install b/platform/marvell-armhf/sonic-platform-nokia/debian/sonic-platform-nokia-7215.install index ea347d79be..be989f05c1 100644 --- a/platform/marvell-armhf/sonic-platform-nokia/debian/sonic-platform-nokia-7215.install +++ b/platform/marvell-armhf/sonic-platform-nokia/debian/sonic-platform-nokia-7215.install @@ -1,6 +1,7 @@ nokia-7215_plt_setup.sh usr/sbin 7215/scripts/nokia-7215init.sh usr/local/bin 7215/service/nokia-7215init.service etc/systemd/system +7215/service/fstrim.timer/timer-override.conf /lib/systemd/system/fstrim.timer.d 7215/sonic_platform-1.0-py3-none-any.whl usr/share/sonic/device/armhf-nokia_ixs7215_52x-r0 entropy.py etc/ inband_mgmt.sh etc/