- mkinitramfs: allow umask setting paranoid

- revert an nfs changes
small fixes over the place
This commit is contained in:
maximilian attems 2006-09-27 16:03:30 +02:00
parent 681dc7a756
commit b8c8f676a5
6 changed files with 53 additions and 16 deletions

27
debian/changelog vendored
View File

@ -1,3 +1,30 @@
initramfs-tools (0.81) unstable; urgency=low
Release quick and happy spin j = l + s
* update-initramfs: Really check for mounted /proc on use. (closes: 388241)
Thanks Alex Owen <r.alex.owen@gmail.com>. While beeing in this business,
check for mounted proc in initramfs-tools.preinst too.
* hook-functions: Add new scsi drivers aic94xx and stex. Add new net drivers
ehea, ep93xx_eth and qla3xxx. Thus urgency high.
* update-initramfs: Use set ``--'' to change positional paramaters. Thanks
Jörg Sommer <joerg@alea.gnuu.de>. (closes: 389726)
* scripts/nfs: Revert to previous handling of dhcp server passing server-ip.
(closes: 387808)
* debian/initramfs-tools.preinst: Fix comment typo, thanks
shaulka@012.net.il for the patch. (closes: 389486)
* mkinitramfs: Allow an hook script to set an paranoid umask, considered
useful for shipping gpg keys inside of initramfs. Thanks Max Vozeler
<max@nusquama.org> and Lionel Elie Mamane <lionel@mamane.lu> for the
patch. (closes: 381677)
-- maximilian attems <maks@sternwelten.at> Wed, 27 Sep 2006 15:56:46 +0200
initramfs-tools (0.80) unstable; urgency=high
Release "O partigiano, portami via, che mi sento di morir."

View File

@ -8,9 +8,11 @@ case "$1" in
mkdir -p /etc/initramfs-tools/conf.d
# First time install. Can we autodetect the RESUME partition?
RESUME=$(tail -n $(($(wc -l /proc/swaps | awk ' { print $1 } ') - 1)) /proc/swaps | sort -rk3 | head -n 1 | awk ' { print $1 } ')
if [ -r /proc/swaps ]; then
RESUME=$(tail -n $(($(wc -l /proc/swaps | awk ' { print $1 } ') - 1)) /proc/swaps | sort -rk3 | head -n 1 | awk ' { print $1 } ')
fi
# Inhertic initrd-tools settings if possible.
# Inherit initrd-tools settings if possible.
if [ -e /etc/mkinitrd/mkinitrd.conf ]; then
. /etc/mkinitrd/mkinitrd.conf
fi

View File

@ -148,9 +148,10 @@ auto_add_modules()
;;
net)
for x in 3c59x 8139cp 8139too 8390 b44 bmac bnx2 defxx \
dl2k e1000 e100 epic100 eql fealnx famachi forcedeth \
hp100 mace mv643xx_eth myri10ge natsemi ne2k-pci netconsole \
ns83820 pcnet32 r8169 s2io sis900 skge slhc smc911x starfire \
dl2k e1000 e100 ehea epic100 ep93xx_eth eql fealnx \
famachi forcedeth hp100 mace mv643xx_eth myri10ge \
natsemi ne2k-pci netconsole ns83820 pcnet32 qla3xxx \
r8169 s2io sis900 skge slhc smc911x starfire \
sundance sungem sungem_phy sunhme tg3 tlan de2104x \
de4x5 dmfe tulip winbond-840 xircom_cb xircom_tulip_cb \
typhon via-rhine via-velocity yellowfin; do
@ -168,17 +169,18 @@ auto_add_modules()
;;
scsi)
for x in 3w-9xxx 3w-xxxx a100u2x aacraid advansys ahci \
aic79xx aic7xxx 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 \
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 \
qla6312 qlogicfas408 qlogicfc sata_mv sata_nv sata_promise \
sata_qstor sata_sil 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 sym53c8xx tmscsim zfcp; do
sd_mod stex sym53c8xx tmscsim zfcp; do
manual_add_modules "${x}"
done
;;

View File

@ -28,8 +28,7 @@ while true; do
fi
;;
-o)
touch $2
outfile="$(readlink -f "$2")"
outfile="$2"
shift 2
;;
-k)
@ -94,6 +93,13 @@ for i in ${EXTRA_CONF}; do
fi
done
if [ -n "${UMASK}" ]; then
umask "${UMASK}"
fi
touch $outfile
outfile="$(readlink -f "$outfile")"
if [ -z "${outfile}" ]; then
usage
fi

View File

@ -49,7 +49,7 @@ do_nfsmount()
NFSOPTS="-o ${NFSROOT#*,}"
fi
NFSROOT=${NFSROOT%%,*}
if [ "${NFSROOT#:*}" = "$NFSROOT" ]; then
if [ "${NFSROOT#*:}" = "$NFSROOT" ]; then
NFSROOT=${ROOTSERVER}:${NFSROOT}
fi
fi

View File

@ -138,7 +138,7 @@ delete_sha1()
# ro /boot is not modified
ro_boot_check()
{
[ -d /proc ] || return 0
[ -r /proc/mounts ] || return 0
boot_opts=$(awk '/boot/{if (match($4, /ro/)) print "ro"}' /proc/mounts)
if [ -n "${boot_opts}" ]; then
echo "WARNING: /boot is ro mounted."
@ -201,7 +201,7 @@ set_linked_version()
set_highest_version()
{
get_sorted_versions
set - ${version_list}
set -- ${version_list}
version=${1}
}