meta-google: gbmc-bridge: Remove ensure RA
We no longer need to ensure that router advertisements are sent if we
have a forced retransmission window 3x shorter than the expiry.
Tested: Ran on a multi-BMC machine and verified routes remain stable
over 10s of minutes of time.
Change-Id: Ic0361242cd77aea774d3315986f6590d9d043d6f
Signed-off-by: William A. Kennington III <wak@google.com>
diff --git a/meta-google/recipes-google/networking/gbmc-bridge.bb b/meta-google/recipes-google/networking/gbmc-bridge.bb
index e23ee57..0a6f40e 100644
--- a/meta-google/recipes-google/networking/gbmc-bridge.bb
+++ b/meta-google/recipes-google/networking/gbmc-bridge.bb
@@ -15,8 +15,6 @@
file://50-gbmc-br.rules \
file://gbmc-br-ula.sh \
file://gbmc-br-from-ra.sh \
- file://gbmc-br-ensure-ra.sh \
- file://gbmc-br-ensure-ra.service \
file://gbmc-br-hostname.sh \
file://gbmc-br-hostname.service \
file://gbmc-br-ra.sh.in \
@@ -54,7 +52,6 @@
"
SYSTEMD_SERVICE:${PN} += " \
- gbmc-br-ensure-ra.service \
gbmc-br-hostname.service \
gbmc-br-dhcp.service \
gbmc-br-dhcp-term.service \
@@ -141,12 +138,10 @@
install -m0644 ${WORKDIR}/gbmc-br-nft.sh "$mondir"/
install -d -m0755 ${D}${libexecdir}
- install -m0755 ${WORKDIR}/gbmc-br-ensure-ra.sh ${D}${libexecdir}/
install -m0755 ${WORKDIR}/gbmc-br-hostname.sh ${D}${libexecdir}/
install -m0755 ${WORKDIR}/gbmc-br-dhcp.sh ${D}${libexecdir}/
install -m0755 ${WORKDIR}/gbmc-br-dhcp-term.sh ${D}${libexecdir}/
install -d -m0755 ${D}${systemd_system_unitdir}
- install -m0644 ${WORKDIR}/gbmc-br-ensure-ra.service ${D}${systemd_system_unitdir}/
install -m0644 ${WORKDIR}/gbmc-br-hostname.service ${D}${systemd_system_unitdir}/
install -m0644 ${WORKDIR}/gbmc-br-dhcp.service ${D}${systemd_system_unitdir}/
install -m0644 ${WORKDIR}/gbmc-br-dhcp-term.service ${D}${systemd_system_unitdir}/
diff --git a/meta-google/recipes-google/networking/gbmc-bridge/gbmc-br-ensure-ra.service b/meta-google/recipes-google/networking/gbmc-bridge/gbmc-br-ensure-ra.service
deleted file mode 100644
index 7f97cea..0000000
--- a/meta-google/recipes-google/networking/gbmc-bridge/gbmc-br-ensure-ra.service
+++ /dev/null
@@ -1,5 +0,0 @@
-[Service]
-ExecStart=/usr/libexec/gbmc-br-ensure-ra.sh
-
-[Install]
-WantedBy=multi-user.target
diff --git a/meta-google/recipes-google/networking/gbmc-bridge/gbmc-br-ensure-ra.sh b/meta-google/recipes-google/networking/gbmc-bridge/gbmc-br-ensure-ra.sh
deleted file mode 100644
index 60e33d8..0000000
--- a/meta-google/recipes-google/networking/gbmc-bridge/gbmc-br-ensure-ra.sh
+++ /dev/null
@@ -1,27 +0,0 @@
-#!/bin/bash
-# Copyright 2021 Google LLC
-#
-# Licensed under the Apache License, Version 2.0 (the "License");
-# you may not use this file except in compliance with the License.
-# You may obtain a copy of the License at
-#
-# http://www.apache.org/licenses/LICENSE-2.0
-#
-# Unless required by applicable law or agreed to in writing, software
-# distributed under the License is distributed on an "AS IS" BASIS,
-# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-# See the License for the specific language governing permissions and
-# limitations under the License.
-
-# Every 30 seconds, send out an RA so that the kernel will receive a response.
-# This ensures that all BMCs (even ones that think they are routers) get updated
-# information from the other systems on the network.
-w=30
-while true; do
- start=$SECONDS
- rdisc6 -m gbmcbr -r 1 -w $(( w * 1000 )) >/dev/null 2>/dev/null
- # If rdisc6 exits early we still want to wait the full `w` time before
- # starting again.
- (( timeout = start + w - SECONDS ))
- sleep $(( timeout < 0 ? 0 : timeout ))
-done