I have a Windows PC connected to a VLAN ( cisco catalyst 3500 ) switch . The switch has also a DHCP server connected to it. Now when i enable the ethernet interface connected to the VLAN switch ( access mode ) , it takes a long time to get an address from the server . The reason being the switch is dropping the initial DHCP packets sent from the windows PC. The debug messages at in the switch indicate " Line protocol on Interface GigabitEthernet0/7, changed state to down " and after 2 or 3 seconds "Line protocol on Interface GigabitEthernet0/7, changed state to up " and hence when the protocol is down , the packets are getting dropped . only after the interface comes up completely at the switch side the Windows PC gets the address. Can some one please explain why does the line protocol flips its state(up/down ).This problem is not found if i use a LINUX PC as my client.
Can you confirm that you have enabled "spanning-tree portfast" on the port that the Windows PC connects into.
thanks for the fast reply. i have not enabled that command. I will enable it and then try. Can u please let me know wat does that command do with the switchport ??
spanning-tree portfast allows the port to start forwarding and receiving packets immediately. Without it you have to wait for the port to go through the normal STP process which can be up to 45 seconds.
You must make sure that you only enable spanning-tree portfast on ports that are connected to PC's, servers, printers etc. Ports that are connected to other switches/hubs should not have spanning-tree portfast on them.
If the linux pc switch port does not have portfast enabled then it too should take approx 45 seconds before it gets an IP address.
But its working fine with a LINUX PC as a client even if i don enable "spanning tree fastport" command. And i tried it with windows now and its working fine.Thanks.
I tried again with a LINUX PC connected to the other access port of the switch without enabling spanning fastport mode, its working fine and it gets an IP address immediately. Can u please let me know y this behaviour only with windows?? Is windows driver causing any problem ??
Linux keeps querying via DHCP for an address if it doesn't get one, if I remember correctly.
Windows will stop after awhile and assign itself one from the 169.254 address.
So the behavior your seeing is normal. Turn on portfast, it should solve your problem.
Watever u have told is right, but in my case linux is gettig an address faster even if i dont enable that "spanning tree portfast" on the VLAN switch interface to which i have connected the LINUX PC. The intriguing question is why does the switch behave differently with LINUX and WINDOWS?