diff options
-rw-r--r-- | debian/changelog | 60 | ||||
-rw-r--r-- | debian/control | 4 | ||||
-rwxr-xr-x | debian/script | 2 | ||||
-rw-r--r-- | hook-functions | 28 | ||||
-rwxr-xr-x | init | 13 | ||||
-rw-r--r-- | initramfs.conf.5 | 6 | ||||
-rw-r--r-- | mkinitramfs.8 | 7 | ||||
-rw-r--r-- | scripts/functions | 8 | ||||
-rwxr-xr-x | scripts/init-premount/thermal | 26 | ||||
-rwxr-xr-x | scripts/init-top/framebuffer | 7 | ||||
-rw-r--r-- | scripts/local | 8 | ||||
-rwxr-xr-x | scripts/local-top/lvm | 6 | ||||
-rwxr-xr-x | scripts/local-top/mdrun | 46 | ||||
-rwxr-xr-x | scripts/local-top/udev_helper | 2 | ||||
-rw-r--r-- | scripts/nfs | 4 | ||||
-rwxr-xr-x | update-initramfs | 24 | ||||
-rw-r--r-- | update-initramfs.conf.5 | 4 |
17 files changed, 130 insertions, 125 deletions
diff --git a/debian/changelog b/debian/changelog index c292a82..07d28d0 100644 --- a/debian/changelog +++ b/debian/changelog @@ -1,3 +1,59 @@ +initramfs-tools (0.86) experimental; urgency=low + + * update-initramfs: Bound the mode and version variable. (closes: 403905) + Thanks "Nikita V. Youshchenko" <yoush@debian.org> for report. + + * init: Set once the MODPROBE_OPTIONS environment variable and export it. + Don't forget to set -b to have the modprobe.d blacklists respected. + Thus remove everywhere the -q modprobe switch. + Thanks Ben Collins <bcollins@ubuntu.com> for the suggestion. + + * small trailing whitespace cleanup, display full path of kernel-img.conf + in bug script. + + * debian/control: change maintainer entry to new DD mail. :) + Add busybox-initramfs as Ubuntu busybox alternative to depends. + Dropp the sarge busybox-cvs-static entry. + + * scripts/local-top/mdrun: Drop, existed for partial upgrades from sarge. + + * scripts/local: Improve panic message and printed order. (closes: 414640) + Thanks Vincent.McIntyre@csiro.au for patch. + + * scripts/functions: Check if panic is set befor using it. (closes: 406107) + Thanks martin f krafft <madduck@debian.org> for report. + + * hook-functions: Copy all kernel/drivers/{block,ide,scsi} subdir modules + instead of hardcoding the list of "supported" drivers. As consequence + the initramfs might be larger, but none of those should be missed. + As bonus syncs with Ubuntu. + + * init: Mount /sys and /proc nodev, noexec, nosuid - Ubuntu sync. + + -- maximilian attems <maks@debian.org> Sat, 17 Mar 2007 21:39:13 +0100 + +initramfs-tools (0.85f) unstable; urgency=high + + Release "Au lieu d'aller voter Casse leur la margoulette" + + * update-initramfs: Grub _doesn't_ clear LILO string in mbr, but the inverse + is done. Fix mbr_check() to first check for GRUB. Fixes accidental lilo + call in the case that Grub is the used bootloader. (closes: 409820) + Thanks Michael Prokop <mika@grml.org> for bringing up the case. + + * initramfs.conf.5, mkinitramfs.5: Fix typos. Document version. + (closes: 405157, 405190, 405194) + + * update-initramfs: Be more screamy about lilo error, people seem to + overlook recent lilo failures. + + * scripts/init-top/framebuffer: Remove unused variables. + + * init: Export ROOTDELAY to let udev boot script handle eventual rootdelay. + downgrades 401916 + + -- maximilian attems <maks@sternwelten.at> Wed, 7 Mar 2007 23:34:17 +0100 + initramfs-tools (0.85e) unstable; urgency=high Release "Qu'ils soient rouges, bleus ou blancs Il faudrait mieux les pendre" @@ -74,7 +130,7 @@ initramfs-tools (0.85b) unstable; urgency=medium urgency medium. * scripts/init-top/framebuffer: Fix regression of /dev/fb0 creation, - modprobe fb before creating device. Thanks to Otavio Salvador + modprobe fb before creating device. Thanks to Otavio Salvador <otavio@debian.org> for patch. -- maximilian attems <maks@sternwelten.at> Tue, 14 Nov 2006 08:06:40 +0100 @@ -93,7 +149,7 @@ initramfs-tools (0.85) unstable; urgency=high having a /boot string. (closes: 393906) Thanks for the patch Olli Helenius <olli@starnet.fi> - * init-top/framebuffer: Fix duplicate fbno0 device creation. Merge the + * init-top/framebuffer: Fix duplicate fbno0 device creation. Merge the 0.69ubuntu10 solution. Thanks Benjamin Leipold <rabbit171@web.de> for the report. (closes: 393890) diff --git a/debian/control b/debian/control index dd4c3b3..9294ee7 100644 --- a/debian/control +++ b/debian/control @@ -1,14 +1,14 @@ Source: initramfs-tools Section: utils Priority: optional -Uploaders: Jeff Bailey <jbailey@ubuntu.com>, maximilian attems <maks@sternwelten.at> +Uploaders: Jeff Bailey <jbailey@ubuntu.com>, maximilian attems <maks@debian.org> Maintainer: Debian kernel team <debian-kernel@lists.debian.org> Build-Depends: debhelper (>= 4.1.0), cdbs Standards-Version: 3.7.2.0 Package: initramfs-tools Architecture: all -Depends: klibc-utils (>= 1.4.19-2), busybox (>= 1:1.01-3) | busybox-cvs-static (>= 20040623-1), cpio, module-init-tools, udev (>= 0.086-1) +Depends: klibc-utils (>= 1.4.19-2), busybox (>= 1:1.01-3) | busybox-initramfs, cpio, module-init-tools, udev (>= 0.086-1) Provides: linux-initramfs-tool Description: tools for generating an initramfs This package contains tools to create and boot an initramfs for packaged 2.6 diff --git a/debian/script b/debian/script index a8e3dd9..7cfac12 100755 --- a/debian/script +++ b/debian/script @@ -15,7 +15,7 @@ lsmod echo if [ -r /etc/kernel-img.conf ]; then - echo "-- kernel-img.conf" + echo "-- /etc/kernel-img.conf" cat /etc/kernel-img.conf echo fi diff --git a/hook-functions b/hook-functions index fe5d31e..f506b49 100644 --- a/hook-functions +++ b/hook-functions @@ -172,35 +172,20 @@ auto_add_modules() done ;; ide) - for x in ide-cd ide-disk ide-generic aec62xx alim15x3 \ - amd74xx atiixp atuuxo cmd64x cs5520 cs5530 cy82c693 \ - generic hpt34x hpt366 it821x jmicron ns87415 opti621 \ - pdc202xx_new pdc202xx_old piix rz1000 sc1200 serverworks \ - siimage sis5513 slc82c105 slc90e66 triflex trm290 \ - via82cxxx; do - manual_add_modules "${x}" - done + copy_modules_dir kernel/drivers/ide ;; scsi) - for x in 3w-9xxx 3w-xxxx a100u2x aacraid advansys ahci \ - aic79xx aic7xxx aic94xx arcmsr ata_piix atari_scsi \ - atp870u BusLogic cciss ch cpqarray DAC960 dc395x \ - dmx3191d dpt_i2o eata fdomain gdth hptiop ibmvscsic \ - initio ipr ips isp1020 lasi700 lpfc max_scsi mac53c94 \ - megaraid megaraid_mbox megaraid_mm megaraid_sas \ - mesh mptfc mptscsih mptsas mptspi nsp32 \ - osst qla1280 qla2100 qla2200 qla2300 qla2322 qla2xxx \ - qla4xxx qla6312 qlogicfas408 qlogicfc sata_mv sata_nv \ - sata_promise sata_qstor sata_sil sata_sil24 sata_sis sata_svw \ - sata_sx4 sata_uli sata_via sata_vsc scsi_mod \ - scsi_transport_fc scsi_transport_iscsi scsi_transport_spi \ - sd_mod stex sym53c8xx tmscsim zalon zfcp; do + copy_modules_dir kernel/drivers/scsi + for x in mptfc mptsas mptscsih mptspi; do manual_add_modules "${x}" done ;; ata) copy_modules_dir kernel/drivers/ata ;; + block) + copy_modules_dir kernel/drivers/block + ;; ieee1394) for x in ohci1394 sbp2; do manual_add_modules "${x}" @@ -221,6 +206,7 @@ auto_add_modules() auto_add_modules net auto_add_modules ide auto_add_modules scsi + auto_add_modules block auto_add_modules ata auto_add_modules i2o auto_add_modules dasd @@ -8,8 +8,8 @@ echo "Loading, please wait..." [ -d /proc ] || mkdir /proc [ -d /tmp ] || mkdir /tmp mkdir -p /var/lock -mount -t sysfs none /sys -mount -t proc none /proc +mount -t sysfs none /sys -o nodev, noexec, nosuid +mount -t proc none /proc -o nodev, noexec, nosuid # Note that this only becomes /dev on the real filesystem if udev's scripts # are used; which they will be, but it's worth pointing out @@ -37,7 +37,10 @@ for i in conf/conf.d/*; do done . /scripts/functions -# Parse command line options +# Set modprobe env +export MODPROBE_OPTIONS="-qb" + +# Export relevant variables export break= export init=/sbin/init export quiet=n @@ -45,8 +48,10 @@ export readonly=y export rootmnt=/root export debug= export cryptopts=${CRYPTOPTS} -export panic +export ROOTDELAY= +export panic= +# Parse command line options for x in $(cat /proc/cmdline); do case $x in init=*) diff --git a/initramfs.conf.5 b/initramfs.conf.5 index ca47a02..e685298 100644 --- a/initramfs.conf.5 +++ b/initramfs.conf.5 @@ -1,4 +1,4 @@ -.TH INITRAMFS.CONF 5 "$Date: 2006/10/12 $" "" "initramfs.conf manual" +.TH INITRAMFS.CONF 5 "$Date: 2007/01/01 $" "" "initramfs.conf manual" .SH NAME initramfs.conf \- configuration file for mkinitramfs @@ -37,14 +37,14 @@ The default setting is \fImost\fP. Include busybox utilities for the boot scripts. If set to 'n' .B mkinitramfs -will build an initramfs whithout busybox. +will build an initramfs without busybox. Beware that many boot scripts need busybox utilities. .SH NFS VARIABLES .TP \fB BOOT Allows to use an nfs drive as the root of the drive. -The default is to boot of an \fIlocal\fP media (harddrive, USB stick). +The default is to boot from \fIlocal\fP media (harddrive, USB stick). Set to \fInfs\fP for an NFS root share. .TP diff --git a/mkinitramfs.8 b/mkinitramfs.8 index 23e719f..6d81233 100644 --- a/mkinitramfs.8 +++ b/mkinitramfs.8 @@ -1,4 +1,4 @@ -.TH MKINITRAMFS 8 "$Date: 2006/10/12 $" "" "mkinitramfs manual" +.TH MKINITRAMFS 8 "$Date: 2007/01/02 $" "" "mkinitramfs manual" .SH NAME mkinitramfs \- generate an initramfs image @@ -59,6 +59,11 @@ setting in .IR initramfs.conf . .TP +\fI version +Set the kernel version of the initramfs image +(defaults to the running kernel). + +.TP \fB\-\-supported-host-version=\fIhversion This option queries if mkinitramfs can create ramdisks on a running kernel of version .IR hversion . diff --git a/scripts/functions b/scripts/functions index 7e67771..7ae9c78 100644 --- a/scripts/functions +++ b/scripts/functions @@ -60,11 +60,11 @@ panic() /sbin/usplash_write "QUIT" fi # Disallow console access - if [ "${panic}" = 0 ]; then + if [ -n "${panic}" ] && [ "${panic}" = 0 ]; then reboot fi - modprobe -q i8042 - modprobe -q atkbd + modprobe i8042 + modprobe atkbd echo $@ PS1='(initramfs) ' /bin/sh -i </dev/console >/dev/console 2>&1 } @@ -206,7 +206,7 @@ load_modules() if [ "$com" = "#" ]; then continue fi - modprobe -q $m + modprobe $m done fi } diff --git a/scripts/init-premount/thermal b/scripts/init-premount/thermal index bfea1fc..aa146ec 100755 --- a/scripts/init-premount/thermal +++ b/scripts/init-premount/thermal @@ -18,20 +18,20 @@ esac case "$DPKG_ARCH" in # load the right modules powerpc|ppc64) - modprobe -q i2c-powermac - modprobe -q therm_pm72 - modprobe -q windfarm_cpufreq_clamp - modprobe -q windfarm_lm75_sensor - modprobe -q windfarm_max6690_sensor - modprobe -q windfarm_pm112 - modprobe -q windfarm_pm81 - modprobe -q windfarm_pm91 - modprobe -q windfarm_smu_controls - modprobe -q windfarm_smu_sat - modprobe -q windfarm_smu_sensors + modprobe i2c-powermac + modprobe therm_pm72 + modprobe windfarm_cpufreq_clamp + modprobe windfarm_lm75_sensor + modprobe windfarm_max6690_sensor + modprobe windfarm_pm112 + modprobe windfarm_pm81 + modprobe windfarm_pm91 + modprobe windfarm_smu_controls + modprobe windfarm_smu_sat + modprobe windfarm_smu_sensors ;; i386|amd64|ia64) - modprobe -q fan - modprobe -q thermal + modprobe fan + modprobe thermal ;; esac diff --git a/scripts/init-top/framebuffer b/scripts/init-top/framebuffer index 7c080f9..c680409 100755 --- a/scripts/init-top/framebuffer +++ b/scripts/init-top/framebuffer @@ -59,9 +59,6 @@ parse_video_opts() FB="" OPTS="" -SPLASH=false; -VESA=false; - for x in $(cat /proc/cmdline); do case ${x} in splash*) @@ -89,8 +86,8 @@ matroxfb) esac if [ -n "${FB}" ]; then - modprobe -q fbcon - modprobe -q ${FB} ${OPTS} + modprobe fbcon + modprobe ${FB} ${OPTS} fi if [ -e /proc/fb ]; then diff --git a/scripts/local b/scripts/local index f4079d5..4e01472 100644 --- a/scripts/local +++ b/scripts/local @@ -40,9 +40,9 @@ mountroot () # We've given up, but we'll let the user fix matters if they can while [ ! -e "${ROOT}" ]; do - echo " Check root= bootarg cat /proc/cmdline" - echo " or missing modules, devices: cat /proc/modules ls /dev" - panic "ALERT! ${ROOT} does not exist. Dropping to a shell!" + echo "ALERT! ${ROOT} does not exist. Dropping to a shell!" + echo " Check your root= boot argument (cat /proc/cmdline)" + panic " Check for missing modules (cat /proc/modules), or device files (ls /dev)" done # Get the root filesystem type if not set @@ -67,7 +67,7 @@ mountroot () fi # FIXME This has no error checking - modprobe -q ${FSTYPE} + modprobe ${FSTYPE} # FIXME This has no error checking # Mount root diff --git a/scripts/local-top/lvm b/scripts/local-top/lvm index 27053de..4cf48ad 100755 --- a/scripts/local-top/lvm +++ b/scripts/local-top/lvm @@ -64,9 +64,9 @@ if [ ! -e /sbin/vgchange ]; then exit 0 fi -modprobe -q dm-mod -modprobe -q dm-snapshot -modprobe -q dm-mirror +modprobe dm-mod +modprobe dm-snapshot +modprobe dm-mirror activate_vg "$ROOT" activate_vg "$resume" diff --git a/scripts/local-top/mdrun b/scripts/local-top/mdrun deleted file mode 100755 index f733656..0000000 --- a/scripts/local-top/mdrun +++ /dev/null @@ -1,46 +0,0 @@ -#!/bin/sh - -PREREQ="udev_helper" - -prereqs() -{ - echo "$PREREQ" -} - -case $1 in -# get pre-requisites -prereqs) - prereqs - exit 0 - ;; -esac - -if [ -e /scripts/local-top/mdadm ]; then - exit 0 -fi - -unset raidlvl -gotraid=n - -# Detect raid level -for x in /dev/hd[a-z][0-9]* /dev/sd[a-z][0-9]*; do - if [ ! -e ${x} ]; then - continue - fi - raidlvl=$(mdadm --examine ${x} 2>/dev/null | grep "Level" | sed -e 's/.*Raid Level : \(.*\)/\1/') - if [ "$raidlvl" ]; then - modprobe -q ${raidlvl} 2>/dev/null - gotraid=y - fi -done - -[ "${gotraid}" = y ] || exit - -# source the presumed root md and it's info -. ./conf/mdrun.conf - -# assemble root raid first due to initrd-tools compatibility -mdadm -A ${rootraiddev} -R -u $uuid $devices - -# assemble all raid devices -/sbin/mdrun /dev diff --git a/scripts/local-top/udev_helper b/scripts/local-top/udev_helper index 2d4c209..c1694b7 100755 --- a/scripts/local-top/udev_helper +++ b/scripts/local-top/udev_helper @@ -19,5 +19,5 @@ esac # but might be an old fashioned ISA controller; in which case # we need to load ide-generic. if [ ! -e "${ROOT}" -o "${ROOT}" = "/dev/root" ]; then - modprobe -q ide-generic + modprobe ide-generic fi diff --git a/scripts/nfs b/scripts/nfs index fc869cc..5eb17bf 100644 --- a/scripts/nfs +++ b/scripts/nfs @@ -78,9 +78,9 @@ mountroot() run_scripts /scripts/nfs-top [ "$quiet" != "y" ] && log_end_msg - modprobe -q nfs + modprobe nfs # For DHCP - modprobe -q af_packet + modprobe af_packet # Default delay is around 180s # FIXME: add usplash_write info diff --git a/update-initramfs b/update-initramfs index 52e603b..a676fe9 100755 --- a/update-initramfs +++ b/update-initramfs @@ -4,6 +4,8 @@ STATEDIR=/var/lib/initramfs-tools BOOTDIR=/boot CONF=/etc/initramfs-tools/update-initramfs.conf KPKGCONF=/etc/kernel-img.conf +mode="" +version="" set -e @@ -136,7 +138,7 @@ run_lilo() { # show lilo errors on failure if ! lilo -t > /dev/null 2>&1 ; then - echo "update-initramfs: lilo run failed for ${initramfs}:" + echo "Error lilo fails for new ${initramfs}:" echo lilo -t fi @@ -146,6 +148,16 @@ run_lilo() # check if lilo is on mbr mbr_check() { + # try to discover grub and be happy + [ -r /boot/grub/menu.lst ] \ + && groot=$(awk '/^root/{print substr($2, 2, 3); exit}' \ + /boot/grub/menu.lst) + [ -e /boot/grub/device.map ] && [ -n "${groot}" ] \ + && dev=$(awk "/${groot}/{ print \$NF}" /boot/grub/device.map) + [ -n "${dev}" ] && [ -r ${dev} ] \ + && dd if="${dev}" bs=512 skip=0 count=1 2> /dev/null \ + | grep -q GRUB && return 0 + # check out lilo.conf for validity boot=$(awk -F = '/^boot=/{ print $2}' /etc/lilo.conf) [ -z "${boot}" ] && return 0 @@ -162,16 +174,6 @@ mbr_check() dd if="${boot}" bs=512 skip=0 count=1 2> /dev/null | grep -q LILO \ && run_lilo && return 0 - # try to discover grub and be happy - [ -r /boot/grub/menu.lst ] \ - && groot=$(awk '/^root/{print substr($2, 2, 3); exit}' \ - /boot/grub/menu.lst) - [ -e /boot/grub/device.map ] && [ -n "${groot}" ] \ - && dev=$(awk "/${groot}/{ print \$NF}" /boot/grub/device.map) - [ -n "${dev}" ] && [ -r ${dev} ] \ - && dd if="${dev}" bs=512 skip=0 count=1 2> /dev/null \ - | grep -q GRUB && return 0 - # no idea which bootloader is used echo echo "WARNING: grub and lilo installed." diff --git a/update-initramfs.conf.5 b/update-initramfs.conf.5 index 30ef6d0..50e1f95 100644 --- a/update-initramfs.conf.5 +++ b/update-initramfs.conf.5 @@ -1,4 +1,4 @@ -.TH UPDATE-INITRAMFS.CONF 5 "$Date: 2006/10/12 $" "" "update-initramfs.conf manual" +.TH UPDATE-INITRAMFS.CONF 5 "$Date: 2006/12/22 $" "" "update-initramfs.conf manual" .SH NAME update-initramfs.conf \- configuration file for update-initramfs @@ -13,7 +13,7 @@ The configuration file allows to disable the update action from Default is \fIyes\fP for running the latest initramfs-tools hooks in the newest Linux image. It is possible to set it to \fIno\fP for remote servers or boxes where -conservative manners needs to be applied. This disables +conservative manners needs to be applied. This disables the \fBupdate_initramfs -u\fP call. .SH AUTHOR |