Re: booting from host with multiple network cards

2009-12-29 Diskussionsfäden Michael Prokop
* Thomas Neumann blacky+...@fluffbunny.de [20091122 15:45]:

  * bootoption ethdevice: use specified network device for network booting
  (PXE) instead of default (being eth0). Feature contributed by Helge
  Wagner. Usage example: ethdevice=eth1
 [...]
  I think about adding a newer live-initramfs package to the FAI
  repository, so you will automatically get a version that supports this
  new option. Any comments?

 This is just a crude hack.

 I don't care which interface is configured, as long as a usable interface
 is configured. (If there's no dhcp on this network then it's not usable
 - at least for mounting the nfs shares.)
[...]

JFYI: I just implemented a more robust network boot handling which
doesn't care about the number of available network devices but just
works in all situations (without any manual configuration) that I
could reproduce in a HA setup. Details available at:

  http://grml.supersized.org/archives/337-More-robust-network-booting.html

regards,
-mika-
-- 
http://michael-prokop.at/  || http://adminzen.org/
http://grml-solutions.com/ || http://grml.org/


signature.asc
Description: Digital signature


Re: booting from host with multiple network cards

2009-11-23 Diskussionsfäden Stephan Hermann
Good Morning,


On Sun, 22 Nov 2009 13:38:16 +0100
Thomas Lange la...@informatik.uni-koeln.de wrote:

 In the past, several people had problems booting a host with multiple
 network cards. IIRC Dell hardware often had this problem.
 In newer versions of live-initramfs a new bootoption is available.
 
 * bootoption ethdevice: use specified network device for network
 booting (PXE) instead of default (being eth0). Feature contributed by
 Helge Wagner. Usage example: ethdevice=eth1
 
 AFAIKS this option was first added to grml, then the patch was
 also included in the original live-initramfs package.
 http://bts.grml.org/grml/issue724
 
 A backport version of the newest live-initramfs package can be found
 at http://live.debian.net/debian/pool/backports/main/l/live-initramfs/
 
 I think about adding a newer live-initramfs package to the FAI
 repository, so you will automatically get a version that supports this
 new option. Any comments?


I would say, setting ipconfig
in /usr/share/initramfs-tools/scripts/functions to dhcp any interface
which is there should be a better option.

The fun part about this issue is, when you deal with trunk ports and
native vlans on switch interfaces

in this case, it shouldn't matter which device was pxe booting, but
ipconfig (no it's not a typing mistake) should dhcp all interfaces. 
if one of the available interfaces comes through, the process goes on,
and FAI does it's work.

Setting a special interface can give a problem with udev not knowing
that the device e.g. with name eth1 is really the hw device which can
dhcp.

Yes, there are other problems with the implementation of ipconfig (e.g.
my ipconfig setup needs a timeout of 180, because loading the module
for the nic and ipconfigs send dhcp request is not in sync somehow +
port fast on cisco switches is not fast enough ;))

Regards,

\sh 

-- 
| Stephan '\sh' Hermann| OSS Dev / SysAdmin |
| JID: s...@linux-server.org | http://www.sourcecode.de/  | 
| GPG ID: 0xC098EFA8   | http://leonov.tv/  |
| FP: 3D8B 5138 0852 DA7A B83F DCCB C189 E733 C098 EFA8 |


Re: booting from host with multiple network cards

2009-11-23 Diskussionsfäden Frédéric Boiteux
Le Sun, 22 Nov 2009 13:38:16 +0100,
Thomas Lange la...@informatik.uni-koeln.de a écrit :

 In the past, several people had problems booting a host with multiple
 network cards. IIRC Dell hardware often had this problem.
 In newer versions of live-initramfs a new bootoption is available.
 
 * bootoption ethdevice: use specified network device for network
 booting (PXE) instead of default (being eth0). Feature contributed by
 Helge Wagner. Usage example: ethdevice=eth1

  Having the same problem on some HP hardware, I've written a small
script added to live-initramfs' init system to check which interface
has a cable plugged, to run ipconfig on this one. I can give it if
someone is interested…

Fred.



Re: booting from host with multiple network cards

2009-11-23 Diskussionsfäden Frédéric Boiteux
Le Mon, 23 Nov 2009 10:11:25 +0100,
Thomas Lange la...@informatik.uni-koeln.de a écrit :

  On Mon, 23 Nov 2009 10:05:47 +0100, Frédéric Boiteux
  fboit...@calistel.com said:
 
  has a cable plugged, to run ipconfig on this one. I can give it
  if someone is interested?
 Yes, please post it here on this list, and alo give it to the
 live-initramfs (the project is called debian live) guys.
 

For Debian-live people : attached is a small script I add to
live-initramfs' init system to check which interface has a cable
plugged, to run ipconfig on this one (in case you're network booting on
a computer with multiple network interfaces cards, and on which the
boot system and Linux don't enumerate them in the same order).

I add it in the directory /etc/initramfs-tools/scripts/init-premount of
the Debian-live system used for netboot (FAI for example).

  with regards,
Fred.


select_eth_device
Description: Binary data


Re: booting from host with multiple network cards

2009-11-23 Diskussionsfäden Toomas Tamm
On Sun, Nov 22, 2009 at 01:38:16PM +0100, Thomas Lange wrote:

 * bootoption ethdevice: use specified network device for network booting
 (PXE) instead of default (being eth0). Feature contributed by Helge
 Wagner. Usage example: ethdevice=eth1

Does anyone know/remember, why the problem cannot be fixed properly,
i.e. make live-initramfs try all interfaces and use the first one
where a DHCP reply is obtained?

This used to be possible with fai-kernels under etch, so why is it not
possible with live-initramfs?

I imagine someone could even create a patched live-initramfs package
which could be used together with fai in lieu of the lenny default
one?

-- 
Toomas Tamm


Re: booting from host with multiple network cards

2009-11-23 Diskussionsfäden Michael Goetze
Toomas Tamm wrote:
 On Sun, Nov 22, 2009 at 01:38:16PM +0100, Thomas Lange wrote:
 
 * bootoption ethdevice: use specified network device for network booting
 (PXE) instead of default (being eth0). Feature contributed by Helge
 Wagner. Usage example: ethdevice=eth1
 
 Does anyone know/remember, why the problem cannot be fixed properly,
 i.e. make live-initramfs try all interfaces and use the first one
 where a DHCP reply is obtained?
 
 This used to be possible with fai-kernels under etch, so why is it not
 possible with live-initramfs?

Red Hat's Kickstart also does this, I agree it would definitely be much
nicer.

However, lacking that, the ethdevice boot option would at least be
better than what we have now...

Regards,
Michael


Re: booting from host with multiple network cards

2009-11-23 Diskussionsfäden Stephan Hermann
Moins,

just for clarification:



network NFS DHCP boot fails on multiple NIC machine
https://bugs.launchpad.net/ubuntu/+source/initramfs-tools/+bug/182940

initramfs-tools: Network configuration can't work with multiple
interfaces
http://bugs.debian.org/cgi-bin/bugreport.cgi?bug=467078

Regards,

\sh

On Mon, 23 Nov 2009 15:30:40 +0100
Steffen Grunewald steffen.grunew...@aei.mpg.de wrote:

 On Mon, Nov 23, 2009 at 03:22:30PM +0100, Michael Goetze wrote:
  Toomas Tamm wrote:
   On Sun, Nov 22, 2009 at 01:38:16PM +0100, Thomas Lange wrote:
   
   * bootoption ethdevice: use specified network device for network
   booting (PXE) instead of default (being eth0). Feature
   contributed by Helge Wagner. Usage example: ethdevice=eth1
   
   Does anyone know/remember, why the problem cannot be fixed
   properly, i.e. make live-initramfs try all interfaces and use the
   first one where a DHCP reply is obtained?
   
   This used to be possible with fai-kernels under etch, so why is
   it not possible with live-initramfs?
  
  Red Hat's Kickstart also does this, I agree it would definitely be
  much nicer.
  
  However, lacking that, the ethdevice boot option would at least be
  better than what we have now...
 
 I suppose there is no chance to find out which interface had been
 used for the actual PXE booting? 
 For IPMI reasons, eth0 of multi-homed machines may be a public
 interface and eth1 the private one which is connected to the
 installation network. In such a case, the first DHCP response might
 be returned from the public network even if PXE booting took place on
 eth1. (which has preference in the BIOS boot order, btw)
 
 I still don't understand why we can't have back ip=::eth1
 
 Cheers,
  Steffen


-- 
| Stephan '\sh' Hermann| OSS Dev / SysAdmin |
| JID: s...@linux-server.org | http://www.sourcecode.de/  | 
| GPG ID: 0xC098EFA8   | http://leonov.tv/  |
| FP: 3D8B 5138 0852 DA7A B83F DCCB C189 E733 C098 EFA8 |


Re: booting from host with multiple network cards

2009-11-22 Diskussionsfäden Henning Glawe
On Sun, Nov 22, 2009 at 01:38:16PM +0100, Thomas Lange wrote:
 * bootoption ethdevice: use specified network device for network booting
 (PXE) instead of default (being eth0). Feature contributed by Helge
 Wagner. Usage example: ethdevice=eth1

I think that there would be still the problem of interface names/enumeration
of the network devices. Is there any way to detect which interface was used
for pxe/tftp kernel loading? 

-- 
c u
henning


Re: booting from host with multiple network cards

2009-11-22 Diskussionsfäden Thomas Lange
 On Sun, 22 Nov 2009 15:21:07 +0100, Henning Glawe 
 gla...@physik.fu-berlin.de said:

 On Sun, Nov 22, 2009 at 01:38:16PM +0100, Thomas Lange wrote:
 * bootoption ethdevice: use specified network device for network booting
 (PXE) instead of default (being eth0). Feature contributed by Helge
 Wagner. Usage example: ethdevice=eth1

 I think that there would be still the problem of interface 
names/enumeration
 of the network devices. Is there any way to detect which interface was 
used
 for pxe/tftp kernel loading? 
If you have two cards (a very common hardware), and PXE booting is
done from the first card which the kernel defines as eth1, it's a
perfect solution to tell the kernel ethdevice=eth1.

The kernel itself does not know anything about were it was loaded
from. It even does not know if it was loaded from network or disk or
whatever device.

-- 
regards Thomas


Re: booting from host with multiple network cards

2009-11-22 Diskussionsfäden Thomas Neumann
hiya

 * bootoption ethdevice: use specified network device for network booting
 (PXE) instead of default (being eth0). Feature contributed by Helge
 Wagner. Usage example: ethdevice=eth1
[...]
 I think about adding a newer live-initramfs package to the FAI
 repository, so you will automatically get a version that supports this
 new option. Any comments?

This is just a crude hack.

I don't care which interface is configured, as long as a usable interface
is configured. (If there's no dhcp on this network then it's not usable
- at least for mounting the nfs shares.)

Yes I agree that this would be somewhat better then the current situation,
but how much better exactly? Sure you are able to specify a specific
interface, but this only means that you need to write different
tftp-stanza for different host-requirements - and have someone (manually)
decide which to use for what.

But exactly this is one of the great strengths of fai: I really don't care
what system (xen vm, vmware vm, physical server type a, physical server
type b) I need to install. I just launch my trusty fai and let the
configspace figure out the correct configuration.

tschüß
thomas






Re: booting from host with multiple network cards

2009-11-22 Diskussionsfäden Michael Tautschnig
 Sorry for the self-followup, I forgot something
 
  I don't care which interface is configured, as long as a usable interface
  is configured. (If there's no dhcp on this network then it's not usable
  - at least for mounting the nfs shares.)
 
 I have servers with up to 8 network interfaces (2 quadport NICs). I really
 don't want to try educated guesses which interface is assigned what
 eth#. Especially since HP sometimes uses 2 different chips for the 4
 onboard interfaces. (BL680c G5 specific)
 
 Currently interface are assigned as follows:
 
 internal 1 - eth0
 internal 2 - eth1
 internal 3 - eth6
 internal 4 - eth7
 
 addon 1 - eth2
 addon 2 - eth3
 addon 3 - eth4
 addon 4 - eth5
 
 Who knows how long this is going to stay this way? Next kernelrelease?
 Next hardware revision?
 

Forever? 

Well, at least industry acknowledged the problem, and there even seem to be some
workarounds related to PXE stuff:

http://linux.dell.com/files/whitepapers/nic-enum-whitepaper-v4.pdf 

Best,
Michael



pgp4IOR34q9pj.pgp
Description: PGP signature