fix udev rules

Signed-off-by: Fabio M. Di Nitto <fdinitto@redhat.com>
This commit is contained in:
Fabio M. Di Nitto 2012-02-03 15:27:12 +01:00
parent e641fe44f5
commit 03271b28ea
2 changed files with 42 additions and 1 deletions

View File

@ -1,6 +1,6 @@
Name: dlm Name: dlm
Version: 3.99.0 Version: 3.99.0
Release: 2%{?dist} Release: 3%{?dist}
License: GPLv2 and GPLv2+ and LGPLv2+ License: GPLv2 and GPLv2+ and LGPLv2+
# For a breakdown of the licensing, see README.license # For a breakdown of the licensing, see README.license
Group: System Environment/Kernel Group: System Environment/Kernel
@ -12,6 +12,7 @@ BuildRequires: libxml2-devel
BuildRequires: systemd-units BuildRequires: systemd-units
Requires: %{name}-lib = %{version}-%{release} Requires: %{name}-lib = %{version}-%{release}
Source0: http://people.redhat.com/teigland/%{name}-%{version}.tar.gz Source0: http://people.redhat.com/teigland/%{name}-%{version}.tar.gz
Patch0: fix_udev_rules.patch
Requires(post): systemd-units Requires(post): systemd-units
Requires(preun): systemd-units Requires(preun): systemd-units
@ -23,6 +24,7 @@ The kernel dlm requires a user daemon to control cluster membership.
%prep %prep
%setup -q %setup -q
%patch0 -p1
%build %build
# upstream does not require configure # upstream does not require configure
@ -96,6 +98,10 @@ developing applications that use %{name}.
%{_libdir}/pkgconfig/*.pc %{_libdir}/pkgconfig/*.pc
%changelog %changelog
* Fri Feb 3 2012 Fabio M. Di Nitto <fdinitto@redhat.com> - 3.99.0-3
- Add patch to fix udev rules and make sure dlm_controld can find
its devices
* Thu Feb 2 2012 Fabio M. Di Nitto <fdinitto@redhat.com> - 3.99.0-2 * Thu Feb 2 2012 Fabio M. Di Nitto <fdinitto@redhat.com> - 3.99.0-2
- Add Conflicts with clusterlib/cman as necessary - Add Conflicts with clusterlib/cman as necessary

35
fix_udev_rules.patch Normal file
View File

@ -0,0 +1,35 @@
commit 5d55eebda689be8f62bcf75e02d99777b6442b08
Author: Fabio M. Di Nitto <fdinitto@redhat.com>
Date: Fri Feb 3 15:16:09 2012 +0100
libdlm: fix udev rules to deal with misc contrains
new kernels do not allow renaming of certain class of char devices,
and that means that new dlm* devices are created in /dev instead
of /dev/misc.
Change udev rules to create compat SYMLINKS in /dev/misc and
maintain the same file modes.
Also update to deal with dlm_plock and drop dlm_default that is
not referenced neither in kernel or userland.
This also fixes a dlm_controld segfaults on closing connections
to dlm_plock.
Signed-off-by: Fabio M. Di Nitto <fdinitto@redhat.com>
diff --git a/libdlm/51-dlm.rules b/libdlm/51-dlm.rules
index f71e79d..9d21fc0 100644
--- a/libdlm/51-dlm.rules
+++ b/libdlm/51-dlm.rules
@@ -1,5 +1,4 @@
-KERNEL=="dlm-control", NAME="misc/dlm-control", MODE="0666"
-KERNEL=="dlm-monitor", NAME="misc/dlm-monitor", MODE="0666"
-KERNEL=="dlm_default", NAME="misc/dlm_default", MODE="0666"
-KERNEL=="dlm_*", NAME="misc/%k", MODE="0660"
-
+KERNEL=="dlm-control", MODE="0666", SYMLINK+="misc/dlm-control"
+KERNEL=="dlm-monitor", MODE="0666", SYMLINK+="misc/dlm-monitor"
+KERNEL=="dlm_plock", MODE="0666", SYMLINK+="misc/dlm_plock"
+KERNEL=="dlm_*", MODE="0660", SYMLINK+="misc/%k"