Compare commits
21 Commits
Author | SHA1 | Date | |
---|---|---|---|
![]() |
5d12f1a485 | ||
![]() |
7addf9d430 | ||
![]() |
6d0480426d | ||
![]() |
5a8b143888 | ||
![]() |
5bf0b329c9 | ||
![]() |
51123629d7 | ||
![]() |
0ad78ae8e7 | ||
![]() |
1c6e9e5c0a | ||
![]() |
0b610a002c | ||
![]() |
0f1361ee1c | ||
![]() |
b806825d2a | ||
![]() |
f905c1d7d6 | ||
![]() |
926b2c3337 | ||
![]() |
fc900b8be4 | ||
![]() |
88838bf238 | ||
![]() |
ed2de829e1 | ||
![]() |
ff34c9dcd4 | ||
![]() |
3d4641fd98 | ||
![]() |
860ace56f8 | ||
![]() |
ed6220fd25 | ||
![]() |
be9ca6c8a8 |
2
Makefile
2
Makefile
@@ -1,4 +1,4 @@
|
||||
VERSION=0.8
|
||||
VERSION=0.9
|
||||
GITVERSION=$(shell [ -d .git ] && git rev-list --abbrev-commit -n 1 HEAD |cut -b 1-8)
|
||||
|
||||
prefix = /usr
|
||||
|
10
NEWS
10
NEWS
@@ -1,3 +1,13 @@
|
||||
dracut-0.9
|
||||
==========
|
||||
- let plymouth attach to the terminal (nice text output now)
|
||||
- new kernel command line parameter "rdinfo" show dracut output, even when
|
||||
"quiet" is specified
|
||||
- rd_LUKS_UUID is now handled correctly
|
||||
- dracut-gencmdline: rd_LUKS_UUID and rd_MD_UUID is now correctly generated
|
||||
- now generates initrd-generic with around 15MB
|
||||
- smaller bugfixes
|
||||
|
||||
dracut-0.8
|
||||
==========
|
||||
- iSCSI with username and password
|
||||
|
2
dracut
2
dracut
@@ -238,7 +238,7 @@ if [ "$do_strip" = "yes" ] ; then
|
||||
done
|
||||
fi
|
||||
|
||||
( cd "$initdir"; find . |cpio -H newc -o |gzip -9 > "$outfile"; )
|
||||
( cd "$initdir"; find . |cpio -R 0:0 -H newc -o |gzip -9 > "$outfile"; )
|
||||
|
||||
[[ "$beverbose" = "yes" ]] && ls -lh "$outfile"
|
||||
|
||||
|
@@ -59,7 +59,7 @@ inst_simple() {
|
||||
[[ -f $target ]] && return 0
|
||||
mkdir -p "${target%/*}"
|
||||
dinfo "Installing $src"
|
||||
cp -fL "$src" "$target"
|
||||
cp -pfL "$src" "$target"
|
||||
}
|
||||
|
||||
# Same as above, but specialzed to handle dynamic libraries.
|
||||
|
@@ -643,6 +643,7 @@ emitcrypto()
|
||||
if [ -z "$luksuuid" ]; then
|
||||
luksuuid="$2"
|
||||
fi
|
||||
luksuuid=${luksuuid##UUID=}
|
||||
echo -n "rd_LUKS_UUID=$luksuuid "
|
||||
}
|
||||
|
||||
@@ -652,7 +653,9 @@ done
|
||||
|
||||
if [ -n "$raiddevices" ]; then
|
||||
for dev in $raiddevices; do
|
||||
echo -n "rd_MD_UUID=${dev} "
|
||||
uid=$(udevadm info --query=all --name=/dev/${dev}|grep MD_UUID)
|
||||
uid=$(IFS="=";set $uid;echo $2)
|
||||
echo -n "rd_MD_UUID=$uid "
|
||||
done
|
||||
fi
|
||||
|
||||
|
5
dracut.8
5
dracut.8
@@ -249,6 +249,9 @@ do not load kernel module <drivername>
|
||||
|
||||
.SH Debug
|
||||
.TP
|
||||
.B rdinfo
|
||||
print informational output though "quiet" is set
|
||||
.TP
|
||||
.B rdshell
|
||||
allow dropping to a shell, if root mounting fails
|
||||
.TP
|
||||
@@ -258,7 +261,7 @@ set -x for the dracut shell
|
||||
.B rdbreak
|
||||
drop to a shell at the end
|
||||
.TP
|
||||
.B rdbreak={pre-udev|pre-mount|mount|pre-pivot|commandline|initqueue}
|
||||
.B rdbreak={cmdline|pre-udev|pre-trigger|initqueue|pre-mount|mount|pre-pivot}
|
||||
drop to a shell on defined breakpoint
|
||||
.TP
|
||||
.B rdudevinfo
|
||||
|
10
dracut.spec
10
dracut.spec
@@ -12,7 +12,7 @@
|
||||
%endif
|
||||
|
||||
Name: dracut
|
||||
Version: 0.8
|
||||
Version: 0.9
|
||||
Release: 1%{?rdist}
|
||||
Summary: Initramfs generator using udev
|
||||
Group: System Environment/Base
|
||||
@@ -32,6 +32,7 @@ Requires: which
|
||||
Requires: mktemp >= 1.5-5
|
||||
Requires: mount
|
||||
Requires: bash
|
||||
Requires: dash
|
||||
Requires: /bin/sh
|
||||
Requires: fileutils, gzip, tar
|
||||
Requires: lvm2 >= 2.02.33-9, dhclient
|
||||
@@ -48,7 +49,7 @@ Requires: kbd
|
||||
%endif
|
||||
|
||||
%if ! 0%{?with_switch_root}
|
||||
Requires: /sbin/switch_root
|
||||
Requires: util-linux-ng >= 2.16
|
||||
BuildArch: noarch
|
||||
%endif
|
||||
|
||||
@@ -63,6 +64,7 @@ Requires: iscsi-initiator-utils
|
||||
Requires: nbd
|
||||
Requires: net-tools iproute
|
||||
Requires: plymouth-system-theme plymouth-theme-charge plymouth-theme-solar
|
||||
Requires: plymouth-theme-fade-in plymouth-theme-spinfinity
|
||||
|
||||
%description generic
|
||||
This package requires everything which is needed to build a generic
|
||||
@@ -143,6 +145,10 @@ rm -rf $RPM_BUILD_ROOT
|
||||
%dir /var/lib/dracut/overlay
|
||||
|
||||
%changelog
|
||||
* Fri Aug 14 2009 Harald Hoyer <harald@redhat.com> 0.9-1
|
||||
- version 0.9
|
||||
- see http://dracut.git.sourceforge.net/git/gitweb.cgi?p=dracut;a=blob_plain;f=NEWS
|
||||
|
||||
* Thu Aug 06 2009 Harald Hoyer <harald@redhat.com> 0.8-1
|
||||
- version 0.8
|
||||
- see http://dracut.git.sourceforge.net/git/gitweb.cgi?p=dracut;a=blob_plain;f=NEWS
|
||||
|
@@ -76,10 +76,13 @@ else
|
||||
for i in $(find /lib/kbd -type f -print); do
|
||||
dracut_install $i
|
||||
done
|
||||
# remove unnecessary files
|
||||
rm -f "$initdir/lib/kbd/consoletrans/utflist" 2>/dev/null
|
||||
find "$initdir/lib/kbd/" -name README\* -exec rm -f '{}' \;
|
||||
dracut_install gzip bzip2
|
||||
fi
|
||||
|
||||
dracut_install /lib/udev/console_*
|
||||
dracut_install /lib/udev/console_init
|
||||
dracut_install setfont loadkeys
|
||||
inst_rules 10-console.rules
|
||||
inst_hook cmdline 20 "$moddir/parse-i18n.sh"
|
||||
|
3
modules.d/10rpmversion/check
Executable file
3
modules.d/10rpmversion/check
Executable file
@@ -0,0 +1,3 @@
|
||||
#!/bin/sh
|
||||
[ -f /etc/redhat-release ]
|
||||
|
8
modules.d/10rpmversion/install
Executable file
8
modules.d/10rpmversion/install
Executable file
@@ -0,0 +1,8 @@
|
||||
|
||||
dracut_rpm_version=$(rpm -qf --qf '%{name}-%{version}-%{release}' $(which $0))
|
||||
if [ $? -eq 0 ]; then
|
||||
echo $dracut_rpm_version > $initdir/$dracut_rpm_version
|
||||
fi
|
||||
|
||||
inst_hook cmdline 01 "$moddir/version.sh"
|
||||
|
6
modules.d/10rpmversion/version.sh
Normal file
6
modules.d/10rpmversion/version.sh
Normal file
@@ -0,0 +1,6 @@
|
||||
for i in dracut-*; do
|
||||
if [ -f $i ]; then
|
||||
vinfo < $i
|
||||
fi
|
||||
done
|
||||
unset i
|
@@ -1,7 +1,8 @@
|
||||
#!/bin/bash
|
||||
# Include wired net drivers, excluding wireless
|
||||
for modname in $(find "$srcmods/kernel/drivers" -name '*.ko'); do
|
||||
if nm -uPA $modname | egrep -q 'eth_type_trans|register_virtio_device'; then
|
||||
if nm -uPA $modname | egrep -q 'eth_type_trans|register_virtio_device' \
|
||||
&& ! nm -uPA $modname | egrep -q 'iw_handler_get_spy'; then
|
||||
if echo "$modname" | egrep -q '/wireless/|/isdn/|/uwb/'; then
|
||||
continue
|
||||
else
|
||||
|
@@ -15,8 +15,9 @@ ask=1
|
||||
|
||||
if [ -n "$LUKS" ]; then
|
||||
ask=0
|
||||
luuid=${2##luks-}
|
||||
for luks in $LUKS; do
|
||||
if [ "${2##$luks}" != "$2" ]; then
|
||||
if [ "${luuid##$luks}" != "$2" ]; then
|
||||
ask=1
|
||||
fi
|
||||
done
|
||||
|
@@ -13,6 +13,6 @@ udevadm settle --timeout=30 2>&1 | vinfo
|
||||
[ -c /dev/hvc0 ] || mknod /dev/hvc0 c 229 0
|
||||
|
||||
info "Starting plymouth daemon"
|
||||
[ -x /bin/plymouthd ] && /bin/plymouthd
|
||||
[ -x /bin/plymouthd ] && /bin/plymouthd --attach-to-session
|
||||
/bin/plymouth --show-splash 2>&1 | vinfo
|
||||
|
||||
|
@@ -15,8 +15,9 @@ ask=1
|
||||
|
||||
if [ -n "$LUKS" ]; then
|
||||
ask=0
|
||||
luuid=${2##luks-}
|
||||
for luks in $LUKS; do
|
||||
if [ "${2##$luks}" != "$2" ]; then
|
||||
if [ "${luuid##$luks}" != "$2" ]; then
|
||||
ask=1
|
||||
fi
|
||||
done
|
||||
@@ -33,4 +34,4 @@ fi
|
||||
# mark device as asked
|
||||
>> /tmp/cryptroot-asked-$2
|
||||
|
||||
exit 0
|
||||
exit 0
|
||||
|
@@ -1,5 +0,0 @@
|
||||
#!/bin/sh
|
||||
|
||||
[ -x /lib/udev/devkit-disks-dm-export ] || exit 1
|
||||
|
||||
exit 0
|
@@ -1,8 +0,0 @@
|
||||
#!/bin/bash
|
||||
# FIXME: would be nice if we didn't have to know 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
|
||||
dracut_install /lib/udev/devkit-disks-dm-export /lib/udev/devkit-disks-part-id
|
||||
|
||||
inst_rules 95-devkit-disks.rules
|
||||
|
@@ -3,7 +3,14 @@ inst dmsetup
|
||||
inst blkid
|
||||
inst dd
|
||||
inst losetup
|
||||
inst eject
|
||||
|
||||
# eject might be a symlink to consolehelper
|
||||
if [ -L /usr/bin/eject ]; then
|
||||
dracut_install /usr/sbin/eject
|
||||
else
|
||||
inst eject
|
||||
fi
|
||||
|
||||
inst blockdev
|
||||
which checkisomd5 >/dev/null 2>&1 && inst checkisomd5
|
||||
inst_hook cmdline 30 "$moddir/parse-dmsquash-live.sh"
|
||||
|
@@ -13,7 +13,8 @@ else
|
||||
LIBDIR="/lib"
|
||||
fi
|
||||
|
||||
dracut_install $(ls {/usr,}$LIBDIR/libnfsidmap*.so* 2>/dev/null )
|
||||
dracut_install $(ls {/usr,}$LIBDIR/libnfsidmap_nsswitch.so* 2>/dev/null )
|
||||
#dracut_install $(ls {/usr,}$LIBDIR/libnfsidmap*.so* 2>/dev/null )
|
||||
|
||||
nsslibs=$(for j in $(for i in \
|
||||
$(egrep -v '^#.*' /etc/nsswitch.conf|cut -f2 -d :\
|
||||
|
@@ -2,7 +2,7 @@
|
||||
# FIXME: would be nice if we didn't have to know 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
|
||||
dracut_install udevd udevadm /lib*/udev/*_id /etc/udev/udev.conf /etc/group
|
||||
dracut_install udevd udevadm /etc/udev/udev.conf /etc/group
|
||||
dracut_install basename
|
||||
inst_rules 50-udev-default.rules 60-persistent-storage.rules \
|
||||
61-persistent-storage-edd.rules 80-drivers.rules 95-udev-late.rules
|
||||
@@ -21,6 +21,21 @@ if [ ! -x /lib/udev/vol_id ]; then
|
||||
dracut_install blkid
|
||||
fi
|
||||
|
||||
for i in \
|
||||
ata_id \
|
||||
cdrom_id \
|
||||
create_floppy_devices \
|
||||
edd_id \
|
||||
firmware.sh \
|
||||
fw_unit_symlinks.sh \
|
||||
hid2hci \
|
||||
path_id \
|
||||
scsi_id \
|
||||
usb_id \
|
||||
; do
|
||||
[ -x /lib/udev/$i ] && dracut_install /lib/udev/$i
|
||||
done
|
||||
|
||||
|
||||
if ldd $(find_binary udevd) |grep -q /lib64/libc; then
|
||||
dracut_install /lib64/libnss_files*
|
||||
|
@@ -65,6 +65,7 @@ info() {
|
||||
if [ -z "$DRACUT_QUIET" ]; then
|
||||
DRACUT_QUIET="no"
|
||||
getarg quiet && DRACUT_QUIET="yes"
|
||||
getarg rdinfo && DRACUT_QUIET="no"
|
||||
fi
|
||||
echo "<6>dracut: $@" > /dev/kmsg
|
||||
[ "$DRACUT_QUIET" != "yes" ] && \
|
||||
|
@@ -5,11 +5,11 @@ for x in 64-lvm.rules 70-mdadm.rules 99-mount-rules; do
|
||||
done
|
||||
udevadm control --reload-rules
|
||||
# save a partition at the beginning for future flagging purposes
|
||||
sfdisk -C 640 -H 2 -S 32 -L /dev/sda <<EOF
|
||||
,1
|
||||
,213
|
||||
,213
|
||||
,213
|
||||
sfdisk -C 1280 -H 2 -S 32 -L /dev/sda <<EOF
|
||||
,16
|
||||
,400
|
||||
,400
|
||||
,400
|
||||
EOF
|
||||
mdadm --create /dev/md0 --run --auto=yes --level=5 --raid-devices=3 /dev/sda2 /dev/sda3 /dev/sda4
|
||||
# wait for the array to finish initailizing, otherwise this sometimes fails
|
||||
|
@@ -16,7 +16,7 @@ test_run() {
|
||||
|
||||
test_setup() {
|
||||
# Create the blank file to use as a root filesystem
|
||||
dd if=/dev/zero of=root.ext2 bs=1M count=20
|
||||
dd if=/dev/zero of=root.ext2 bs=1M count=40
|
||||
|
||||
kernel=$KVERSION
|
||||
# Create what will eventually be our root filesystem onto an overlay
|
||||
|
Reference in New Issue
Block a user