From: Yu Watanabe Date: Sun, 19 Oct 2025 03:38:35 +0000 (+0900) Subject: TEST-75-RESOLVED: stop socket units before stopping the main service X-Git-Tag: v258.2~38 X-Git-Url: http://git.ipfire.org/gitweb.cgi?a=commitdiff_plain;h=279a13734dbeb52a9c84fcbe08ba6f61d102975a;p=thirdparty%2Fsystemd.git TEST-75-RESOLVED: stop socket units before stopping the main service Fixes the following warning: TEST-75-RESOLVED.sh[2251]: ++ restart_resolved TEST-75-RESOLVED.sh[2251]: ++ systemctl stop systemd-resolved.service TEST-75-RESOLVED.sh[2271]: Stopping 'systemd-resolved.service', but its triggering units are still active: TEST-75-RESOLVED.sh[2271]: systemd-resolved-monitor.socket, systemd-resolved-varlink.socket (cherry picked from commit f88f0271f84f11643fa20198e2346a2ec4e629ed) --- diff --git a/test/units/TEST-75-RESOLVED.sh b/test/units/TEST-75-RESOLVED.sh index 04216ec1426..48ee25d576c 100755 --- a/test/units/TEST-75-RESOLVED.sh +++ b/test/units/TEST-75-RESOLVED.sh @@ -64,11 +64,13 @@ monitor_check_rr() ( ) restart_resolved() { + systemctl stop systemd-resolved-monitor.socket systemd-resolved-varlink.socket systemctl stop systemd-resolved.service (! systemctl is-failed systemd-resolved.service) # Reset the restart counter since we call this method a bunch of times # and can occasionally hit the default rate limit systemctl reset-failed systemd-resolved.service + systemctl start systemd-resolved-monitor.socket systemd-resolved-varlink.socket systemctl start systemd-resolved.service systemctl service-log-level systemd-resolved.service debug } @@ -334,6 +336,7 @@ manual_testcase_02_mdns_llmnr() { } >/run/systemd/resolved.conf.d/90-mdns-llmnr.conf restart_resolved # make sure networkd is not running. + systemctl stop systemd-networkd.socket systemd-networkd-varlink.socket systemctl stop systemd-networkd.service assert_in 'no' "$(resolvectl mdns hoge)" assert_in 'no' "$(resolvectl llmnr hoge)" @@ -1368,7 +1371,9 @@ testcase_15_wait_online_dns() { resolvectl domain dns0 "" # Stop systemd-resolved before calling systemd-networkd-wait-online. It should retry connections. + systemctl stop systemd-resolved-monitor.socket systemd-resolved-varlink.socket systemctl stop systemd-resolved.service + systemctl start systemd-resolved-monitor.socket systemd-resolved-varlink.socket # Begin systemd-networkd-wait-online --dns systemd-run -u "$unit" -p "Environment=SYSTEMD_LOG_LEVEL=debug" -p "Environment=SYSTEMD_LOG_TARGET=journal" --service-type=exec \