From 540b3c5d53f7b5889247e9cb4aea62d3983a48b8 Mon Sep 17 00:00:00 2001 From: Martin Wilck Date: Fri, 20 Oct 2023 16:25:15 +0200 Subject: [PATCH] units: modprobe@.service: don't unescape instance name modprobe treats "-" and "_" interchangeably, thereby avoiding frequent errors because some module names contain dashes and others underscores. Because modprobe@.service unescapes the instance name, an attempt to start "modprobe@dm-crypt.service" will run "modprobe -abq dm/crypt", which is doomed to fail. "modprobe@dm_crypt.service" will work as expected. Thus unescaping the instance name has surprising side effects. Use "%i" instead. (cherry picked from commit bf25cf6c49253e922524dfa0e7960f554838f18b) (cherry picked from commit c98d0130dc8efd826cd85020337353cdbe644bb4) (cherry picked from commit 6d5eba0814e7dfc15ebb68ca5afdabab214c9da6) --- units/modprobe@.service | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/units/modprobe@.service b/units/modprobe@.service index 85a2c08dee..fe631fffeb 100644 --- a/units/modprobe@.service +++ b/units/modprobe@.service @@ -17,4 +17,4 @@ StartLimitIntervalSec=0 [Service] Type=oneshot -ExecStart=-/sbin/modprobe -abq %I +ExecStart=-/sbin/modprobe -abq %i -- 2.33.0