On 03/31/2011 04:27 PM, micah anderson wrote:
> I love debirf, its so handy!

thanks, glad to hear it!

> However, the handiness is offset by the
> less than handy process of having to build these images and ship them
> off to my machines that I want debirf on. The fact that I want debirf
> installed on every physical mcahine I have, and setup automatically in
> grub2 make me sad that there is no package I can just install.
> 
> I propose building a package that installs pre-built images into
> /boot/debirf  and the following (tested!) /etc/grub.d/21_debirf to fill
> out the grub menu:

Are you imagining that some binary package would actually contain the
pre-built debirf images as well?  I think it would be difficult to
create such a thing on any buildd, since the buildds are not required to
have a network connection.

However, we're now running a debirf autobuilder and publishing
cryptographically-signed, pre-built images for common architectures
(i386 and amd64 at the moment):

 http://debirf.cmrg.net/autobuilds/

What if we made a small arch:all package named "debirf-prebuilt-images"
which provides the grub snippet, and a tool for easy download and
verification of those images?  That package could be installed without
even needing the debirf package or its dependencies at all.

The current autobuilder setup for i386 and amd64 is configured to run
nightly.  The images may therefore change from day to day (all downloads
are verified through the debian-archive-keyring).  This raises a policy
question for admins of the machines who want these images pre-installed:
how frequently should they be updated?  For that matter, does the admin
want images from stable or unstable distributions?

> #!/bin/sh
> set -e
> 
> prefix=/usr
> exec_prefix=${prefix}
> bindir=${exec_prefix}/bin
> libdir=${exec_prefix}/lib
> . ${libdir}/grub/grub-mkconfig_lib
> 
> DEBIRF_CMDLINE="root=/dev/ram0 rw panic=15 $GRUB_CMDLINE_LINUX"

what are the arguments "root=/dev/ram0" and "rw" doing here?  i don't
think they're meaningful in the debirf initramfs.

> # loop-AES arranges things so that /dev/loop/X can be our root device, but
> # the initrds that Linux uses don't like that.
> case ${GRUB_DEVICE} in
>   /dev/loop/*|/dev/loop[0-9])
>     GRUB_DEVICE=`losetup ${GRUB_DEVICE} | sed -e "s/^[^(]*(\([^)]\+\)).*/\1/"`
>   ;;
> esac
> 
> if [ "x${GRUB_DEVICE_UUID}" = "x" ] || [ "x${GRUB_DISABLE_LINUX_UUID}" = 
> "xtrue" ] \
>     || ! test -e "/dev/disk/by-uuid/${GRUB_DEVICE_UUID}" \
>     || uses_abstraction "${GRUB_DEVICE}" lvm; then
>   LINUX_ROOT_DEVICE=${GRUB_DEVICE}
> else
>   LINUX_ROOT_DEVICE=UUID=${GRUB_DEVICE_UUID}
> fi

Aren't these also unnecessary?  why is LINUX_ROOT_DEVICE meaningful to
debirf?  Is this really the minimal grub config snippet such a package
would need?  I'd be happy to ship a reasonable grub config snippet, but
i don't want to cargo-cult anything we don't need.

        --dkg

Attachment: signature.asc
Description: OpenPGP digital signature

Reply via email to