Author Topic: Mds not booting Cisco switch Spantree  (Read 1184 times)

shortydigital

  • Regular Poster
  • **
  • Posts: 22
    • View Profile
Mds not booting Cisco switch Spantree
« on: January 04, 2008, 06:18:03 pm »
I stumbled across this issue and figured that I’d post it in hopes that it may help someone else down the line since not everyone attempting LMCE is a networker.

Background info: Spanning tree (STP) is a protocol that runs on network switches and discovers and disables multiple paths on a LAN. This is done to prevent loops in the network. This is done this through a series of blocking/listening/learning/forwarding of STP information before other data is allowed to pass. This feature is necessary on switch up link ports, but is not needed on client ports. 
Port fast is a STP feature of that by passes the blocking/listening/learning states of the switch port and allows it to immediately start forwarding. It is intended for server and workstation ports, important for prevent dhcp and bootp from timing out. Unfortunately it is disabled by default on Cisco and many other business grade network switches.

So how is this related to LMCE. I was trying to boot a MD plugged into both a Cisco 2950 and again with a Cisco 3550 switch, and it wouldn’t boot. I noticed that MD’s switch port link light was staying orange (indicating its not up), it wouldn’t turn green to indicating a good link is up until about a second before the MD pxe/bootp attempt timed out and rebooted. I switched it to an old hub and it worked fine. So I logged into my switch and enabled the Portfast feature one the MD’s switch port and it booted just fine.
Config example for a Cisco 24 port 2950 switch, MD was on port 23

Switch: config t
Switch (config) : interface fa 0/23
Switch (config): spanning-tree portfast
Switch (config): end

hari

  • Administrator
  • LinuxMCE God
  • *****
  • Posts: 2420
    • View Profile
    • ago control
Re: Mds not booting Cisco switch Spantree
« Reply #1 on: January 04, 2008, 08:13:23 pm »
if you have to configure plenty of interfaces (e.g. on a 48port switch) i recommend to use the "interface range"   command ;)

that misconfiguration also bugged netware consultants with dos clients in the past..

best regards,
Hari
rock your home - http://www.agocontrol.com home automation

rrambo

  • Guru
  • ****
  • Posts: 221
    • View Profile
Re: Mds not booting Cisco switch Spantree
« Reply #2 on: January 04, 2008, 08:15:05 pm »
that it did, that it did...

and yes, interface-range sure helps when you need to apply this to about 50 switches....

colinjones

  • Alumni
  • LinuxMCE God
  • *
  • Posts: 3003
    • View Profile
Re: Mds not booting Cisco switch Spantree
« Reply #3 on: January 04, 2008, 09:42:38 pm »
A few years ago, I noticed this causing problems on corporate Windows PCs too - not network booting, just getting IP addresses on start up. WinXP on its own was fine with this - would fail to get an IP initially, and so would not be able to log on to the Domain, but shortly after (race condition) would get the IP, connect to the Domain, and just in time for the user to login. But with any services running under a Domain service account (eg on a server) these would always fail during boot and need to be manually started. But it did bugger up GPO processing on XP machines.

But it was specifically associated with one of Broadcom's earlier Gb NICs only on all our PCs and Servers. Must have just been a bit slow coming up, with knock on effects to the port starting to forward after STP. DisableDHCPMediaSense worked for PCs until Portfast could be turned on - even that caused problems with users connecting switches at their desk and then accidentally looping them!

Either way, to this day I see this with most Broadcom NICs. I guess if PXE times out before the port goes to forwarding, this will always happen unless portfast is turned on, and a slow NIC makes it worse. Come to think of it, I think forwarding without portfast takes 50 seconds, doesn't it? If so, I assume PXE would definitely timeout beforehand and that mandates portforwarding. Maybe a Wiki article?

hari

  • Administrator
  • LinuxMCE God
  • *****
  • Posts: 2420
    • View Profile
    • ago control
Re: Mds not booting Cisco switch Spantree
« Reply #4 on: January 04, 2008, 10:19:54 pm »
Come to think of it, I think forwarding without portfast takes 50 seconds, doesn't it?
yes, with default STP times.
Quote
If so, I assume PXE would definitely timeout beforehand and that mandates portforwarding.
yes
Quote
Maybe a Wiki article?
feel free...

best regards,
Hari
rock your home - http://www.agocontrol.com home automation

colinjones

  • Alumni
  • LinuxMCE God
  • *
  • Posts: 3003
    • View Profile
Re: Mds not booting Cisco switch Spantree
« Reply #5 on: January 04, 2008, 10:25:39 pm »
sh*t - I knew you were going to say that! Guess its time to work out how to create a new wiki article :) any pointers on where to link it into the other articles so it isn't an orphan page, and in fact, how to link it??

hari

  • Administrator
  • LinuxMCE God
  • *****
  • Posts: 2420
    • View Profile
    • ago control
Re: Mds not booting Cisco switch Spantree
« Reply #6 on: January 04, 2008, 10:29:13 pm »
sh*t - I knew you were going to say that! Guess its time to work out how to create a new wiki article :) any pointers on where to link it into the other articles so it isn't an orphan page, and in fact, how to link it??
maybe you want to put it in some networking guide category..
rock your home - http://www.agocontrol.com home automation

colinjones

  • Alumni
  • LinuxMCE God
  • *
  • Posts: 3003
    • View Profile
Re: Mds not booting Cisco switch Spantree
« Reply #7 on: January 05, 2008, 12:43:49 am »
OK, I built a basic skeleton of several reasons an MD might not boot correctly, including the portfast thing. I linked it to the Troubleshooting main page, and categorised it as troubleshooting and networking. Its only basic, and needs input from others, but its a start. The Cisco commands definitely need correcting as I was working from dim distant memory!

http://wiki.linuxmce.org/index.php/MDs_Do_Not_Network_%28PXE%29_Boot