dracut-037-1
- version 037
This commit is contained in:
parent
bcb5fa941d
commit
a0be9cac88
@ -1,21 +0,0 @@
|
||||
From d50a99c5ceeb7107f624c5d3238d37509b2217a8 Mon Sep 17 00:00:00 2001
|
||||
From: Harald Hoyer <harald@redhat.com>
|
||||
Date: Wed, 29 Jan 2014 08:37:43 +0100
|
||||
Subject: [PATCH] NEWS: update for version 036
|
||||
|
||||
---
|
||||
NEWS | 4 ++++
|
||||
1 file changed, 4 insertions(+)
|
||||
|
||||
diff --git a/NEWS b/NEWS
|
||||
index 5b88600..ccf279f 100644
|
||||
--- a/NEWS
|
||||
+++ b/NEWS
|
||||
@@ -1,3 +1,7 @@
|
||||
+dracut-036
|
||||
+==========
|
||||
+- fixed skipcpio signature checking
|
||||
+
|
||||
dracut-035
|
||||
==========
|
||||
- changed dracut tarball compression to xz
|
@ -1,50 +0,0 @@
|
||||
From 66bfe863f551389add3a3a53067264ce32eba302 Mon Sep 17 00:00:00 2001
|
||||
From: Harald Hoyer <harald@redhat.com>
|
||||
Date: Thu, 30 Jan 2014 13:50:02 +0100
|
||||
Subject: [PATCH] network: understand ip=.....:<dns1>:<dns2>
|
||||
|
||||
---
|
||||
modules.d/40network/net-lib.sh | 23 +++++++++++++++++------
|
||||
1 file changed, 17 insertions(+), 6 deletions(-)
|
||||
|
||||
diff --git a/modules.d/40network/net-lib.sh b/modules.d/40network/net-lib.sh
|
||||
index 7544401..36fad12 100755
|
||||
--- a/modules.d/40network/net-lib.sh
|
||||
+++ b/modules.d/40network/net-lib.sh
|
||||
@@ -339,7 +339,7 @@ ip_to_var() {
|
||||
fi
|
||||
done
|
||||
|
||||
- unset ip srv gw mask hostname dev autoconf macaddr mtu
|
||||
+ unset ip srv gw mask hostname dev autoconf macaddr mtu dns1 dns2
|
||||
case $# in
|
||||
0) autoconf="error" ;;
|
||||
1) autoconf=$1 ;;
|
||||
@@ -347,11 +347,22 @@ ip_to_var() {
|
||||
3) [ -n "$1" ] && dev=$1; [ -n "$2" ] && autoconf=$2; [ -n "$3" ] && mtu=$3 ;;
|
||||
4) [ -n "$1" ] && dev=$1; [ -n "$2" ] && autoconf=$2; [ -n "$3" ] && mtu=$3; [ -n "$4" ] && macaddr=$4 ;;
|
||||
*) [ -n "$1" ] && ip=$1; [ -n "$2" ] && srv=$2; [ -n "$3" ] && gw=$3; [ -n "$4" ] && mask=$4;
|
||||
- [ -n "$5" ] && hostname=$5; [ -n "$6" ] && dev=$6; [ -n "$7" ] && autoconf=$7; [ -n "$8" ] && mtu=$8;
|
||||
- if [ -n "${9}" -a -n "${10}" -a -n "${11}" -a -n "${12}" -a -n "${13}" -a -n "${14}" ]; then
|
||||
- macaddr="${9}:${10}:${11}:${12}:${13}:${14}"
|
||||
- fi
|
||||
- ;;
|
||||
+ [ -n "$5" ] && hostname=$5; [ -n "$6" ] && dev=$6; [ -n "$7" ] && autoconf=$7;
|
||||
+ case "$8" in
|
||||
+ [0-9]*:*|[0-9]*.[0-9]*.[0-9]*.[0-9]*)
|
||||
+ dns1="$mtu"; unset $mtu
|
||||
+ [ -n "$9" ] && dns2="$9"
|
||||
+ ;;
|
||||
+ [0-9]*)
|
||||
+ mtu="$8"
|
||||
+ ;;
|
||||
+ *)
|
||||
+ if [ -n "${9}" -a -n "${10}" -a -n "${11}" -a -n "${12}" -a -n "${13}" -a -n "${14}" ]; then
|
||||
+ macaddr="${9}:${10}:${11}:${12}:${13}:${14}"
|
||||
+ fi
|
||||
+ ;;
|
||||
+ esac
|
||||
+ ;;
|
||||
esac
|
||||
|
||||
# ip=<ipv4-address> means anaconda-style static config argument cluster:
|
@ -1,36 +0,0 @@
|
||||
From c8a9a6b4a7dff76c66e84f65b2717632e1bb4505 Mon Sep 17 00:00:00 2001
|
||||
From: Harald Hoyer <harald@redhat.com>
|
||||
Date: Thu, 30 Jan 2014 16:11:40 +0100
|
||||
Subject: [PATCH] dracut.sh: only set the owner of files to 0:0, if generated
|
||||
as non-root
|
||||
|
||||
If the root user generates the initramfs image, preserve the ownership
|
||||
of the files. This of course cannot be done for non-root users
|
||||
generating an initramfs image.
|
||||
---
|
||||
dracut.sh | 7 +++++--
|
||||
1 file changed, 5 insertions(+), 2 deletions(-)
|
||||
|
||||
diff --git a/dracut.sh b/dracut.sh
|
||||
index 9b715ab..ccff358 100755
|
||||
--- a/dracut.sh
|
||||
+++ b/dracut.sh
|
||||
@@ -1462,13 +1462,16 @@ fi
|
||||
|
||||
rm -f -- "$outfile"
|
||||
dinfo "*** Creating image file ***"
|
||||
+
|
||||
+[[ "$UID" != 0 ]] && cpio_owner_root="-R 0:0"
|
||||
+
|
||||
if [[ $create_early_cpio = yes ]]; then
|
||||
echo 1 > "$early_cpio_dir/d/early_cpio"
|
||||
# The microcode blob is _before_ the initramfs blob, not after
|
||||
- (cd "$early_cpio_dir/d"; find . -print0 | cpio --null -R 0:0 -H newc -o --quiet >../early.cpio)
|
||||
+ (cd "$early_cpio_dir/d"; find . -print0 | cpio --null $cpio_owner_root -H newc -o --quiet >../early.cpio)
|
||||
mv $early_cpio_dir/early.cpio $outfile.$$
|
||||
fi
|
||||
-if ! ( umask 077; cd "$initdir"; find . -print0 | cpio --null -R 0:0 -H newc -o --quiet | \
|
||||
+if ! ( umask 077; cd "$initdir"; find . -print0 | cpio --null $cpio_owner_root -H newc -o --quiet | \
|
||||
$compress >> "$outfile.$$"; ); then
|
||||
dfatal "dracut: creation of $outfile.$$ failed"
|
||||
exit 1
|
@ -1,22 +0,0 @@
|
||||
From f57850d7e8800cc28c766c77ad0a881a9b6a1f36 Mon Sep 17 00:00:00 2001
|
||||
From: Harald Hoyer <harald@redhat.com>
|
||||
Date: Thu, 30 Jan 2014 14:27:18 +0100
|
||||
Subject: [PATCH] dracut-functions.sh: also search in the updates directory
|
||||
|
||||
---
|
||||
dracut-functions.sh | 2 +-
|
||||
1 file changed, 1 insertion(+), 1 deletion(-)
|
||||
|
||||
diff --git a/dracut-functions.sh b/dracut-functions.sh
|
||||
index 7cfa097..c766ca3 100755
|
||||
--- a/dracut-functions.sh
|
||||
+++ b/dracut-functions.sh
|
||||
@@ -1551,7 +1551,7 @@ find_kernel_modules_by_path () {
|
||||
_OLDIFS=$IFS
|
||||
IFS=:
|
||||
while read a rest; do
|
||||
- [[ $a = */$1/* ]] || continue
|
||||
+ [[ $a = */$1/* ]] || [[ $a = */updates/* ]] || continue
|
||||
printf "%s\n" "$srcmods/$a"
|
||||
done < "$srcmods/modules.dep"
|
||||
IFS=$_OLDIFS
|
@ -1,34 +0,0 @@
|
||||
From e95e48c6eee46ea0d3cbaa9e28576f795204018a Mon Sep 17 00:00:00 2001
|
||||
From: Harald Hoyer <harald@redhat.com>
|
||||
Date: Thu, 30 Jan 2014 17:11:43 +0100
|
||||
Subject: [PATCH] network/net-lib.sh: parse ibft nameserver settings
|
||||
|
||||
---
|
||||
modules.d/40network/net-lib.sh | 5 ++++-
|
||||
1 file changed, 4 insertions(+), 1 deletion(-)
|
||||
|
||||
diff --git a/modules.d/40network/net-lib.sh b/modules.d/40network/net-lib.sh
|
||||
index 36fad12..1b51c85 100755
|
||||
--- a/modules.d/40network/net-lib.sh
|
||||
+++ b/modules.d/40network/net-lib.sh
|
||||
@@ -185,6 +185,7 @@ ibft_to_cmdline() {
|
||||
for iface in /sys/firmware/ibft/ethernet*; do
|
||||
local mac="" dev=""
|
||||
local dhcp="" ip="" gw="" mask="" hostname=""
|
||||
+ local dns1 dns2
|
||||
|
||||
[ -e ${iface}/mac ] || continue
|
||||
mac=$(read a < ${iface}/mac; echo $a)
|
||||
@@ -203,9 +204,11 @@ ibft_to_cmdline() {
|
||||
[ "$ip" = "0.0.0.0" ] && continue
|
||||
[ -e ${iface}/gateway ] && gw=$(read a < ${iface}/gateway; echo $a)
|
||||
[ -e ${iface}/subnet-mask ] && mask=$(read a < ${iface}/subnet-mask; echo $a)
|
||||
+ [ -e ${iface}/primary-dns ] && dns1=$(read a < ${iface}/primary-dns; echo $a)
|
||||
+ [ -e ${iface}/secondary-dns ] && dns2=$(read a < ${iface}/secondary-dns; echo $a)
|
||||
[ -e ${iface}/hostname ] && hostname=$(read a < ${iface}/hostname; echo $a)
|
||||
if [ -n "$ip" ] && [ -n "$mask" ]; then
|
||||
- echo "ip=$ip::$gw:$mask:$hostname:$dev:none"
|
||||
+ echo "ip=$ip::$gw:$mask:$hostname:$dev:none${dns1:+:$dns1}${dns2:+:$dns2}"
|
||||
else
|
||||
warn "${iface} does not contain a valid iBFT configuration"
|
||||
warn "ip-addr=$ip"
|
@ -1,72 +0,0 @@
|
||||
From 1982098e00a545894d7aabba13a99c324e56ed52 Mon Sep 17 00:00:00 2001
|
||||
From: Harald Hoyer <harald@redhat.com>
|
||||
Date: Thu, 30 Jan 2014 17:12:24 +0100
|
||||
Subject: [PATCH] network/ifup.sh: handle $dns1 and $dns2 from "ip=" settings
|
||||
|
||||
---
|
||||
dracut.cmdline.7.asc | 7 +++++++
|
||||
modules.d/40network/ifup.sh | 21 ++++++++++++---------
|
||||
2 files changed, 19 insertions(+), 9 deletions(-)
|
||||
|
||||
diff --git a/dracut.cmdline.7.asc b/dracut.cmdline.7.asc
|
||||
index 963ba07..985285b 100644
|
||||
--- a/dracut.cmdline.7.asc
|
||||
+++ b/dracut.cmdline.7.asc
|
||||
@@ -472,6 +472,13 @@ cannot be used in conjunction with the **ifname** argument for the
|
||||
same <interface>.
|
||||
=====================
|
||||
|
||||
+**ip=**__<client-IP>__:[__<peer>__]:__<gateway-IP>__:__<netmask>__:__<client_hostname>__:__<interface>__:__{none|off|dhcp|on|any|dhcp6|auto6|ibft}__[:[__<dns1>__][:__<dns2>__]]::
|
||||
+ explicit network configuration. If you want do define a IPv6 address, put it
|
||||
+ in brackets (e.g. [2001:DB8::1]). This parameter can be specified multiple
|
||||
+ times. __<peer>__ is optional and is the address of the remote endpoint
|
||||
+ for pointopoint interfaces and it may be followed by a slash and a decimal
|
||||
+ number, encoding the network prefix length.
|
||||
+
|
||||
**ifname=**__<interface>__:__<MAC>__::
|
||||
Assign network device name <interface> (ie "bootnet") to the NIC with
|
||||
MAC <MAC>.
|
||||
diff --git a/modules.d/40network/ifup.sh b/modules.d/40network/ifup.sh
|
||||
index 2edcfe6..b33981b 100755
|
||||
--- a/modules.d/40network/ifup.sh
|
||||
+++ b/modules.d/40network/ifup.sh
|
||||
@@ -264,18 +264,15 @@ if [ "$netif" = "$vlanname" ] && [ ! -e /tmp/net.$vlanname.up ]; then
|
||||
ip link set "$vlanname" up
|
||||
fi
|
||||
|
||||
-# setup nameserver
|
||||
-namesrv=$(getargs nameserver)
|
||||
-if [ -n "$namesrv" ] ; then
|
||||
- for s in $namesrv; do
|
||||
- echo nameserver $s
|
||||
- done
|
||||
-fi >> /tmp/net.$netif.resolv.conf
|
||||
-
|
||||
# No ip lines default to dhcp
|
||||
ip=$(getarg ip)
|
||||
|
||||
if [ -z "$ip" ]; then
|
||||
+ namesrv=$(getargs nameserver)
|
||||
+ for s in $namesrv; do
|
||||
+ echo nameserver $s >> /tmp/net.$netif.resolv.conf
|
||||
+ done
|
||||
+
|
||||
if [ "$netroot" = "dhcp6" ]; then
|
||||
do_dhcp -6
|
||||
else
|
||||
@@ -307,8 +304,14 @@ for p in $(getargs ip=); do
|
||||
[ "$use_bridge" != 'true' ] && \
|
||||
[ "$use_vlan" != 'true' ] && continue
|
||||
|
||||
+ # setup nameserver
|
||||
+ namesrv="$dns1 $dns2 $(getargs nameserver)"
|
||||
+ for s in $namesrv; do
|
||||
+ echo nameserver $s >> /tmp/net.$netif.resolv.conf
|
||||
+ done
|
||||
+
|
||||
# Store config for later use
|
||||
- for i in ip srv gw mask hostname macaddr; do
|
||||
+ for i in ip srv gw mask hostname macaddr dns1 dns2; do
|
||||
eval '[ "$'$i'" ] && echo '$i'="$'$i'"'
|
||||
done > /tmp/net.$netif.override
|
||||
|
@ -1,43 +0,0 @@
|
||||
From c8608373039e66768d34bcf8d43da48d68c5be2a Mon Sep 17 00:00:00 2001
|
||||
From: Harald Hoyer <harald@redhat.com>
|
||||
Date: Fri, 31 Jan 2014 15:33:05 +0100
|
||||
Subject: [PATCH] base/rdsosreport.sh: add dracut version to rdsosreport
|
||||
|
||||
---
|
||||
modules.d/99base/rdsosreport.sh | 16 +++++++++-------
|
||||
1 file changed, 9 insertions(+), 7 deletions(-)
|
||||
|
||||
diff --git a/modules.d/99base/rdsosreport.sh b/modules.d/99base/rdsosreport.sh
|
||||
index 5e11166..3e2ac87 100755
|
||||
--- a/modules.d/99base/rdsosreport.sh
|
||||
+++ b/modules.d/99base/rdsosreport.sh
|
||||
@@ -8,13 +8,7 @@ exec >/run/initramfs/rdsosreport.txt 2>&1
|
||||
|
||||
set -x
|
||||
|
||||
-cat /proc/self/mountinfo
|
||||
-cat /proc/mounts
|
||||
-
|
||||
-blkid
|
||||
-blkid -o udev
|
||||
-
|
||||
-ls -l /dev/disk/by*
|
||||
+cat /lib/dracut/dracut-*
|
||||
|
||||
cat /proc/cmdline
|
||||
|
||||
@@ -26,6 +20,14 @@ for _i in /etc/cmdline.d/*.conf; do
|
||||
cat $_i
|
||||
done
|
||||
|
||||
+cat /proc/self/mountinfo
|
||||
+cat /proc/mounts
|
||||
+
|
||||
+blkid
|
||||
+blkid -o udev
|
||||
+
|
||||
+ls -l /dev/disk/by*
|
||||
+
|
||||
for _i in /etc/conf.d/*.conf; do
|
||||
[ -f "$_i" ] || break
|
||||
echo $_i
|
@ -1,297 +0,0 @@
|
||||
From f52759131bd8d0c118106de9c1f0ddb68bf16521 Mon Sep 17 00:00:00 2001
|
||||
From: Harald Hoyer <harald@redhat.com>
|
||||
Date: Tue, 4 Feb 2014 12:01:11 +0100
|
||||
Subject: [PATCH] test: include the same Makefile.testdir
|
||||
|
||||
---
|
||||
test/TEST-01-BASIC/Makefile | 11 +----------
|
||||
test/TEST-02-SYSTEMD/Makefile | 11 +----------
|
||||
test/TEST-03-USR-MOUNT/Makefile | 11 +----------
|
||||
test/TEST-04-FULL-SYSTEMD/Makefile | 11 +----------
|
||||
test/TEST-10-RAID/Makefile | 11 +----------
|
||||
test/TEST-11-LVM/Makefile | 11 +----------
|
||||
test/TEST-12-RAID-DEG/Makefile | 11 +----------
|
||||
test/TEST-13-ENC-RAID-LVM/Makefile | 11 +----------
|
||||
test/TEST-14-IMSM/Makefile | 11 +----------
|
||||
test/TEST-15-BTRFSRAID/Makefile | 11 +----------
|
||||
test/TEST-16-DMSQUASH/Makefile | 11 +----------
|
||||
test/TEST-17-LVM-THIN/Makefile | 11 +----------
|
||||
test/TEST-20-NFS/Makefile | 11 +----------
|
||||
test/TEST-30-ISCSI/Makefile | 11 +----------
|
||||
test/TEST-40-NBD/Makefile | 11 +----------
|
||||
test/TEST-50-MULTINIC/Makefile | 11 +----------
|
||||
test/TEST-99-RPM/Makefile | 11 +----------
|
||||
17 files changed, 17 insertions(+), 170 deletions(-)
|
||||
|
||||
diff --git a/test/TEST-01-BASIC/Makefile b/test/TEST-01-BASIC/Makefile
|
||||
index aad2705..2dcab81 100644
|
||||
--- a/test/TEST-01-BASIC/Makefile
|
||||
+++ b/test/TEST-01-BASIC/Makefile
|
||||
@@ -1,10 +1 @@
|
||||
-all:
|
||||
- @$(MAKE) -s --no-print-directory -C ../.. all
|
||||
- @V=$(V) basedir=../.. testdir=../ ./test.sh --all
|
||||
-setup:
|
||||
- @$(MAKE) --no-print-directory -C ../.. all
|
||||
- @basedir=../.. testdir=../ ./test.sh --setup
|
||||
-clean:
|
||||
- @basedir=../.. testdir=../ ./test.sh --clean
|
||||
-run:
|
||||
- @basedir=../.. testdir=../ ./test.sh --run
|
||||
+-include ../Makefile.testdir
|
||||
diff --git a/test/TEST-02-SYSTEMD/Makefile b/test/TEST-02-SYSTEMD/Makefile
|
||||
index aad2705..2dcab81 100644
|
||||
--- a/test/TEST-02-SYSTEMD/Makefile
|
||||
+++ b/test/TEST-02-SYSTEMD/Makefile
|
||||
@@ -1,10 +1 @@
|
||||
-all:
|
||||
- @$(MAKE) -s --no-print-directory -C ../.. all
|
||||
- @V=$(V) basedir=../.. testdir=../ ./test.sh --all
|
||||
-setup:
|
||||
- @$(MAKE) --no-print-directory -C ../.. all
|
||||
- @basedir=../.. testdir=../ ./test.sh --setup
|
||||
-clean:
|
||||
- @basedir=../.. testdir=../ ./test.sh --clean
|
||||
-run:
|
||||
- @basedir=../.. testdir=../ ./test.sh --run
|
||||
+-include ../Makefile.testdir
|
||||
diff --git a/test/TEST-03-USR-MOUNT/Makefile b/test/TEST-03-USR-MOUNT/Makefile
|
||||
index aad2705..2dcab81 100644
|
||||
--- a/test/TEST-03-USR-MOUNT/Makefile
|
||||
+++ b/test/TEST-03-USR-MOUNT/Makefile
|
||||
@@ -1,10 +1 @@
|
||||
-all:
|
||||
- @$(MAKE) -s --no-print-directory -C ../.. all
|
||||
- @V=$(V) basedir=../.. testdir=../ ./test.sh --all
|
||||
-setup:
|
||||
- @$(MAKE) --no-print-directory -C ../.. all
|
||||
- @basedir=../.. testdir=../ ./test.sh --setup
|
||||
-clean:
|
||||
- @basedir=../.. testdir=../ ./test.sh --clean
|
||||
-run:
|
||||
- @basedir=../.. testdir=../ ./test.sh --run
|
||||
+-include ../Makefile.testdir
|
||||
diff --git a/test/TEST-04-FULL-SYSTEMD/Makefile b/test/TEST-04-FULL-SYSTEMD/Makefile
|
||||
index aad2705..2dcab81 100644
|
||||
--- a/test/TEST-04-FULL-SYSTEMD/Makefile
|
||||
+++ b/test/TEST-04-FULL-SYSTEMD/Makefile
|
||||
@@ -1,10 +1 @@
|
||||
-all:
|
||||
- @$(MAKE) -s --no-print-directory -C ../.. all
|
||||
- @V=$(V) basedir=../.. testdir=../ ./test.sh --all
|
||||
-setup:
|
||||
- @$(MAKE) --no-print-directory -C ../.. all
|
||||
- @basedir=../.. testdir=../ ./test.sh --setup
|
||||
-clean:
|
||||
- @basedir=../.. testdir=../ ./test.sh --clean
|
||||
-run:
|
||||
- @basedir=../.. testdir=../ ./test.sh --run
|
||||
+-include ../Makefile.testdir
|
||||
diff --git a/test/TEST-10-RAID/Makefile b/test/TEST-10-RAID/Makefile
|
||||
index aad2705..2dcab81 100644
|
||||
--- a/test/TEST-10-RAID/Makefile
|
||||
+++ b/test/TEST-10-RAID/Makefile
|
||||
@@ -1,10 +1 @@
|
||||
-all:
|
||||
- @$(MAKE) -s --no-print-directory -C ../.. all
|
||||
- @V=$(V) basedir=../.. testdir=../ ./test.sh --all
|
||||
-setup:
|
||||
- @$(MAKE) --no-print-directory -C ../.. all
|
||||
- @basedir=../.. testdir=../ ./test.sh --setup
|
||||
-clean:
|
||||
- @basedir=../.. testdir=../ ./test.sh --clean
|
||||
-run:
|
||||
- @basedir=../.. testdir=../ ./test.sh --run
|
||||
+-include ../Makefile.testdir
|
||||
diff --git a/test/TEST-11-LVM/Makefile b/test/TEST-11-LVM/Makefile
|
||||
index aad2705..2dcab81 100644
|
||||
--- a/test/TEST-11-LVM/Makefile
|
||||
+++ b/test/TEST-11-LVM/Makefile
|
||||
@@ -1,10 +1 @@
|
||||
-all:
|
||||
- @$(MAKE) -s --no-print-directory -C ../.. all
|
||||
- @V=$(V) basedir=../.. testdir=../ ./test.sh --all
|
||||
-setup:
|
||||
- @$(MAKE) --no-print-directory -C ../.. all
|
||||
- @basedir=../.. testdir=../ ./test.sh --setup
|
||||
-clean:
|
||||
- @basedir=../.. testdir=../ ./test.sh --clean
|
||||
-run:
|
||||
- @basedir=../.. testdir=../ ./test.sh --run
|
||||
+-include ../Makefile.testdir
|
||||
diff --git a/test/TEST-12-RAID-DEG/Makefile b/test/TEST-12-RAID-DEG/Makefile
|
||||
index aad2705..2dcab81 100644
|
||||
--- a/test/TEST-12-RAID-DEG/Makefile
|
||||
+++ b/test/TEST-12-RAID-DEG/Makefile
|
||||
@@ -1,10 +1 @@
|
||||
-all:
|
||||
- @$(MAKE) -s --no-print-directory -C ../.. all
|
||||
- @V=$(V) basedir=../.. testdir=../ ./test.sh --all
|
||||
-setup:
|
||||
- @$(MAKE) --no-print-directory -C ../.. all
|
||||
- @basedir=../.. testdir=../ ./test.sh --setup
|
||||
-clean:
|
||||
- @basedir=../.. testdir=../ ./test.sh --clean
|
||||
-run:
|
||||
- @basedir=../.. testdir=../ ./test.sh --run
|
||||
+-include ../Makefile.testdir
|
||||
diff --git a/test/TEST-13-ENC-RAID-LVM/Makefile b/test/TEST-13-ENC-RAID-LVM/Makefile
|
||||
index aad2705..2dcab81 100644
|
||||
--- a/test/TEST-13-ENC-RAID-LVM/Makefile
|
||||
+++ b/test/TEST-13-ENC-RAID-LVM/Makefile
|
||||
@@ -1,10 +1 @@
|
||||
-all:
|
||||
- @$(MAKE) -s --no-print-directory -C ../.. all
|
||||
- @V=$(V) basedir=../.. testdir=../ ./test.sh --all
|
||||
-setup:
|
||||
- @$(MAKE) --no-print-directory -C ../.. all
|
||||
- @basedir=../.. testdir=../ ./test.sh --setup
|
||||
-clean:
|
||||
- @basedir=../.. testdir=../ ./test.sh --clean
|
||||
-run:
|
||||
- @basedir=../.. testdir=../ ./test.sh --run
|
||||
+-include ../Makefile.testdir
|
||||
diff --git a/test/TEST-14-IMSM/Makefile b/test/TEST-14-IMSM/Makefile
|
||||
index bc0ddb6..2dcab81 100644
|
||||
--- a/test/TEST-14-IMSM/Makefile
|
||||
+++ b/test/TEST-14-IMSM/Makefile
|
||||
@@ -1,10 +1 @@
|
||||
-all:
|
||||
- @make -s --no-print-directory -C ../.. all
|
||||
- @basedir=../.. testdir=../ ./test.sh --all
|
||||
-setup:
|
||||
- @make --no-print-directory -C ../.. all
|
||||
- @basedir=../.. testdir=../ ./test.sh --setup
|
||||
-clean:
|
||||
- @basedir=../.. testdir=../ ./test.sh --clean
|
||||
-run:
|
||||
- @basedir=../.. testdir=../ ./test.sh --run
|
||||
+-include ../Makefile.testdir
|
||||
diff --git a/test/TEST-15-BTRFSRAID/Makefile b/test/TEST-15-BTRFSRAID/Makefile
|
||||
index aad2705..2dcab81 100644
|
||||
--- a/test/TEST-15-BTRFSRAID/Makefile
|
||||
+++ b/test/TEST-15-BTRFSRAID/Makefile
|
||||
@@ -1,10 +1 @@
|
||||
-all:
|
||||
- @$(MAKE) -s --no-print-directory -C ../.. all
|
||||
- @V=$(V) basedir=../.. testdir=../ ./test.sh --all
|
||||
-setup:
|
||||
- @$(MAKE) --no-print-directory -C ../.. all
|
||||
- @basedir=../.. testdir=../ ./test.sh --setup
|
||||
-clean:
|
||||
- @basedir=../.. testdir=../ ./test.sh --clean
|
||||
-run:
|
||||
- @basedir=../.. testdir=../ ./test.sh --run
|
||||
+-include ../Makefile.testdir
|
||||
diff --git a/test/TEST-16-DMSQUASH/Makefile b/test/TEST-16-DMSQUASH/Makefile
|
||||
index aad2705..2dcab81 100644
|
||||
--- a/test/TEST-16-DMSQUASH/Makefile
|
||||
+++ b/test/TEST-16-DMSQUASH/Makefile
|
||||
@@ -1,10 +1 @@
|
||||
-all:
|
||||
- @$(MAKE) -s --no-print-directory -C ../.. all
|
||||
- @V=$(V) basedir=../.. testdir=../ ./test.sh --all
|
||||
-setup:
|
||||
- @$(MAKE) --no-print-directory -C ../.. all
|
||||
- @basedir=../.. testdir=../ ./test.sh --setup
|
||||
-clean:
|
||||
- @basedir=../.. testdir=../ ./test.sh --clean
|
||||
-run:
|
||||
- @basedir=../.. testdir=../ ./test.sh --run
|
||||
+-include ../Makefile.testdir
|
||||
diff --git a/test/TEST-17-LVM-THIN/Makefile b/test/TEST-17-LVM-THIN/Makefile
|
||||
index aad2705..2dcab81 100644
|
||||
--- a/test/TEST-17-LVM-THIN/Makefile
|
||||
+++ b/test/TEST-17-LVM-THIN/Makefile
|
||||
@@ -1,10 +1 @@
|
||||
-all:
|
||||
- @$(MAKE) -s --no-print-directory -C ../.. all
|
||||
- @V=$(V) basedir=../.. testdir=../ ./test.sh --all
|
||||
-setup:
|
||||
- @$(MAKE) --no-print-directory -C ../.. all
|
||||
- @basedir=../.. testdir=../ ./test.sh --setup
|
||||
-clean:
|
||||
- @basedir=../.. testdir=../ ./test.sh --clean
|
||||
-run:
|
||||
- @basedir=../.. testdir=../ ./test.sh --run
|
||||
+-include ../Makefile.testdir
|
||||
diff --git a/test/TEST-20-NFS/Makefile b/test/TEST-20-NFS/Makefile
|
||||
index aad2705..2dcab81 100644
|
||||
--- a/test/TEST-20-NFS/Makefile
|
||||
+++ b/test/TEST-20-NFS/Makefile
|
||||
@@ -1,10 +1 @@
|
||||
-all:
|
||||
- @$(MAKE) -s --no-print-directory -C ../.. all
|
||||
- @V=$(V) basedir=../.. testdir=../ ./test.sh --all
|
||||
-setup:
|
||||
- @$(MAKE) --no-print-directory -C ../.. all
|
||||
- @basedir=../.. testdir=../ ./test.sh --setup
|
||||
-clean:
|
||||
- @basedir=../.. testdir=../ ./test.sh --clean
|
||||
-run:
|
||||
- @basedir=../.. testdir=../ ./test.sh --run
|
||||
+-include ../Makefile.testdir
|
||||
diff --git a/test/TEST-30-ISCSI/Makefile b/test/TEST-30-ISCSI/Makefile
|
||||
index aad2705..2dcab81 100644
|
||||
--- a/test/TEST-30-ISCSI/Makefile
|
||||
+++ b/test/TEST-30-ISCSI/Makefile
|
||||
@@ -1,10 +1 @@
|
||||
-all:
|
||||
- @$(MAKE) -s --no-print-directory -C ../.. all
|
||||
- @V=$(V) basedir=../.. testdir=../ ./test.sh --all
|
||||
-setup:
|
||||
- @$(MAKE) --no-print-directory -C ../.. all
|
||||
- @basedir=../.. testdir=../ ./test.sh --setup
|
||||
-clean:
|
||||
- @basedir=../.. testdir=../ ./test.sh --clean
|
||||
-run:
|
||||
- @basedir=../.. testdir=../ ./test.sh --run
|
||||
+-include ../Makefile.testdir
|
||||
diff --git a/test/TEST-40-NBD/Makefile b/test/TEST-40-NBD/Makefile
|
||||
index aad2705..2dcab81 100644
|
||||
--- a/test/TEST-40-NBD/Makefile
|
||||
+++ b/test/TEST-40-NBD/Makefile
|
||||
@@ -1,10 +1 @@
|
||||
-all:
|
||||
- @$(MAKE) -s --no-print-directory -C ../.. all
|
||||
- @V=$(V) basedir=../.. testdir=../ ./test.sh --all
|
||||
-setup:
|
||||
- @$(MAKE) --no-print-directory -C ../.. all
|
||||
- @basedir=../.. testdir=../ ./test.sh --setup
|
||||
-clean:
|
||||
- @basedir=../.. testdir=../ ./test.sh --clean
|
||||
-run:
|
||||
- @basedir=../.. testdir=../ ./test.sh --run
|
||||
+-include ../Makefile.testdir
|
||||
diff --git a/test/TEST-50-MULTINIC/Makefile b/test/TEST-50-MULTINIC/Makefile
|
||||
index aad2705..2dcab81 100644
|
||||
--- a/test/TEST-50-MULTINIC/Makefile
|
||||
+++ b/test/TEST-50-MULTINIC/Makefile
|
||||
@@ -1,10 +1 @@
|
||||
-all:
|
||||
- @$(MAKE) -s --no-print-directory -C ../.. all
|
||||
- @V=$(V) basedir=../.. testdir=../ ./test.sh --all
|
||||
-setup:
|
||||
- @$(MAKE) --no-print-directory -C ../.. all
|
||||
- @basedir=../.. testdir=../ ./test.sh --setup
|
||||
-clean:
|
||||
- @basedir=../.. testdir=../ ./test.sh --clean
|
||||
-run:
|
||||
- @basedir=../.. testdir=../ ./test.sh --run
|
||||
+-include ../Makefile.testdir
|
||||
diff --git a/test/TEST-99-RPM/Makefile b/test/TEST-99-RPM/Makefile
|
||||
index aad2705..2dcab81 100644
|
||||
--- a/test/TEST-99-RPM/Makefile
|
||||
+++ b/test/TEST-99-RPM/Makefile
|
||||
@@ -1,10 +1 @@
|
||||
-all:
|
||||
- @$(MAKE) -s --no-print-directory -C ../.. all
|
||||
- @V=$(V) basedir=../.. testdir=../ ./test.sh --all
|
||||
-setup:
|
||||
- @$(MAKE) --no-print-directory -C ../.. all
|
||||
- @basedir=../.. testdir=../ ./test.sh --setup
|
||||
-clean:
|
||||
- @basedir=../.. testdir=../ ./test.sh --clean
|
||||
-run:
|
||||
- @basedir=../.. testdir=../ ./test.sh --run
|
||||
+-include ../Makefile.testdir
|
@ -1,26 +0,0 @@
|
||||
From d61a423f7cb326848e952d9e13a8cbf25ca06631 Mon Sep 17 00:00:00 2001
|
||||
From: Harald Hoyer <harald@redhat.com>
|
||||
Date: Tue, 4 Feb 2014 12:02:05 +0100
|
||||
Subject: [PATCH] network/ifup: do not ifup an already setup network interface
|
||||
|
||||
---
|
||||
modules.d/40network/ifup.sh | 6 +++++-
|
||||
1 file changed, 5 insertions(+), 1 deletion(-)
|
||||
|
||||
diff --git a/modules.d/40network/ifup.sh b/modules.d/40network/ifup.sh
|
||||
index b33981b..3a03d05 100755
|
||||
--- a/modules.d/40network/ifup.sh
|
||||
+++ b/modules.d/40network/ifup.sh
|
||||
@@ -80,7 +80,11 @@ fi
|
||||
# in netroot case we prefer netroot to bringup $netif automaticlly
|
||||
[ -n "$2" -a "$2" = "-m" ] && [ -z "$netroot" ] && manualup="$2"
|
||||
[ -z "$netroot" ] && [ -z "$manualup" ] && exit 0
|
||||
-[ -n "$manualup" ] && >/tmp/net.$netif.manualup
|
||||
+if [ -n "$manualup" ]; then
|
||||
+ >/tmp/net.$netif.manualup
|
||||
+else
|
||||
+ [ -f /tmp/net.${iface}.did-setup ] && exit 0
|
||||
+fi
|
||||
|
||||
# Run dhclient
|
||||
do_dhcp() {
|
@ -1,23 +0,0 @@
|
||||
From c84618d7ac5cf87c6efaaca00e52f69dcff954e1 Mon Sep 17 00:00:00 2001
|
||||
From: Harald Hoyer <harald@redhat.com>
|
||||
Date: Tue, 4 Feb 2014 12:02:34 +0100
|
||||
Subject: [PATCH] network/ifup: do not run dhclient twice on the same interface
|
||||
|
||||
---
|
||||
modules.d/40network/ifup.sh | 3 +++
|
||||
1 file changed, 3 insertions(+)
|
||||
|
||||
diff --git a/modules.d/40network/ifup.sh b/modules.d/40network/ifup.sh
|
||||
index 3a03d05..33ec81d 100755
|
||||
--- a/modules.d/40network/ifup.sh
|
||||
+++ b/modules.d/40network/ifup.sh
|
||||
@@ -91,6 +91,9 @@ do_dhcp() {
|
||||
# dhclient-script will mark the netif up and generate the online
|
||||
# event for nfsroot
|
||||
# XXX add -V vendor class and option parsing per kernel
|
||||
+
|
||||
+ [ -e /tmp/dhclient.$netif.pid ] && return 0
|
||||
+
|
||||
if ! iface_has_link $netif; then
|
||||
echo "No carrier detected"
|
||||
return 1
|
@ -1,23 +0,0 @@
|
||||
From 81aed4f28eca81b151e2f0ee307a2a487fb2bfcc Mon Sep 17 00:00:00 2001
|
||||
From: Harald Hoyer <harald@redhat.com>
|
||||
Date: Wed, 5 Feb 2014 13:06:29 +0100
|
||||
Subject: [PATCH] nfs/nfsroot: symlink /dev/null to /dev/nfs, as a marker for
|
||||
root=/dev/nfs
|
||||
|
||||
---
|
||||
modules.d/95nfs/nfsroot.sh | 2 +-
|
||||
1 file changed, 1 insertion(+), 1 deletion(-)
|
||||
|
||||
diff --git a/modules.d/95nfs/nfsroot.sh b/modules.d/95nfs/nfsroot.sh
|
||||
index f04159e..d0719ef 100755
|
||||
--- a/modules.d/95nfs/nfsroot.sh
|
||||
+++ b/modules.d/95nfs/nfsroot.sh
|
||||
@@ -16,7 +16,7 @@ NEWROOT="$3"
|
||||
nfs_to_var $root $netif
|
||||
[ -z "$server" ] && die "Required parameter 'server' is missing"
|
||||
|
||||
-mount_nfs $root $NEWROOT $netif && { [ -e /dev/root ] || ln -s null /dev/root ; }
|
||||
+mount_nfs $root $NEWROOT $netif && { [ -e /dev/root ] || ln -s null /dev/root ; [ -e /dev/nfs ] || ln -s null /dev/nfs; }
|
||||
|
||||
[ -f $NEWROOT/etc/fstab ] && cat $NEWROOT/etc/fstab > /dev/null
|
||||
|
@ -1,37 +0,0 @@
|
||||
From 751c7de98af289970e4f827245647080cf2595b3 Mon Sep 17 00:00:00 2001
|
||||
From: Harald Hoyer <harald@redhat.com>
|
||||
Date: Wed, 5 Feb 2014 13:08:54 +0100
|
||||
Subject: [PATCH] systemd/dracut-pre-pivot: run for /dev/{nfs,root} and cleanup
|
||||
/dev/nfs
|
||||
|
||||
dracut-pre-pivot was not cleaning up /dev/nfs and did not run to clean
|
||||
up /dev/root.
|
||||
---
|
||||
modules.d/98systemd/dracut-pre-pivot.service | 2 ++
|
||||
modules.d/98systemd/dracut-pre-pivot.sh | 1 +
|
||||
2 files changed, 3 insertions(+)
|
||||
|
||||
diff --git a/modules.d/98systemd/dracut-pre-pivot.service b/modules.d/98systemd/dracut-pre-pivot.service
|
||||
index dd4e49b..6db1f2c 100644
|
||||
--- a/modules.d/98systemd/dracut-pre-pivot.service
|
||||
+++ b/modules.d/98systemd/dracut-pre-pivot.service
|
||||
@@ -19,6 +19,8 @@ ConditionDirectoryNotEmpty=|/lib/dracut/hooks/cleanup
|
||||
ConditionKernelCommandLine=|rd.break=pre-pivot
|
||||
ConditionKernelCommandLine=|rd.break=cleanup
|
||||
ConditionKernelCommandLine=|rd.break
|
||||
+ConditionPathExists=|/dev/root
|
||||
+ConditionPathExists=|/dev/nfs
|
||||
|
||||
[Service]
|
||||
Environment=DRACUT_SYSTEMD=1
|
||||
diff --git a/modules.d/98systemd/dracut-pre-pivot.sh b/modules.d/98systemd/dracut-pre-pivot.sh
|
||||
index 8c7554e..e62a1ce 100755
|
||||
--- a/modules.d/98systemd/dracut-pre-pivot.sh
|
||||
+++ b/modules.d/98systemd/dracut-pre-pivot.sh
|
||||
@@ -24,5 +24,6 @@ getarg rd.break -d rdbreak && emergency_shell -n switch_root "Break before switc
|
||||
|
||||
# remove helper symlink
|
||||
[ -h /dev/root ] && rm -f -- /dev/root
|
||||
+[ -h /dev/nfs ] && rm -f -- /dev/nfs
|
||||
|
||||
exit 0
|
@ -1,102 +0,0 @@
|
||||
From 352d557d4d94042e321b4acc81eeab8691e19f42 Mon Sep 17 00:00:00 2001
|
||||
From: Harald Hoyer <harald@redhat.com>
|
||||
Date: Wed, 5 Feb 2014 13:12:29 +0100
|
||||
Subject: [PATCH] Do not reload systemd with wait_for_dev
|
||||
|
||||
---
|
||||
modules.d/90dmsquash-live/dmsquash-live-genrules.sh | 2 +-
|
||||
modules.d/90dmsquash-live/parse-dmsquash-live.sh | 2 +-
|
||||
modules.d/90livenet/parse-livenet.sh | 2 +-
|
||||
modules.d/90lvm/parse-lvm.sh | 2 +-
|
||||
modules.d/95iscsi/iscsiroot.sh | 2 +-
|
||||
modules.d/95nbd/nbdroot.sh | 2 +-
|
||||
modules.d/95nbd/parse-nbdroot.sh | 2 +-
|
||||
7 files changed, 7 insertions(+), 7 deletions(-)
|
||||
|
||||
diff --git a/modules.d/90dmsquash-live/dmsquash-live-genrules.sh b/modules.d/90dmsquash-live/dmsquash-live-genrules.sh
|
||||
index b27fccc..0f51ed4 100755
|
||||
--- a/modules.d/90dmsquash-live/dmsquash-live-genrules.sh
|
||||
+++ b/modules.d/90dmsquash-live/dmsquash-live-genrules.sh
|
||||
@@ -9,7 +9,7 @@ case "$root" in
|
||||
printf 'SYMLINK=="%s", RUN+="/sbin/initqueue --settled --onetime --unique /sbin/dmsquash-live-root $env{DEVNAME}"\n' \
|
||||
${root#live:/dev/}
|
||||
} >> /etc/udev/rules.d/99-live-squash.rules
|
||||
- wait_for_dev "${root#live:}"
|
||||
+ wait_for_dev -n "${root#live:}"
|
||||
;;
|
||||
live:*)
|
||||
if [ -f "${root#live:}" ]; then
|
||||
diff --git a/modules.d/90dmsquash-live/parse-dmsquash-live.sh b/modules.d/90dmsquash-live/parse-dmsquash-live.sh
|
||||
index a5564e2..6e54dfe 100755
|
||||
--- a/modules.d/90dmsquash-live/parse-dmsquash-live.sh
|
||||
+++ b/modules.d/90dmsquash-live/parse-dmsquash-live.sh
|
||||
@@ -56,4 +56,4 @@ info "root was $liveroot, is now $root"
|
||||
# make sure that init doesn't complain
|
||||
[ -z "$root" ] && root="live"
|
||||
|
||||
-wait_for_dev /dev/mapper/live-rw
|
||||
+wait_for_dev -n /dev/mapper/live-rw
|
||||
diff --git a/modules.d/90livenet/parse-livenet.sh b/modules.d/90livenet/parse-livenet.sh
|
||||
index 6c847ba..a6b2842 100755
|
||||
--- a/modules.d/90livenet/parse-livenet.sh
|
||||
+++ b/modules.d/90livenet/parse-livenet.sh
|
||||
@@ -27,7 +27,7 @@ if get_url_handler "$liveurl" >/dev/null; then
|
||||
netroot="livenet:$liveurl"
|
||||
root="livenet" # quiet complaints from init
|
||||
rootok=1
|
||||
- wait_for_dev /dev/root
|
||||
+ wait_for_dev -n /dev/root
|
||||
else
|
||||
info "livenet: no url handler for $liveurl"
|
||||
fi
|
||||
diff --git a/modules.d/90lvm/parse-lvm.sh b/modules.d/90lvm/parse-lvm.sh
|
||||
index 74e1d43..d69cb45 100755
|
||||
--- a/modules.d/90lvm/parse-lvm.sh
|
||||
+++ b/modules.d/90lvm/parse-lvm.sh
|
||||
@@ -13,7 +13,7 @@ if ! getargbool 1 rd.lvm -d -n rd_NO_LVM \
|
||||
rm -f -- /etc/udev/rules.d/64-lvm*.rules
|
||||
else
|
||||
for dev in $LV_DEVS; do
|
||||
- wait_for_dev "/dev/$dev"
|
||||
+ wait_for_dev -n "/dev/$dev"
|
||||
done
|
||||
fi
|
||||
|
||||
diff --git a/modules.d/95iscsi/iscsiroot.sh b/modules.d/95iscsi/iscsiroot.sh
|
||||
index 769124f..c56d54d 100755
|
||||
--- a/modules.d/95iscsi/iscsiroot.sh
|
||||
+++ b/modules.d/95iscsi/iscsiroot.sh
|
||||
@@ -156,7 +156,7 @@ handle_netroot()
|
||||
printf 'SYMLINK=="disk/by-path/*-iscsi-*-%s", SYMLINK+="root"\n' $iscsi_lun >> /etc/udev/rules.d/99-iscsi-root.rules
|
||||
udevadm control --reload
|
||||
write_fs_tab /dev/root
|
||||
- wait_for_dev /dev/root
|
||||
+ wait_for_dev -n /dev/root
|
||||
|
||||
# install mount script
|
||||
[ -z "$DRACUT_SYSTEMD" ] && \
|
||||
diff --git a/modules.d/95nbd/nbdroot.sh b/modules.d/95nbd/nbdroot.sh
|
||||
index 2e9d917..32f346d 100755
|
||||
--- a/modules.d/95nbd/nbdroot.sh
|
||||
+++ b/modules.d/95nbd/nbdroot.sh
|
||||
@@ -102,7 +102,7 @@ if [ "$root" = "block:/dev/root" -o "$root" = "dhcp" ]; then
|
||||
udevadm control --reload
|
||||
type write_fs_tab >/dev/null 2>&1 || . /lib/fs-lib.sh
|
||||
write_fs_tab /dev/root "$nbdfstype" "$fsopts"
|
||||
- wait_for_dev /dev/root
|
||||
+ wait_for_dev -n /dev/root
|
||||
|
||||
if [ -z "$DRACUT_SYSTEMD" ]; then
|
||||
printf '/bin/mount %s\n' \
|
||||
diff --git a/modules.d/95nbd/parse-nbdroot.sh b/modules.d/95nbd/parse-nbdroot.sh
|
||||
index 49c44b6..fe5a7fa 100755
|
||||
--- a/modules.d/95nbd/parse-nbdroot.sh
|
||||
+++ b/modules.d/95nbd/parse-nbdroot.sh
|
||||
@@ -61,6 +61,6 @@ rootok=1
|
||||
# Shut up init error check
|
||||
if [ -z "$root" ]; then
|
||||
root=block:/dev/root
|
||||
- wait_for_dev /dev/root
|
||||
+ wait_for_dev -n /dev/root
|
||||
fi
|
||||
|
@ -1,31 +0,0 @@
|
||||
From 8d21728942b52f1fe258ab63acfa5a0542d8b1fc Mon Sep 17 00:00:00 2001
|
||||
From: Harald Hoyer <harald@redhat.com>
|
||||
Date: Wed, 5 Feb 2014 13:58:33 +0100
|
||||
Subject: [PATCH] systemd: add sys-kernel-config.mount
|
||||
|
||||
---
|
||||
modules.d/98systemd/module-setup.sh | 4 ++++
|
||||
1 file changed, 4 insertions(+)
|
||||
|
||||
diff --git a/modules.d/98systemd/module-setup.sh b/modules.d/98systemd/module-setup.sh
|
||||
index d625ea0..036f1c1 100755
|
||||
--- a/modules.d/98systemd/module-setup.sh
|
||||
+++ b/modules.d/98systemd/module-setup.sh
|
||||
@@ -44,6 +44,7 @@ install() {
|
||||
$systemdutildir/systemd-modules-load \
|
||||
$systemdutildir/systemd-vconsole-setup \
|
||||
$systemdutildir/system-generators/systemd-fstab-generator \
|
||||
+ \
|
||||
$systemdsystemunitdir/cryptsetup.target \
|
||||
$systemdsystemunitdir/emergency.target \
|
||||
$systemdsystemunitdir/sysinit.target \
|
||||
@@ -72,6 +73,9 @@ install() {
|
||||
$systemdsystemunitdir/timers.target \
|
||||
$systemdsystemunitdir/paths.target \
|
||||
$systemdsystemunitdir/umount.target \
|
||||
+ \
|
||||
+ $systemdsystemunitdir/sys-kernel-config.mount \
|
||||
+ \
|
||||
$systemdsystemunitdir/kmod-static-nodes.service \
|
||||
$systemdsystemunitdir/systemd-tmpfiles-setup-dev.service \
|
||||
$systemdsystemunitdir/systemd-ask-password-console.path \
|
@ -1,735 +0,0 @@
|
||||
From 30e6e809ed8d189cc8374df3c28cfbcab5a299b9 Mon Sep 17 00:00:00 2001
|
||||
From: Harald Hoyer <harald@redhat.com>
|
||||
Date: Thu, 6 Feb 2014 16:45:20 +0100
|
||||
Subject: [PATCH] Factor out all the "type -V" commands
|
||||
|
||||
Add new functions require_binaries() and require_any_binary() to be used
|
||||
in the check() section of module-setup.sh.
|
||||
|
||||
These functions print a warning line telling the user, which binary is
|
||||
missing for the specific dracut module.
|
||||
|
||||
This unifies the way of checking for binaries and makes the life of an
|
||||
initramfs creator easier, if he wants to find out why a specific dracut
|
||||
module is not included in the initramfs.
|
||||
---
|
||||
dracut-functions.sh | 57 ++++++++++++++++++++++++---
|
||||
modules.d/00bash/module-setup.sh | 2 +-
|
||||
modules.d/00bootchart/module-setup.sh | 2 +-
|
||||
modules.d/00dash/module-setup.sh | 2 +-
|
||||
modules.d/00systemd-bootchart/module-setup.sh | 2 +-
|
||||
modules.d/02caps/module-setup.sh | 14 ++++---
|
||||
modules.d/03modsign/module-setup.sh | 2 +-
|
||||
modules.d/05busybox/module-setup.sh | 2 +-
|
||||
modules.d/10i18n/module-setup.sh | 4 +-
|
||||
modules.d/40network/module-setup.sh | 7 +---
|
||||
modules.d/45url-lib/module-setup.sh | 2 +-
|
||||
modules.d/50plymouth/module-setup.sh | 2 +-
|
||||
modules.d/90btrfs/module-setup.sh | 2 +-
|
||||
modules.d/90crypt/module-setup.sh | 2 +-
|
||||
modules.d/90dm/module-setup.sh | 2 +-
|
||||
modules.d/90dmraid/module-setup.sh | 2 +-
|
||||
modules.d/90lvm/module-setup.sh | 2 +-
|
||||
modules.d/90mdraid/module-setup.sh | 2 +-
|
||||
modules.d/90multipath/module-setup.sh | 2 +-
|
||||
modules.d/91crypt-gpg/module-setup.sh | 2 +-
|
||||
modules.d/91crypt-loop/module-setup.sh | 20 ++++++----
|
||||
modules.d/95cifs/module-setup.sh | 2 +-
|
||||
modules.d/95dasd/module-setup.sh | 2 +-
|
||||
modules.d/95dasd_mod/module-setup.sh | 1 +
|
||||
modules.d/95dasd_rules/module-setup.sh | 2 +-
|
||||
modules.d/95fcoe-uefi/module-setup.sh | 4 +-
|
||||
modules.d/95fcoe/module-setup.sh | 5 +--
|
||||
modules.d/95iscsi/module-setup.sh | 2 +-
|
||||
modules.d/95nbd/module-setup.sh | 2 +-
|
||||
modules.d/95nfs/module-setup.sh | 4 +-
|
||||
modules.d/95ssh-client/module-setup.sh | 6 +--
|
||||
modules.d/95udev-rules/module-setup.sh | 2 +-
|
||||
modules.d/95zfcp/module-setup.sh | 3 +-
|
||||
modules.d/95zfcp_rules/module-setup.sh | 2 +-
|
||||
modules.d/95znet/module-setup.sh | 3 +-
|
||||
modules.d/97biosdevname/module-setup.sh | 2 +-
|
||||
modules.d/97masterkey/module-setup.sh | 2 +-
|
||||
modules.d/98systemd/module-setup.sh | 2 +-
|
||||
modules.d/99img-lib/module-setup.sh | 4 +-
|
||||
39 files changed, 113 insertions(+), 71 deletions(-)
|
||||
|
||||
diff --git a/dracut-functions.sh b/dracut-functions.sh
|
||||
index c766ca3..32f264b 100755
|
||||
--- a/dracut-functions.sh
|
||||
+++ b/dracut-functions.sh
|
||||
@@ -35,6 +35,51 @@ fi
|
||||
# Generic substring function. If $2 is in $1, return 0.
|
||||
strstr() { [[ $1 = *$2* ]]; }
|
||||
|
||||
+# helper function for check() in module-setup.sh
|
||||
+# to check for required installed binaries
|
||||
+# issues a standardized warning message
|
||||
+require_binaries() {
|
||||
+ local _module_name="${moddir##*/}"
|
||||
+ local _ret=0
|
||||
+
|
||||
+ if [[ "$1" = "-m" ]]; then
|
||||
+ _module_name="$2"
|
||||
+ shift 2
|
||||
+ fi
|
||||
+
|
||||
+ for cmd in "$@"; do
|
||||
+ if ! find_binary "$cmd" &>/dev/null; then
|
||||
+ dwarning "$_module_name: Could not find command '$cmd'!"
|
||||
+ ((_ret++))
|
||||
+ fi
|
||||
+ done
|
||||
+ return $_ret
|
||||
+}
|
||||
+
|
||||
+require_any_binary() {
|
||||
+ local _module_name="${moddir##*/}"
|
||||
+ local _ret=1
|
||||
+
|
||||
+ if [[ "$1" = "-m" ]]; then
|
||||
+ _module_name="$2"
|
||||
+ shift 2
|
||||
+ fi
|
||||
+
|
||||
+ for cmd in "$@"; do
|
||||
+ if find_binary "$cmd" &>/dev/null; then
|
||||
+ _ret=0
|
||||
+ break
|
||||
+ fi
|
||||
+ done
|
||||
+
|
||||
+ if (( $_ret != 0 )); then
|
||||
+ dwarning "$_module_name: Could not find any command of '$@'!"
|
||||
+ return 1
|
||||
+ fi
|
||||
+
|
||||
+ return 0
|
||||
+}
|
||||
+
|
||||
# find a binary. If we were not passed the full path directly,
|
||||
# search in the usual places to find the binary.
|
||||
find_binary() {
|
||||
@@ -1084,7 +1129,7 @@ module_check() {
|
||||
. $_moddir/module-setup.sh
|
||||
is_func check || return 0
|
||||
[ $_forced -ne 0 ] && unset hostonly
|
||||
- check $hostonly
|
||||
+ moddir=$_moddir check $hostonly
|
||||
_ret=$?
|
||||
unset check depends cmdline install installkernel
|
||||
fi
|
||||
@@ -1110,7 +1155,7 @@ module_check_mount() {
|
||||
unset check depends cmdline install installkernel
|
||||
check() { false; }
|
||||
. $_moddir/module-setup.sh
|
||||
- check 0
|
||||
+ moddir=$_moddir check 0
|
||||
_ret=$?
|
||||
unset check depends cmdline install installkernel
|
||||
fi
|
||||
@@ -1134,7 +1179,7 @@ module_depends() {
|
||||
unset check depends cmdline install installkernel
|
||||
depends() { true; }
|
||||
. $_moddir/module-setup.sh
|
||||
- depends
|
||||
+ moddir=$_moddir depends
|
||||
_ret=$?
|
||||
unset check depends cmdline install installkernel
|
||||
return $_ret
|
||||
@@ -1155,7 +1200,7 @@ module_cmdline() {
|
||||
unset check depends cmdline install installkernel
|
||||
cmdline() { true; }
|
||||
. $_moddir/module-setup.sh
|
||||
- cmdline
|
||||
+ moddir=$_moddir cmdline
|
||||
_ret=$?
|
||||
unset check depends cmdline install installkernel
|
||||
return $_ret
|
||||
@@ -1176,7 +1221,7 @@ module_install() {
|
||||
unset check depends cmdline install installkernel
|
||||
install() { true; }
|
||||
. $_moddir/module-setup.sh
|
||||
- install
|
||||
+ moddir=$_moddir install
|
||||
_ret=$?
|
||||
unset check depends cmdline install installkernel
|
||||
return $_ret
|
||||
@@ -1197,7 +1242,7 @@ module_installkernel() {
|
||||
unset check depends cmdline install installkernel
|
||||
installkernel() { true; }
|
||||
. $_moddir/module-setup.sh
|
||||
- installkernel
|
||||
+ moddir=$_moddir installkernel
|
||||
_ret=$?
|
||||
unset check depends cmdline install installkernel
|
||||
return $_ret
|
||||
diff --git a/modules.d/00bash/module-setup.sh b/modules.d/00bash/module-setup.sh
|
||||
index f599940..e8fc115 100755
|
||||
--- a/modules.d/00bash/module-setup.sh
|
||||
+++ b/modules.d/00bash/module-setup.sh
|
||||
@@ -4,7 +4,7 @@
|
||||
|
||||
# called by dracut
|
||||
check() {
|
||||
- [ -x /bin/bash ]
|
||||
+ require_binaries /bin/bash
|
||||
}
|
||||
|
||||
# called by dracut
|
||||
diff --git a/modules.d/00bootchart/module-setup.sh b/modules.d/00bootchart/module-setup.sh
|
||||
index 107ee5b..95e5c4b 100755
|
||||
--- a/modules.d/00bootchart/module-setup.sh
|
||||
+++ b/modules.d/00bootchart/module-setup.sh
|
||||
@@ -5,7 +5,7 @@
|
||||
# called by dracut
|
||||
check() {
|
||||
[[ "$mount_needs" ]] && return 1
|
||||
- [ -x /sbin/bootchartd ] || return 1
|
||||
+ require_binaries /sbin/bootchartd || return 1
|
||||
return 255
|
||||
}
|
||||
|
||||
diff --git a/modules.d/00dash/module-setup.sh b/modules.d/00dash/module-setup.sh
|
||||
index 47f7b03..8f7deec 100755
|
||||
--- a/modules.d/00dash/module-setup.sh
|
||||
+++ b/modules.d/00dash/module-setup.sh
|
||||
@@ -4,7 +4,7 @@
|
||||
|
||||
# called by dracut
|
||||
check() {
|
||||
- [ -x /bin/dash ]
|
||||
+ require_binaries /bin/dash
|
||||
}
|
||||
|
||||
# called by dracut
|
||||
diff --git a/modules.d/00systemd-bootchart/module-setup.sh b/modules.d/00systemd-bootchart/module-setup.sh
|
||||
index a897cef..5cca254 100755
|
||||
--- a/modules.d/00systemd-bootchart/module-setup.sh
|
||||
+++ b/modules.d/00systemd-bootchart/module-setup.sh
|
||||
@@ -5,7 +5,7 @@
|
||||
# called by dracut
|
||||
check() {
|
||||
[[ "$mount_needs" ]] && return 1
|
||||
- [ -x $systemdutildir/systemd-bootchart ] || return 1
|
||||
+ require_binaries $systemdutildir/systemd-bootchart || return 1
|
||||
return 255
|
||||
}
|
||||
|
||||
diff --git a/modules.d/02caps/module-setup.sh b/modules.d/02caps/module-setup.sh
|
||||
index 6019188..46e35a0 100755
|
||||
--- a/modules.d/02caps/module-setup.sh
|
||||
+++ b/modules.d/02caps/module-setup.sh
|
||||
@@ -4,7 +4,7 @@
|
||||
|
||||
# called by dracut
|
||||
check() {
|
||||
- type -P capsh >/dev/null 2>&1
|
||||
+ require_binaries capsh
|
||||
}
|
||||
|
||||
# called by dracut
|
||||
@@ -14,9 +14,13 @@ depends() {
|
||||
|
||||
# called by dracut
|
||||
install() {
|
||||
- inst_hook pre-pivot 00 "$moddir/caps.sh"
|
||||
- inst $(type -P capsh 2>/dev/null) /usr/sbin/capsh
|
||||
- # capsh wants bash and we need bash also
|
||||
- inst /bin/bash
|
||||
+ if ! dracut_module_included "systemd"; then
|
||||
+ inst_hook pre-pivot 00 "$moddir/caps.sh"
|
||||
+ inst $(type -P capsh 2>/dev/null) /usr/sbin/capsh
|
||||
+ # capsh wants bash and we need bash also
|
||||
+ inst /bin/bash
|
||||
+ else
|
||||
+ dwarning "caps: does not work with systemd in the initramfs"
|
||||
+ fi
|
||||
}
|
||||
|
||||
diff --git a/modules.d/03modsign/module-setup.sh b/modules.d/03modsign/module-setup.sh
|
||||
index 5dfd90c..09285d3 100755
|
||||
--- a/modules.d/03modsign/module-setup.sh
|
||||
+++ b/modules.d/03modsign/module-setup.sh
|
||||
@@ -9,7 +9,7 @@
|
||||
|
||||
# called by dracut
|
||||
check() {
|
||||
- [[ -x /usr/bin/keyctl ]] || return 1
|
||||
+ require_binaries keyctl || return 1
|
||||
|
||||
# do not include module in hostonly mode,
|
||||
# if no keys are present
|
||||
diff --git a/modules.d/05busybox/module-setup.sh b/modules.d/05busybox/module-setup.sh
|
||||
index 6e508a6..228ff8c 100755
|
||||
--- a/modules.d/05busybox/module-setup.sh
|
||||
+++ b/modules.d/05busybox/module-setup.sh
|
||||
@@ -4,7 +4,7 @@
|
||||
|
||||
# called by dracut
|
||||
check() {
|
||||
- type -P busybox >/dev/null || return 1
|
||||
+ require_binaries busybox || return 1
|
||||
|
||||
return 255
|
||||
}
|
||||
diff --git a/modules.d/10i18n/module-setup.sh b/modules.d/10i18n/module-setup.sh
|
||||
index fcb18d1..a091f89 100755
|
||||
--- a/modules.d/10i18n/module-setup.sh
|
||||
+++ b/modules.d/10i18n/module-setup.sh
|
||||
@@ -6,9 +6,7 @@
|
||||
check() {
|
||||
[[ "$mount_needs" ]] && return 1
|
||||
|
||||
- for i in setfont loadkeys kbd_mode; do
|
||||
- type -P "$i" >/dev/null || return 1
|
||||
- done
|
||||
+ require_binaries setfont loadkeys kbd_mode || return 1
|
||||
|
||||
return 0
|
||||
}
|
||||
diff --git a/modules.d/40network/module-setup.sh b/modules.d/40network/module-setup.sh
|
||||
index 48afc5a..1df4174 100755
|
||||
--- a/modules.d/40network/module-setup.sh
|
||||
+++ b/modules.d/40network/module-setup.sh
|
||||
@@ -6,12 +6,7 @@
|
||||
check() {
|
||||
local _program
|
||||
|
||||
- for _program in ip arping dhclient ; do
|
||||
- if ! type -P $_program >/dev/null; then
|
||||
- derror "Could not find program \"$_program\" required by network."
|
||||
- return 1
|
||||
- fi
|
||||
- done
|
||||
+ require_binaries ip arping dhclient || return 1
|
||||
|
||||
return 255
|
||||
}
|
||||
diff --git a/modules.d/45url-lib/module-setup.sh b/modules.d/45url-lib/module-setup.sh
|
||||
index 1ed97ac..1b785c2 100755
|
||||
--- a/modules.d/45url-lib/module-setup.sh
|
||||
+++ b/modules.d/45url-lib/module-setup.sh
|
||||
@@ -3,7 +3,7 @@
|
||||
|
||||
# called by dracut
|
||||
check() {
|
||||
- command -v curl >/dev/null || return 1
|
||||
+ require_binaries curl || return 1
|
||||
return 255
|
||||
}
|
||||
|
||||
diff --git a/modules.d/50plymouth/module-setup.sh b/modules.d/50plymouth/module-setup.sh
|
||||
index 1360924..b818324 100755
|
||||
--- a/modules.d/50plymouth/module-setup.sh
|
||||
+++ b/modules.d/50plymouth/module-setup.sh
|
||||
@@ -5,7 +5,7 @@
|
||||
# called by dracut
|
||||
check() {
|
||||
[[ "$mount_needs" ]] && return 1
|
||||
- type -P plymouthd >/dev/null && type -P plymouth >/dev/null
|
||||
+ require_binaries plymouthd plymouth
|
||||
}
|
||||
|
||||
# called by dracut
|
||||
diff --git a/modules.d/90btrfs/module-setup.sh b/modules.d/90btrfs/module-setup.sh
|
||||
index 80a538f..406fd6d 100755
|
||||
--- a/modules.d/90btrfs/module-setup.sh
|
||||
+++ b/modules.d/90btrfs/module-setup.sh
|
||||
@@ -7,7 +7,7 @@ check() {
|
||||
local _rootdev
|
||||
# if we don't have btrfs installed on the host system,
|
||||
# no point in trying to support it in the initramfs.
|
||||
- type -P btrfs >/dev/null || return 1
|
||||
+ require_binaries btrfs || return 1
|
||||
|
||||
[[ $hostonly ]] || [[ $mount_needs ]] && {
|
||||
for fs in ${host_fs_types[@]}; do
|
||||
diff --git a/modules.d/90crypt/module-setup.sh b/modules.d/90crypt/module-setup.sh
|
||||
index 7d18e33..21d49c4 100755
|
||||
--- a/modules.d/90crypt/module-setup.sh
|
||||
+++ b/modules.d/90crypt/module-setup.sh
|
||||
@@ -6,7 +6,7 @@
|
||||
check() {
|
||||
local _rootdev
|
||||
# if cryptsetup is not installed, then we cannot support encrypted devices.
|
||||
- type -P cryptsetup >/dev/null || return 1
|
||||
+ require_binaries cryptsetup || return 1
|
||||
|
||||
[[ $hostonly ]] || [[ $mount_needs ]] && {
|
||||
for fs in "${host_fs_types[@]}"; do
|
||||
diff --git a/modules.d/90dm/module-setup.sh b/modules.d/90dm/module-setup.sh
|
||||
index bafad67..829c24b 100755
|
||||
--- a/modules.d/90dm/module-setup.sh
|
||||
+++ b/modules.d/90dm/module-setup.sh
|
||||
@@ -4,7 +4,7 @@
|
||||
|
||||
# called by dracut
|
||||
check() {
|
||||
- type -P dmsetup >/dev/null || return 1
|
||||
+ require_binaries dmsetup || return 1
|
||||
return 255
|
||||
}
|
||||
|
||||
diff --git a/modules.d/90dmraid/module-setup.sh b/modules.d/90dmraid/module-setup.sh
|
||||
index a9e27a6..d3888a4 100755
|
||||
--- a/modules.d/90dmraid/module-setup.sh
|
||||
+++ b/modules.d/90dmraid/module-setup.sh
|
||||
@@ -7,7 +7,7 @@ check() {
|
||||
local _rootdev
|
||||
# if we don't have dmraid installed on the host system, no point
|
||||
# in trying to support it in the initramfs.
|
||||
- type -P dmraid >/dev/null || return 1
|
||||
+ require_binaries dmraid || return 1
|
||||
|
||||
[[ $hostonly ]] || [[ $mount_needs ]] && {
|
||||
for dev in "${!host_fs_types[@]}"; do
|
||||
diff --git a/modules.d/90lvm/module-setup.sh b/modules.d/90lvm/module-setup.sh
|
||||
index a64e5d6..357797f 100755
|
||||
--- a/modules.d/90lvm/module-setup.sh
|
||||
+++ b/modules.d/90lvm/module-setup.sh
|
||||
@@ -5,7 +5,7 @@
|
||||
# called by dracut
|
||||
check() {
|
||||
# No point trying to support lvm if the binaries are missing
|
||||
- type -P lvm >/dev/null || return 1
|
||||
+ require_binaries lvm || return 1
|
||||
|
||||
[[ $hostonly ]] || [[ $mount_needs ]] && {
|
||||
for fs in "${host_fs_types[@]}"; do
|
||||
diff --git a/modules.d/90mdraid/module-setup.sh b/modules.d/90mdraid/module-setup.sh
|
||||
index 61483f2..7d72098 100755
|
||||
--- a/modules.d/90mdraid/module-setup.sh
|
||||
+++ b/modules.d/90mdraid/module-setup.sh
|
||||
@@ -6,7 +6,7 @@
|
||||
check() {
|
||||
local _rootdev
|
||||
# No mdadm? No mdraid support.
|
||||
- type -P mdadm >/dev/null || return 1
|
||||
+ require_binaries mdadm || return 1
|
||||
|
||||
[[ $hostonly ]] || [[ $mount_needs ]] && {
|
||||
for dev in "${!host_fs_types[@]}"; do
|
||||
diff --git a/modules.d/90multipath/module-setup.sh b/modules.d/90multipath/module-setup.sh
|
||||
index 261a957..b60cc60 100755
|
||||
--- a/modules.d/90multipath/module-setup.sh
|
||||
+++ b/modules.d/90multipath/module-setup.sh
|
||||
@@ -6,7 +6,7 @@
|
||||
check() {
|
||||
local _rootdev
|
||||
# if there's no multipath binary, no go.
|
||||
- type -P multipath >/dev/null || return 1
|
||||
+ require_binaries multipath || return 1
|
||||
|
||||
is_mpath() {
|
||||
local _dev=$1
|
||||
diff --git a/modules.d/91crypt-gpg/module-setup.sh b/modules.d/91crypt-gpg/module-setup.sh
|
||||
index 90c7bc2..b2154f0 100755
|
||||
--- a/modules.d/91crypt-gpg/module-setup.sh
|
||||
+++ b/modules.d/91crypt-gpg/module-setup.sh
|
||||
@@ -5,7 +5,7 @@
|
||||
# GPG support is optional
|
||||
# called by dracut
|
||||
check() {
|
||||
- type -P gpg >/dev/null || return 1
|
||||
+ require_binaries gpg || return 1
|
||||
|
||||
return 255
|
||||
}
|
||||
diff --git a/modules.d/91crypt-loop/module-setup.sh b/modules.d/91crypt-loop/module-setup.sh
|
||||
index 00052d3..93ae92e 100644
|
||||
--- a/modules.d/91crypt-loop/module-setup.sh
|
||||
+++ b/modules.d/91crypt-loop/module-setup.sh
|
||||
@@ -1,23 +1,27 @@
|
||||
+#!/bin/bash
|
||||
+# -*- mode: shell-script; indent-tabs-mode: nil; sh-basic-offset: 4; -*-
|
||||
+# ex: ts=8 sw=4 sts=4 et filetype=sh
|
||||
+
|
||||
# called by dracut
|
||||
check() {
|
||||
- type -P losetup >/dev/null || return 1
|
||||
-
|
||||
- return 255
|
||||
+ require_binaries losetup || return 1
|
||||
+
|
||||
+ return 255
|
||||
}
|
||||
|
||||
# called by dracut
|
||||
depends() {
|
||||
- echo crypt
|
||||
+ echo crypt
|
||||
}
|
||||
|
||||
# called by dracut
|
||||
installkernel() {
|
||||
- instmods loop
|
||||
+ instmods loop
|
||||
}
|
||||
|
||||
# called by dracut
|
||||
install() {
|
||||
- inst_multiple losetup
|
||||
- inst "$moddir/crypt-loop-lib.sh" "/lib/dracut-crypt-loop-lib.sh"
|
||||
- dracut_need_initqueue
|
||||
+ inst_multiple losetup
|
||||
+ inst "$moddir/crypt-loop-lib.sh" "/lib/dracut-crypt-loop-lib.sh"
|
||||
+ dracut_need_initqueue
|
||||
}
|
||||
diff --git a/modules.d/95cifs/module-setup.sh b/modules.d/95cifs/module-setup.sh
|
||||
index 546d2ff..8f5a3bf 100755
|
||||
--- a/modules.d/95cifs/module-setup.sh
|
||||
+++ b/modules.d/95cifs/module-setup.sh
|
||||
@@ -5,7 +5,7 @@
|
||||
# called by dracut
|
||||
check() {
|
||||
# If our prerequisites are not met, fail anyways.
|
||||
- type -P mount.cifs >/dev/null || return 1
|
||||
+ require_binaries mount.cifs || return 1
|
||||
|
||||
[[ $hostonly ]] || [[ $mount_needs ]] && {
|
||||
for fs in ${host_fs_types[@]}; do
|
||||
diff --git a/modules.d/95dasd/module-setup.sh b/modules.d/95dasd/module-setup.sh
|
||||
index 9c93d40..da0f3c0 100755
|
||||
--- a/modules.d/95dasd/module-setup.sh
|
||||
+++ b/modules.d/95dasd/module-setup.sh
|
||||
@@ -5,8 +5,8 @@
|
||||
# called by dracut
|
||||
check() {
|
||||
local _arch=$(uname -m)
|
||||
- [ -x /sbin/normalize_dasd_arg ] || return 1
|
||||
[ "$_arch" = "s390" -o "$_arch" = "s390x" ] || return 1
|
||||
+ require_binaries normalize_dasd_arg || return 1
|
||||
return 0
|
||||
}
|
||||
|
||||
diff --git a/modules.d/95dasd_mod/module-setup.sh b/modules.d/95dasd_mod/module-setup.sh
|
||||
index 8fde525..bee4998 100755
|
||||
--- a/modules.d/95dasd_mod/module-setup.sh
|
||||
+++ b/modules.d/95dasd_mod/module-setup.sh
|
||||
@@ -6,6 +6,7 @@
|
||||
check() {
|
||||
local _arch=$(uname -m)
|
||||
[ "$_arch" = "s390" -o "$_arch" = "s390x" ] || return 1
|
||||
+ require_binaries grep sed seq
|
||||
|
||||
return 0
|
||||
}
|
||||
diff --git a/modules.d/95dasd_rules/module-setup.sh b/modules.d/95dasd_rules/module-setup.sh
|
||||
index d313171..51c315d 100755
|
||||
--- a/modules.d/95dasd_rules/module-setup.sh
|
||||
+++ b/modules.d/95dasd_rules/module-setup.sh
|
||||
@@ -5,8 +5,8 @@
|
||||
# called by dracut
|
||||
check() {
|
||||
local _arch=$(uname -m)
|
||||
- [ -x /sbin/dasd_configure ] || return 1
|
||||
[ "$_arch" = "s390" -o "$_arch" = "s390x" ] || return 1
|
||||
+ require_binaries dasd_configure /usr/lib/udev/collect || return 1
|
||||
return 0
|
||||
}
|
||||
|
||||
diff --git a/modules.d/95fcoe-uefi/module-setup.sh b/modules.d/95fcoe-uefi/module-setup.sh
|
||||
index c91f775..0fb06e2 100755
|
||||
--- a/modules.d/95fcoe-uefi/module-setup.sh
|
||||
+++ b/modules.d/95fcoe-uefi/module-setup.sh
|
||||
@@ -4,9 +4,7 @@
|
||||
|
||||
# called by dracut
|
||||
check() {
|
||||
- for i in dcbtool fipvlan lldpad ip readlink; do
|
||||
- type -P $i >/dev/null || return 1
|
||||
- done
|
||||
+ require_binaries dcbtool fipvlan lldpad ip readlink || return 1
|
||||
return 0
|
||||
}
|
||||
|
||||
diff --git a/modules.d/95fcoe/module-setup.sh b/modules.d/95fcoe/module-setup.sh
|
||||
index 539c464..c502ba0 100755
|
||||
--- a/modules.d/95fcoe/module-setup.sh
|
||||
+++ b/modules.d/95fcoe/module-setup.sh
|
||||
@@ -4,10 +4,7 @@
|
||||
|
||||
# called by dracut
|
||||
check() {
|
||||
- for i in dcbtool fipvlan lldpad ip readlink; do
|
||||
- type -P $i >/dev/null || return 1
|
||||
- done
|
||||
-
|
||||
+ require_binaries dcbtool fipvlan lldpad ip readlink || return 1
|
||||
return 0
|
||||
}
|
||||
|
||||
diff --git a/modules.d/95iscsi/module-setup.sh b/modules.d/95iscsi/module-setup.sh
|
||||
index 8379f4b..1b0f292 100755
|
||||
--- a/modules.d/95iscsi/module-setup.sh
|
||||
+++ b/modules.d/95iscsi/module-setup.sh
|
||||
@@ -6,7 +6,7 @@
|
||||
check() {
|
||||
local _rootdev
|
||||
# If our prerequisites are not met, fail anyways.
|
||||
- type -P iscsistart hostname iscsi-iname >/dev/null || return 1
|
||||
+ require_binaries iscsistart hostname iscsi-iname || return 1
|
||||
|
||||
# If hostonly was requested, fail the check if we are not actually
|
||||
# booting from root.
|
||||
diff --git a/modules.d/95nbd/module-setup.sh b/modules.d/95nbd/module-setup.sh
|
||||
index 37ace21..e62f290 100755
|
||||
--- a/modules.d/95nbd/module-setup.sh
|
||||
+++ b/modules.d/95nbd/module-setup.sh
|
||||
@@ -6,7 +6,7 @@
|
||||
check() {
|
||||
local _rootdev
|
||||
# If our prerequisites are not met, fail.
|
||||
- type -P nbd-client >/dev/null || return 1
|
||||
+ require_binaries nbd-client || return 1
|
||||
|
||||
# if an nbd device is not somewhere in the chain of devices root is
|
||||
# mounted on, fail the hostonly check.
|
||||
diff --git a/modules.d/95nfs/module-setup.sh b/modules.d/95nfs/module-setup.sh
|
||||
index 345810a..dabf3b0 100755
|
||||
--- a/modules.d/95nfs/module-setup.sh
|
||||
+++ b/modules.d/95nfs/module-setup.sh
|
||||
@@ -5,8 +5,8 @@
|
||||
# called by dracut
|
||||
check() {
|
||||
# If our prerequisites are not met, fail anyways.
|
||||
- type -P rpcbind >/dev/null || type -P portmap >/dev/null || return 1
|
||||
- type -P rpc.statd mount.nfs mount.nfs4 umount >/dev/null || return 1
|
||||
+ require_any_binary rpcbind portmap || return 1
|
||||
+ require_binaries rpc.statd mount.nfs mount.nfs4 umount || return 1
|
||||
|
||||
[[ $hostonly ]] || [[ $mount_needs ]] && {
|
||||
for fs in ${host_fs_types[@]}; do
|
||||
diff --git a/modules.d/95ssh-client/module-setup.sh b/modules.d/95ssh-client/module-setup.sh
|
||||
index 1f2b733..2e3c505 100755
|
||||
--- a/modules.d/95ssh-client/module-setup.sh
|
||||
+++ b/modules.d/95ssh-client/module-setup.sh
|
||||
@@ -6,11 +6,11 @@
|
||||
|
||||
# called by dracut
|
||||
check() {
|
||||
- # If our prerequisites are not met, fail.
|
||||
- type -P ssh >/dev/null || return 1
|
||||
- type -P scp >/dev/null || return 1
|
||||
[[ $mount_needs ]] && return 1
|
||||
|
||||
+ # If our prerequisites are not met, fail.
|
||||
+ require_binaries ssh scp || return 1
|
||||
+
|
||||
if [[ $sshkey ]]; then
|
||||
[ ! -f $sshkey ] && {
|
||||
derror "ssh key: $sshkey is not found!"
|
||||
diff --git a/modules.d/95udev-rules/module-setup.sh b/modules.d/95udev-rules/module-setup.sh
|
||||
index ebc4447..584d5c8 100755
|
||||
--- a/modules.d/95udev-rules/module-setup.sh
|
||||
+++ b/modules.d/95udev-rules/module-setup.sh
|
||||
@@ -6,7 +6,7 @@
|
||||
install() {
|
||||
local _i
|
||||
|
||||
- # Fixme: would be nice if we didn't have to know which rules to grab....
|
||||
+ # Fixme: would be nice if we didn't have to guess, which rules to grab....
|
||||
# ultimately, /lib/initramfs/rules.d or somesuch which includes links/copies
|
||||
# of the rules we want so that we just copy those in would be best
|
||||
inst_multiple udevadm cat uname blkid \
|
||||
diff --git a/modules.d/95zfcp/module-setup.sh b/modules.d/95zfcp/module-setup.sh
|
||||
index dfbeed5..b96ccd2 100755
|
||||
--- a/modules.d/95zfcp/module-setup.sh
|
||||
+++ b/modules.d/95zfcp/module-setup.sh
|
||||
@@ -5,9 +5,10 @@
|
||||
# called by dracut
|
||||
check() {
|
||||
arch=$(uname -m)
|
||||
- [ -x /sbin/zfcp_cio_free ] || return 1
|
||||
[ "$arch" = "s390" -o "$arch" = "s390x" ] || return 1
|
||||
|
||||
+ require_binaries zfcp_cio_free grep sed seq || return 1
|
||||
+
|
||||
return 0
|
||||
}
|
||||
|
||||
diff --git a/modules.d/95zfcp_rules/module-setup.sh b/modules.d/95zfcp_rules/module-setup.sh
|
||||
index 9a1ab20..d9879cb 100755
|
||||
--- a/modules.d/95zfcp_rules/module-setup.sh
|
||||
+++ b/modules.d/95zfcp_rules/module-setup.sh
|
||||
@@ -5,8 +5,8 @@
|
||||
# called by dracut
|
||||
check() {
|
||||
local _arch=$(uname -m)
|
||||
- [ -x /sbin/zfcp_disk_configure ] || return 1
|
||||
[ "$_arch" = "s390" -o "$_arch" = "s390x" ] || return 1
|
||||
+ require_binaries zfcp_disk_configure /usr/lib/udev/collect || return 1
|
||||
return 0
|
||||
}
|
||||
|
||||
diff --git a/modules.d/95znet/module-setup.sh b/modules.d/95znet/module-setup.sh
|
||||
index 5012b77..346f893 100755
|
||||
--- a/modules.d/95znet/module-setup.sh
|
||||
+++ b/modules.d/95znet/module-setup.sh
|
||||
@@ -5,9 +5,10 @@
|
||||
# called by dracut
|
||||
check() {
|
||||
arch=$(uname -m)
|
||||
- [ -z /sbin/znet_cio_free ] || return 1
|
||||
[ "$arch" = "s390" -o "$arch" = "s390x" ] || return 1
|
||||
|
||||
+ require_binaries znet_cio_free grep sed seq readlink || return 1
|
||||
+
|
||||
return 0
|
||||
}
|
||||
|
||||
diff --git a/modules.d/97biosdevname/module-setup.sh b/modules.d/97biosdevname/module-setup.sh
|
||||
index b51c472..e285a7f 100755
|
||||
--- a/modules.d/97biosdevname/module-setup.sh
|
||||
+++ b/modules.d/97biosdevname/module-setup.sh
|
||||
@@ -5,7 +5,7 @@
|
||||
# called by dracut
|
||||
check() {
|
||||
[[ "$mount_needs" ]] && return 1
|
||||
- type -P biosdevname >/dev/null || return 1
|
||||
+ require_binaries biosdevname || return 1
|
||||
return 0
|
||||
}
|
||||
|
||||
diff --git a/modules.d/97masterkey/module-setup.sh b/modules.d/97masterkey/module-setup.sh
|
||||
index e6e3690..82a6515 100755
|
||||
--- a/modules.d/97masterkey/module-setup.sh
|
||||
+++ b/modules.d/97masterkey/module-setup.sh
|
||||
@@ -5,7 +5,7 @@
|
||||
# called by dracut
|
||||
check() {
|
||||
[[ $hostonly ]] && {
|
||||
- [ -x "/bin/keyctl" ] || return 1
|
||||
+ require_binaries keyctl uname || return 1
|
||||
}
|
||||
|
||||
return 255
|
||||
diff --git a/modules.d/98systemd/module-setup.sh b/modules.d/98systemd/module-setup.sh
|
||||
index 036f1c1..badce3c 100755
|
||||
--- a/modules.d/98systemd/module-setup.sh
|
||||
+++ b/modules.d/98systemd/module-setup.sh
|
||||
@@ -5,7 +5,7 @@
|
||||
# called by dracut
|
||||
check() {
|
||||
[[ $mount_needs ]] && return 1
|
||||
- if [[ -x $systemdutildir/systemd ]]; then
|
||||
+ if require_binaries $systemdutildir/systemd; then
|
||||
SYSTEMD_VERSION=$($systemdutildir/systemd --version | { read a b a; echo $b; })
|
||||
(( $SYSTEMD_VERSION >= 198 )) && return 0
|
||||
return 255
|
||||
diff --git a/modules.d/99img-lib/module-setup.sh b/modules.d/99img-lib/module-setup.sh
|
||||
index 2c3c992..69346b2 100755
|
||||
--- a/modules.d/99img-lib/module-setup.sh
|
||||
+++ b/modules.d/99img-lib/module-setup.sh
|
||||
@@ -3,9 +3,7 @@
|
||||
|
||||
# called by dracut
|
||||
check() {
|
||||
- for cmd in tar gzip dd; do
|
||||
- command -v $cmd >/dev/null || return 1
|
||||
- done
|
||||
+ require_binaries tar gzip dd bash || return 1
|
||||
return 255
|
||||
}
|
||||
|
22
dracut.spec
22
dracut.spec
@ -10,8 +10,8 @@
|
||||
%endif
|
||||
|
||||
Name: dracut
|
||||
Version: 036
|
||||
Release: 16.git20140206%{?dist}
|
||||
Version: 037
|
||||
Release: 1%{?dist}
|
||||
|
||||
Summary: Initramfs generator using udev
|
||||
%if 0%{?fedora} || 0%{?rhel}
|
||||
@ -30,21 +30,6 @@ URL: https://dracut.wiki.kernel.org/
|
||||
# Source can be generated by
|
||||
# http://git.kernel.org/?p=boot/dracut/dracut.git;a=snapshot;h=%{version};sf=tgz
|
||||
Source0: http://www.kernel.org/pub/linux/utils/boot/dracut/dracut-%{version}.tar.xz
|
||||
Patch1: 0001-NEWS-update-for-version-036.patch
|
||||
Patch2: 0002-network-understand-ip-.-dns1-dns2.patch
|
||||
Patch3: 0003-dracut.sh-only-set-the-owner-of-files-to-0-0-if-gene.patch
|
||||
Patch4: 0004-dracut-functions.sh-also-search-in-the-updates-direc.patch
|
||||
Patch5: 0005-network-net-lib.sh-parse-ibft-nameserver-settings.patch
|
||||
Patch6: 0006-network-ifup.sh-handle-dns1-and-dns2-from-ip-setting.patch
|
||||
Patch7: 0007-base-rdsosreport.sh-add-dracut-version-to-rdsosrepor.patch
|
||||
Patch8: 0008-test-include-the-same-Makefile.testdir.patch
|
||||
Patch9: 0009-network-ifup-do-not-ifup-an-already-setup-network-in.patch
|
||||
Patch10: 0010-network-ifup-do-not-run-dhclient-twice-on-the-same-i.patch
|
||||
Patch11: 0011-nfs-nfsroot-symlink-dev-null-to-dev-nfs-as-a-marker-.patch
|
||||
Patch12: 0012-systemd-dracut-pre-pivot-run-for-dev-nfs-root-and-cl.patch
|
||||
Patch13: 0013-Do-not-reload-systemd-with-wait_for_dev.patch
|
||||
Patch14: 0014-systemd-add-sys-kernel-config.mount.patch
|
||||
Patch15: 0015-Factor-out-all-the-type-V-commands.patch
|
||||
|
||||
|
||||
BuildRequires: bash git
|
||||
@ -493,6 +478,9 @@ rm -rf -- $RPM_BUILD_ROOT
|
||||
%endif
|
||||
|
||||
%changelog
|
||||
* Wed Mar 19 2014 Harald Hoyer <harald@redhat.com> 037-1
|
||||
- version 037
|
||||
|
||||
* Thu Feb 06 2014 Harald Hoyer <harald@redhat.com> 036-16.git20140206
|
||||
- version 036
|
||||
- parse dns information on "ip=" command line arg
|
||||
|
Loading…
Reference in New Issue
Block a user