- New upstream version: 3.2.4. /run/mdadm is not

used for runtime files, not /var/run or /dev/.mdadm.

OBS-URL: https://build.opensuse.org/package/show/Base:System/mdadm?expand=0&rev=52
This commit is contained in:
Neil Brown 2012-05-09 01:23:18 +00:00 committed by Git OBS Bridge
parent 2217494ff8
commit f4371a9780
7 changed files with 19 additions and 1036 deletions

View File

@ -98,12 +98,7 @@ case "$1" in
start)
echo -n "Starting MD RAID "
# create the /var/run/mdadm symlink if needed
mkdir -p /dev/.mdadm
if test ! /dev/.mdadm -ef /var/run/mdadm; then
rm -rf /var/run/mdadm
ln -s /dev/.mdadm /var/run/mdadm
fi
mkdir -p /run/mdadm
# restart mdmon (exits silently if there is nothing to monitor)
/sbin/mdmon --all --takeover
# Check for existence of needed config file and read it

View File

@ -1,3 +0,0 @@
version https://git-lfs.github.com/spec/v1
oid sha256:0d1a04e688b082bc88846e3f524abd50bc782b6ffc06123140f7d358c8f9b906
size 357234

File diff suppressed because it is too large Load Diff

3
mdadm-3.2.4.tar.bz2 Normal file
View File

@ -0,0 +1,3 @@
version https://git-lfs.github.com/spec/v1
oid sha256:3dc439732aa5c0a716bccf57ea673b6e4844ac8eb49a90f2bd5878772c4eaa34
size 368798

View File

@ -1,3 +1,9 @@
-------------------------------------------------------------------
Wed May 9 01:22:11 UTC 2012 - nfbrown@suse.com
- New upstream version: 3.2.4. /run/mdadm is not
used for runtime files, not /var/run or /dev/.mdadm.
-------------------------------------------------------------------
Fri Apr 20 08:00:33 UTC 2012 - rmilasan@suse.com

View File

@ -17,7 +17,7 @@
Name: mdadm
Version: 3.2.2
Version: 3.2.4
Release: 0
BuildRequires: sgmltool
PreReq: %fillup_prereq %insserv_prereq /sbin/mkinitrd
@ -34,8 +34,6 @@ Source3: mdadmd
Source4: boot.md
Source5: mkinitrd-setup.sh
Source6: mkinitrd-boot.sh
Patch0: mdadm-3.2.2_git3b1dab1bdbda0
Patch1: auto-line.fix
%description
Mdadm is a program that can be used to control Linux md devices. It is
@ -44,8 +42,6 @@ programs but with a very different interface.
%prep
%setup -q -a1
%patch0 -p1
%patch1 -p1
%build
make %{?_smp_mflags} CC="%__cc" CXFLAGS="$RPM_OPT_FLAGS -Wno-error"
@ -64,9 +60,8 @@ install -m 755 %{S:5} $RPM_BUILD_ROOT/lib/mkinitrd/scripts/setup-md.sh
install -m 755 %{S:6} $RPM_BUILD_ROOT/lib/mkinitrd/scripts/boot-md.sh
install -m 644 %{S:2} $RPM_BUILD_ROOT%{_var}/adm/fillup-templates/
ln -sf ../../etc/init.d/mdadmd $RPM_BUILD_ROOT/%{_sbindir}/rcmdadmd
rm -rf $RPM_BUILD_ROOT/var/run/mdadm
mkdir -p $RPM_BUILD_ROOT/var/run
ln -s mdadm $RPM_BUILD_ROOT/var/run/mdadm
rm -rf $RPM_BUILD_ROOT/run/mdadm
mkdir -p $RPM_BUILD_ROOT/run/mdadm
install -d $RPM_BUILD_ROOT/lib/udev/rules.d
install -m 644 udev-md-raid.rules $RPM_BUILD_ROOT/lib/udev/rules.d/64-md-raid.rules
@ -80,16 +75,9 @@ elif [ -x /sbin/mkinitrd ]; then
fi
%{fillup_and_insserv -y boot.md}
mkdir -p /dev/.mdadm
# replace the /var/run/mdadm directory (installed by sle11/11.1) with
# a symlink pointing to /dev/.mdadm. Do not do this when /var/run/mdadm is
# not empty, let /etc/init.d/boot.md do it at the next reboot.
if test -e /var/run/mdadm -a ! /var/run/mdadm -ef /dev/.mdadm; then
if ! rmdir /var/run/mdadm 2>/dev/null; then
exit 0
fi
ln -s /dev/.mdadm /var/run/mdadm
fi
# If /run/mdadm is already a symlink, this will fail and will have
# to wait for next boot.
mkdir -p /run/mdadm || true
%postun
%restart_on_update mdadmd
@ -120,7 +108,7 @@ rm -rf $RPM_BUILD_ROOT
%dir /lib/udev/devices
%{_sbindir}/*
%{_var}/adm/fillup-templates/sysconfig.mdadm
%ghost /var/run/mdadm
%ghost /run/mdadm
%dir /lib/mkinitrd
%dir /lib/mkinitrd/scripts
/lib/mkinitrd/scripts/setup-md.sh

View File

@ -18,11 +18,8 @@
# load the necessary module before we initialize the raid system
load_modules
# put the mdmon socked and pid file to /dev/.mdadm
rm -rf /var/run/mdadm
mkdir -p /var/run
ln -s /dev/.mdadm /var/run/mdadm
mkdir -p /dev/.mdadm
# Create dir for socket and pid files
mkdir -p /run/mdadm
[ "$mduuid" ] && md_uuid="$mduuid"
md_major=$(sed -ne 's/\s*\([0-9]\+\)\s*md$/\1/p' /proc/devices)