Resolves: bz 505701
This commit is contained in:
parent
fc4f405b55
commit
0376606424
@ -1,6 +1,6 @@
|
|||||||
Name: kexec-tools
|
Name: kexec-tools
|
||||||
Version: 2.0.0
|
Version: 2.0.0
|
||||||
Release: 14%{?dist}
|
Release: 15%{?dist}
|
||||||
License: GPLv2
|
License: GPLv2
|
||||||
Group: Applications/System
|
Group: Applications/System
|
||||||
Summary: The kexec/kdump userspace component.
|
Summary: The kexec/kdump userspace component.
|
||||||
@ -256,6 +256,9 @@ done
|
|||||||
|
|
||||||
|
|
||||||
%changelog
|
%changelog
|
||||||
|
* Mon Jun 15 2009 Neil Horman <nhorman@redhat.com> 2.0.0-15
|
||||||
|
- Fixed some stat drive detect bugs by E. Biederman (bz505701)
|
||||||
|
|
||||||
* Wed May 20 2009 Neil Horman <nhorman@redhat.com> 2.0.0-14
|
* Wed May 20 2009 Neil Horman <nhorman@redhat.com> 2.0.0-14
|
||||||
- Put early copy of mkdumprd2 out in the wild (bz 466392)
|
- Put early copy of mkdumprd2 out in the wild (bz 466392)
|
||||||
|
|
||||||
|
22
mkdumprd
22
mkdumprd
@ -294,9 +294,7 @@ findstoragedriver () {
|
|||||||
fi
|
fi
|
||||||
vecho "Looking for driver for device $device"
|
vecho "Looking for driver for device $device"
|
||||||
device=`echo $device | sed 's/\//\!/g'`
|
device=`echo $device | sed 's/\//\!/g'`
|
||||||
sysfs=$(findone -type d /sys/block -name $device)
|
pushd $(readlink /sys/class/block/$device ) >/dev/null 2>&1 || return
|
||||||
[ -z "$sysfs" ] && return
|
|
||||||
pushd $sysfs >/dev/null 2>&1
|
|
||||||
findstoragedriverinsys
|
findstoragedriverinsys
|
||||||
popd >/dev/null 2>&1
|
popd >/dev/null 2>&1
|
||||||
done
|
done
|
||||||
@ -384,7 +382,7 @@ handlelvordev() {
|
|||||||
vg_list="$vg_list $vg"
|
vg_list="$vg_list $vg"
|
||||||
for device in `vgdisplay -v $vg 2>/dev/null | sed -n 's/PV Name//p'`; do
|
for device in `vgdisplay -v $vg 2>/dev/null | sed -n 's/PV Name//p'`; do
|
||||||
IS_UUID=`echo $device | grep UUID`
|
IS_UUID=`echo $device | grep UUID`
|
||||||
IS_LABEL=`echo $device | grep UUID`
|
IS_LABEL=`echo $device | grep LABEL`
|
||||||
if [ -n "$IS_UUID" -o -n "$IS_LABEL" ]
|
if [ -n "$IS_UUID" -o -n "$IS_LABEL" ]
|
||||||
then
|
then
|
||||||
devname=`findfs $device`
|
devname=`findfs $device`
|
||||||
@ -398,7 +396,7 @@ handlelvordev() {
|
|||||||
esac
|
esac
|
||||||
else
|
else
|
||||||
IS_UUID=`echo $1 | grep UUID`
|
IS_UUID=`echo $1 | grep UUID`
|
||||||
IS_LABEL=`echo $1 | grep UUID`
|
IS_LABEL=`echo $1 | grep LABEL`
|
||||||
if [ -n "$IS_UUID" -o -n "$IS_LABEL" ]
|
if [ -n "$IS_UUID" -o -n "$IS_LABEL" ]
|
||||||
then
|
then
|
||||||
devname=`findfs $1`
|
devname=`findfs $1`
|
||||||
@ -752,22 +750,12 @@ if [ "x$PROBE" == "xyes" ]; then
|
|||||||
netdev=`/sbin/ip route get to $remoteip |sed 's|.*dev \(.*\).*|\1|g' |awk {'print $1;'} |head -n 1`
|
netdev=`/sbin/ip route get to $remoteip |sed 's|.*dev \(.*\).*|\1|g' |awk {'print $1;'} |head -n 1`
|
||||||
net_list="$net_list $netdev"
|
net_list="$net_list $netdev"
|
||||||
# check if it's root by label
|
# check if it's root by label
|
||||||
elif echo $rootdev | cut -c1-6 | grep -q "LABEL=" ; then
|
elif echo $rootdev | cut -c1-6 | grep -q "UUID=\|LABEL=" ; then
|
||||||
rootopts=$(echo $rootopts | sed -e 's/^r[ow],//' -e 's/,r[ow],$//' -e 's/,r[ow],/,/' \
|
dev=`/sbin/findfs $rootdev | sed -e's/\(.*\/\)\(.*$\)/\2/' -e's/[0-9]\+//'`
|
||||||
-e 's/^r[ow]$/defaults/' -e 's/$/,ro/')
|
|
||||||
majmin=$(get_numeric_dev dec /dev/root)
|
|
||||||
if [ -n "$majmin" ]; then
|
|
||||||
dev=$(findall /sys/block -name dev | while read device ; do \
|
|
||||||
echo "$majmin" | cmp -s $device && echo $device ; done \
|
|
||||||
| sed -e 's,.*/\([^/]\+\)/dev,\1,' )
|
|
||||||
if [ -n "$dev" ] ; then
|
if [ -n "$dev" ] ; then
|
||||||
vecho "Found root device $dev for $rootdev"
|
vecho "Found root device $dev for $rootdev"
|
||||||
rootdev=$dev
|
rootdev=$dev
|
||||||
fi
|
fi
|
||||||
fi
|
|
||||||
elif echo $rootdev | cut -c1-6 | grep -q "UUID=" ; then
|
|
||||||
vecho "Found root device $dev for $rootdev"
|
|
||||||
rootdev=`/sbin/findfs $rootdev | sed -e's/\(.*\/\)\(.*$\)/\2/' -e's/[0-9]\+//'`
|
|
||||||
else
|
else
|
||||||
rootopts=$(echo $rootopts | sed -e 's/^r[ow],//' -e 's/,r[ow],$//' -e 's/,r[ow],/,/' \
|
rootopts=$(echo $rootopts | sed -e 's/^r[ow],//' -e 's/,r[ow],$//' -e 's/,r[ow],/,/' \
|
||||||
-e 's/^r[ow]$/defaults/' -e 's/$/,ro/')
|
-e 's/^r[ow]$/defaults/' -e 's/$/,ro/')
|
||||||
|
Loading…
Reference in New Issue
Block a user