From 0d6583a436633ff509af907ec0148ab9b2f630ea Mon Sep 17 00:00:00 2001 From: Sudharsan Dhamal Gopalarathnam Date: Mon, 3 May 2021 22:43:08 +0000 Subject: [PATCH] Config reload fix --- files/build_templates/delay.target | 5 +++++ files/build_templates/mgmt-framework.timer | 2 +- files/build_templates/snmp.timer | 2 +- files/build_templates/sonic_debian_extension.j2 | 3 +++ files/build_templates/telemetry.timer | 2 +- 5 files changed, 11 insertions(+), 3 deletions(-) create mode 100644 files/build_templates/delay.target diff --git a/files/build_templates/delay.target b/files/build_templates/delay.target new file mode 100644 index 000000000000..b3b5d760f136 --- /dev/null +++ b/files/build_templates/delay.target @@ -0,0 +1,5 @@ +[Unit] +Description=SONiC delayed services target. + +[Install] +WantedBy=multi-user.target diff --git a/files/build_templates/mgmt-framework.timer b/files/build_templates/mgmt-framework.timer index 37389fbc6db5..f844cf858c4b 100644 --- a/files/build_templates/mgmt-framework.timer +++ b/files/build_templates/mgmt-framework.timer @@ -8,4 +8,4 @@ OnBootSec=3min 30 sec Unit=mgmt-framework.service [Install] -WantedBy=timers.target sonic.target +WantedBy=timers.target sonic.target delay.target diff --git a/files/build_templates/snmp.timer b/files/build_templates/snmp.timer index abbcb67f6dee..d8fffdc149a6 100644 --- a/files/build_templates/snmp.timer +++ b/files/build_templates/snmp.timer @@ -9,4 +9,4 @@ OnBootSec=3min 30 sec Unit=snmp.service [Install] -WantedBy=timers.target swss.service +WantedBy=timers.target swss.service delay.target diff --git a/files/build_templates/sonic_debian_extension.j2 b/files/build_templates/sonic_debian_extension.j2 index 2bf752fc31d7..648c4407aeff 100644 --- a/files/build_templates/sonic_debian_extension.j2 +++ b/files/build_templates/sonic_debian_extension.j2 @@ -737,6 +737,9 @@ echo "mgmt-framework.timer" | sudo tee -a $GENERATED_SERVICE_FILE sudo cp $BUILD_TEMPLATES/sonic.target $FILESYSTEM_ROOT_USR_LIB_SYSTEMD_SYSTEM sudo LANG=C chroot $FILESYSTEM_ROOT systemctl enable sonic.target +sudo cp $BUILD_TEMPLATES/delay.target $FILESYSTEM_ROOT_USR_LIB_SYSTEMD_SYSTEM +sudo LANG=C chroot $FILESYSTEM_ROOT systemctl enable delay.target + sudo LANG=C DEBIAN_FRONTEND=noninteractive chroot $FILESYSTEM_ROOT apt-get purge -y python-dev python3-dev sudo LANG=C DEBIAN_FRONTEND=noninteractive chroot $FILESYSTEM_ROOT apt-get purge -y build-essential libssl-dev swig sudo LANG=C DEBIAN_FRONTEND=noninteractive chroot $FILESYSTEM_ROOT apt-get purge -y libcairo2-dev libdbus-1-dev libgirepository1.0-dev libsystemd-dev pkg-config diff --git a/files/build_templates/telemetry.timer b/files/build_templates/telemetry.timer index 4a605b8c50cb..6449375c604a 100644 --- a/files/build_templates/telemetry.timer +++ b/files/build_templates/telemetry.timer @@ -8,4 +8,4 @@ OnBootSec=3min 30 sec Unit=telemetry.service [Install] -WantedBy=timers.target sonic.target +WantedBy=timers.target sonic.target delay.target