From 8ae9783215c2845b50dfb70b919df0753c2b0dd9 Mon Sep 17 00:00:00 2001 From: maximilian attems Date: Fri, 1 Sep 2006 16:18:29 +0200 Subject: - fix destination of the mdrun.conf for partial sarge upgrades - checkout if /sbin/lilo is really there - guard more dirs against creation - add /etc/kernel-img.conf to reportbug output --- debian/changelog | 20 ++++++++++++++++++++ debian/script | 6 ++++++ init | 6 +++--- mkinitramfs | 4 ++-- update-initramfs | 3 +++ 5 files changed, 34 insertions(+), 5 deletions(-) diff --git a/debian/changelog b/debian/changelog index bc635a3..b46db63 100644 --- a/debian/changelog +++ b/debian/changelog @@ -1,3 +1,23 @@ +initramfs-tools (0.78) unstable; urgency=medium + + * update-initramfs: Check in call_lilo() if /sbin/lilo is executable, + when /etc/lilo.conf exists (closes: 384967) - thus urgency medium. + + * init: Guard all dirs against creation. (closes: 385281) + + * debian/scripts: Add /etc/kernel-img.conf section, as update-initramfs + needs to act according to it. + + -- maximilian attems Thu, 31 Aug 2006 14:44:01 +0200 + +initramfs-tools (0.77b) unstable; urgency=high + + * mkinitramfs: Fix destination of mdrun.conf. Thanks for the report to + Scott Glenn . Urgency high as broken in testing + too and needed for partial mdadm upgrades. (closes: 385406) + + -- maximilian attems Thu, 31 Aug 2006 13:20:51 +0200 + initramfs-tools (0.77) unstable; urgency=medium * mkinitramfs, scripts/local-top/mdrun: Use mdrun.conf as config file. diff --git a/debian/script b/debian/script index b1b477d..a8e3dd9 100755 --- a/debian/script +++ b/debian/script @@ -13,3 +13,9 @@ echo echo "-- lsmod" lsmod echo + +if [ -r /etc/kernel-img.conf ]; then + echo "-- kernel-img.conf" + cat /etc/kernel-img.conf + echo +fi diff --git a/init b/init index a83dc39..0c336b3 100755 --- a/init +++ b/init @@ -6,9 +6,9 @@ echo "Loading, please wait..." [ -d /root ] || mkdir --mode=0700 /root [ -e /dev/console ] || mknod /dev/console c 5 1 [ -e /dev/null ] || mknod /dev/null c 1 3 -mkdir /sys -mkdir /proc -mkdir /tmp +[ -d /sys ] || mkdir /sys +[ -d /proc ] || mkdir /proc +[ -d /tmp ] || mkdir /tmp mkdir -p /var/lock mount -t sysfs none /sys mount -t proc none /proc diff --git a/mkinitramfs b/mkinitramfs index d088efa..c36e845 100755 --- a/mkinitramfs +++ b/mkinitramfs @@ -239,7 +239,7 @@ run_scripts "${CONFDIR}"/hooks if [ -x /sbin/mdadm ] && [ ! -f /usr/share/initramfs-tools/hooks/mdadm ]; then # use mkinitrd magic for Sarge backwards compat rootraiddev="$(df / | sed -rne 's,^(/dev/[^[:space:]]+).*,\1,p')" - echo "rootraiddev=${rootraiddev}" > /conf/mdrun.conf + echo "rootraiddev=${rootraiddev}" > ${DESTDIR}/conf/mdrun.conf mdadm=$(mdadm --detail "${rootraiddev}") echo "${mdadm}" | awk ' $1 == "Number" && $2 == "Major" { start = 1; next } @@ -248,7 +248,7 @@ if [ -x /sbin/mdadm ] && [ ! -f /usr/share/initramfs-tools/hooks/mdadm ]; then $2 == 0 && $3 == 0 { next } { devices = devices " " $NF } END { print "devices='\''" devices "'\''" }' \ - >> /conf/mdrun.conf + >> ${DESTDIR}/conf/mdrun.conf copy_exec /sbin/mdadm /sbin for x in md linear multipath raid0 raid1 raid456 raid5 raid6 raid10; do manual_add_modules ${x} diff --git a/update-initramfs b/update-initramfs index c1e42ab..5cd1e2e 100755 --- a/update-initramfs +++ b/update-initramfs @@ -85,6 +85,9 @@ generate_initramfs() # lilo call run_lilo() { + if [ ! -x /sbin/lilo ]; then + return 1 + fi lilo -t > /dev/null if [ $? -eq 0 ]; then lilo -- cgit v1.2.3