Bug#504753: debian-installer: autodetect correct network card [PATCH] - Debian

This is a discussion on Bug#504753: debian-installer: autodetect correct network card [PATCH] - Debian ; Package: debian-installer using PXElinux, if you add "IPAPPEND=3" in the pxelinux.cfg, /proc/cmdline will contain the boot adapter's MAC address. Using this we can automatically detect which card the box PXEbooted from. This removes the need for us to hardcode eth0 ...

+ Reply to Thread
Results 1 to 3 of 3

Thread: Bug#504753: debian-installer: autodetect correct network card [PATCH]

  1. Bug#504753: debian-installer: autodetect correct network card [PATCH]

    Package: debian-installer

    using PXElinux, if you add "IPAPPEND=3" in the pxelinux.cfg,
    /proc/cmdline will contain the boot adapter's MAC address.

    Using this we can automatically detect which card the box PXEbooted
    from. This removes the need for us to hardcode eth0 on some servers,
    eth1 on others, eth5 on yet others.

    I use the attached script (/bin/set-bootif) run from
    /lib/debian-installer-startup.d/S32set-bootif:
    #!/bin/sh
    /bin/set-bootif


    Adrian
    --
    Email: adrian@smop.co.uk -*- GPG key available on public key servers
    Debian GNU/Linux - the maintainable distribution -*- www.debian.org


  2. Bug#504753: debian-installer: autodetect correct network card [PATCH]

    On Thu, Nov 06, 2008 at 08:49:49PM +0000, Adrian Bridgett wrote:
    > Package: debian-installer
    >
    > using PXElinux, if you add "IPAPPEND=3" in the pxelinux.cfg,
    > /proc/cmdline will contain the boot adapter's MAC address.
    >
    > Using this we can automatically detect which card the box PXEbooted
    > from. This removes the need for us to hardcode eth0 on some servers,
    > eth1 on others, eth5 on yet others.
    >
    > I use the attached script (/bin/set-bootif) run from
    > /lib/debian-installer-startup.d/S32set-bootif:
    > #!/bin/sh
    > /bin/set-bootif

    This is a nice thing to have! Installations get difficult if not all
    interfaces are usuable for installation (e.g. if they're crosslinks for
    DRBD).

    > db_set netcfg/choose_interface $interface
    > # must mark question as seen otherwise you are reprompted
    > db_fset netcfg/choose_interface seen true

    Isn't prompting o.k. here? Preselecting the correnct interface and
    giving a message that this was autodetected might be better, because
    folks might want to choose a different interface.
    Cheers,
    -- Guido




    --
    To UNSUBSCRIBE, email to debian-bugs-dist-REQUEST@lists.debian.org
    with a subject of "unsubscribe". Trouble? Contact listmaster@lists.debian.org

  3. Bug#504753: debian-installer: autodetect correct network card [PATCH]

    On Sat, Nov 8, 2008 at 09:57:26 +0100 (+0100), Guido GŁnther wrote:
    > On Thu, Nov 06, 2008 at 08:49:49PM +0000, Adrian Bridgett wrote:
    > > db_set netcfg/choose_interface $interface
    > > # must mark question as seen otherwise you are reprompted
    > > db_fset netcfg/choose_interface seen true

    > Isn't prompting o.k. here? Preselecting the correnct interface and
    > giving a message that this was autodetected might be better, because
    > folks might want to choose a different interface.


    Good point. In my case this was part of an automated install so
    prompting would be bad. However I suppose the ideal would be to use
    this to try and autodetect the right interface and also provide a way
    to automatically accept it _if_ required.

    Adrian
    --
    Email: adrian@smop.co.uk -*- GPG key available on public key servers
    Debian GNU/Linux - the maintainable distribution -*- www.debian.org



    --
    To UNSUBSCRIBE, email to debian-bugs-dist-REQUEST@lists.debian.org
    with a subject of "unsubscribe". Trouble? Contact listmaster@lists.debian.org

+ Reply to Thread