In the Open Shortest Path First routing algorithm, the information about connected links is "flooded" throughout the network.
How is flooding different from broadcasting?
In the Open Shortest Path First routing algorithm, the information about connected links is "flooded" throughout the network.
How is flooding different from broadcasting?
Broadcasting is a term that is used on a broadcast domain, which is bounded by layer-3 (routers). Broadcasts are sent to a special broadcast address, both for layer-2 and layer-3. A broadcast cannot cross a layer-3 device, and every host in a broadcast domain must be interrupted and inspect a broadcast.
Flooding is used by a switch at layer-2 to send unknown unicast frames to all other interfaces. If a frame is not destined for a host which receives it, the host will ignore it and not be interrupted. This, too, is limited to a broadcast domain.
Flooding in OSPF (layer-3) means that the routes get delivered to every OSPF router in an area. It really has nothing to do with a broadcast. OSPF doesn't use broadcasts to send routes, it uses unicast or multicast to connect with its neighbors. Each OSPF router needs to have a full understanding of all the routers and routes in its area, and it tells all its neighbors about all its local routes, and any routes it hears about from other neighbors. (OSPF routers are unrepentant gossips.)
I will explain here in the context of switches (layer 2).
When a switch receives a unicast frame (a frame with a specific MAC address intended for a particular device), it looks for the frame's destination MAC in its MAC address table. If there is no entry for the destination MAC in its table, it will simply send the frame out to everyone connected to its ports.
The frame is still a unicast frame, since it has a specific destination MAC address in its header. The switch doesn't change any header data in the frame.
All the devices that receive the frame will compare the destination MAC address in the frame with their own MAC address and drop the frame if it doesn't match.
A broadcast frame is created by the host itself. A frame becomes a broadcast frame if the destination MAC address is ff:ff:ff:ff:ff:ff. Usually, the host creates this type of frames during the ARP process. When the switch receives a broadcast frame, it sends it out to everyone connected to it.
In flooding the switch sends the frame to all because it doesn't know how to reach the destination.
In broadcasting the host that created the frame itself addressed the frame to everyone.
I would like to give a simple summary of these two concepts from what I learned from Siva`s answer. ALL about the intention of the original frame.
For flooding: the destination of frame is specific! just switch has no idea of where to switch it but simply switch to everyone it connected except the source interface.[frame exactly know its destination MAC]
For broadcasting: the destination of frame is NOT specific but to anyone(SO that is broadcast!). therefore its MAC address is ff-ff-ff-ff-ff-ff ( or FF-FF-FF-FF-FF-FF, as a MAC address's case does not matter. )[frame has no idea of its destination MAC]
There is often some confusion about a switch in regards to a Broadcast and a Switch’s flooding behavior. The confusion is understandable because the end result is the same, but it is also important to understand the distinction.
A Broadcast frame is a frame which is addressed to everyone on the local network. This is done using the same Ethernet header we’ve been discussing, except the Destination MAC address field is populated with a special address: ffff.ffff.ffff. The “all F’s” address is specially reserved for the purpose of broadcasting.
By definition, if the Switch ever encounters a packet with a destination MAC of ffff.ffff.ffff, it will always flood the frame (after learning the Source MAC, of course).
Another way of looking at it is, since the address ffff.ffff.ffff is reserved, the switch is unable to learn a MAC Address Table mapping for it. As such, any frame destined to this MAC address will always be flooded.
In summary, a Broadcast is a frame addressed to everyone on the local network (ffff.ffff.ffff), and Flooding is an action a switch can take. A broadcast frame, by definition, will always be flooded by a switch. But a switch will never broadcast a frame (since broadcasting is not a function of a switch).
A host send a packet to another host through a switch or router or both. A Broadcast can only happen at layer 3 which is the network layer. Flooding happen a Layer 2. A switch will send out a flood when the mac address is not in it table.
You do have switch that do layer 2 and Layer 3 however it the port is configured for layer 3 then layer 2 is not present at that port.
We sometimes in the industry call a flood a broadcast but it can not be. It seem the some people here have fell into that scenario