|
Harald Hoyer |
7e00d9 |
From f9452c94c05e505d358329fbb228da7979770c4c Mon Sep 17 00:00:00 2001
|
|
Harald Hoyer |
7e00d9 |
From: Colin Guthrie <colin@mageia.org>
|
|
Harald Hoyer |
7e00d9 |
Date: Thu, 16 Aug 2012 14:27:22 +0100
|
|
Harald Hoyer |
7e00d9 |
Subject: [PATCH] udev-rules: Pre usrmove systemd installs might not find
|
|
Harald Hoyer |
7e00d9 |
udevd.
|
|
Harald Hoyer |
7e00d9 |
|
|
Harald Hoyer |
7e00d9 |
If users had switched to systemd-183+ but have not completed
|
|
Harald Hoyer |
7e00d9 |
the usrmove, then the variable ${systemdutildir} will likely
|
|
Harald Hoyer |
7e00d9 |
refer to /usr/lib/systemd NOT /lib/systemd and thus the
|
|
Harald Hoyer |
7e00d9 |
systemd-udevd daemon may not be found.
|
|
Harald Hoyer |
7e00d9 |
|
|
Harald Hoyer |
7e00d9 |
So let's try a little harder and add another hard coded path
|
|
Harald Hoyer |
7e00d9 |
and if we don't find it, then bail out hard.
|
|
Harald Hoyer |
7e00d9 |
---
|
|
Harald Hoyer |
7e00d9 |
modules.d/95udev-rules/module-setup.sh | 6 +++++-
|
|
Harald Hoyer |
7e00d9 |
1 file changed, 5 insertions(+), 1 deletion(-)
|
|
Harald Hoyer |
7e00d9 |
|
|
Harald Hoyer |
7e00d9 |
diff --git a/modules.d/95udev-rules/module-setup.sh b/modules.d/95udev-rules/module-setup.sh
|
|
Harald Hoyer |
7e00d9 |
index 2e3c955..5e1cce5 100755
|
|
Harald Hoyer |
7e00d9 |
--- a/modules.d/95udev-rules/module-setup.sh
|
|
Harald Hoyer |
7e00d9 |
+++ b/modules.d/95udev-rules/module-setup.sh
|
|
Harald Hoyer |
7e00d9 |
@@ -12,7 +12,7 @@ install() {
|
|
Harald Hoyer |
7e00d9 |
/etc/udev/udev.conf /etc/group
|
|
Harald Hoyer |
7e00d9 |
|
|
Harald Hoyer |
7e00d9 |
[ -d ${initdir}/lib/systemd ] || mkdir -p ${initdir}/lib/systemd
|
|
Harald Hoyer |
7e00d9 |
- for _i in ${systemdutildir}/systemd-udevd ${udevdir}/udevd /sbin/udevd; do
|
|
Harald Hoyer |
7e00d9 |
+ for _i in ${systemdutildir}/systemd-udevd ${udevdir}/udevd /lib/systemd/systemd-udevd /sbin/udevd; do
|
|
Harald Hoyer |
7e00d9 |
[ -x "$_i" ] || continue
|
|
Harald Hoyer |
7e00d9 |
inst "$_i"
|
|
Harald Hoyer |
7e00d9 |
|
|
Harald Hoyer |
7e00d9 |
@@ -21,6 +21,10 @@ install() {
|
|
Harald Hoyer |
7e00d9 |
fi
|
|
Harald Hoyer |
7e00d9 |
break
|
|
Harald Hoyer |
7e00d9 |
done
|
|
Harald Hoyer |
7e00d9 |
+ if ! [[ -e ${initdir}/lib/systemd/systemd-udevd ]]; then
|
|
Harald Hoyer |
7e00d9 |
+ derror "Cannot find [systemd-]udevd binary!"
|
|
Harald Hoyer |
7e00d9 |
+ exit 1
|
|
Harald Hoyer |
7e00d9 |
+ fi
|
|
Harald Hoyer |
7e00d9 |
|
|
Harald Hoyer |
7e00d9 |
inst_rules 50-udev-default.rules 60-persistent-storage.rules \
|
|
Harald Hoyer |
7e00d9 |
61-persistent-storage-edd.rules 80-drivers.rules 95-udev-late.rules \
|