]> git.ipfire.org Git - thirdparty/dracut.git/commitdiff
fix(ifcfg): avoid calling unavailable dracut-logger functions
authorAntonio Alvarez Feijoo <antonio.feijoo@suse.com>
Wed, 6 Apr 2022 08:25:23 +0000 (10:25 +0200)
committerJóhann B. Guðmundsson <johannbg@gmail.com>
Sat, 9 Apr 2022 08:09:24 +0000 (08:09 +0000)
The dracut-logger functions are only available during the initrd
generation. For internal initrd scripts that run at boot,
dracut-lib provides warn() and info().

modules.d/45ifcfg/write-ifcfg.sh

index 345863f9956908b5972d8e2064454e51f76dacca..854d294dfd4fa7f79e179a7a63a6b9c16ee37937 100755 (executable)
@@ -104,7 +104,7 @@ interface_bind() {
     local _macaddr="$2"
 
     if [ ! -e "/sys/class/net/$_netif" ]; then
-        derror "Cannot find network interface '$_netif'!"
+        warn "Cannot find network interface '$_netif'!"
         return 1
     fi