Network switches use buffering to temporarily store incoming frames before forwarding them to the correct port, and they support multiple switching methods that balance speed against error checking. Understanding port-based versus shared memory buffering, along with store-and-forward and cut-through switching modes, is essential for grasping how modern switches handle frame traffic efficiently.
Switch Buffering & Forwarding
A message that's coming into a hub is then just directly sent out to all ports right away. But what happens with a switch is it is going to be sending out a message to only one device. Of course, how does it do that? As the message is coming in, there's no way for it to know immediately which device it's going to send it on to. And so what it has to do is what's called buffering. It actually has to store at least a component of that message until it knows what port it can be sent out.
Buffering is the mechanism that does that. There's some sort of memory on the switch, and as a frame is coming into that switch, that switch will actually store that frame until it knows what port it needs to be sent out to. That's called buffering.
There are two different ways that this buffering can happen. There is port-based versus shared.
Port-based just means that the memory is already allocated for every single port. So every port has an allocated amount, a fixed amount of memory that's allocated to it. Then when that frame is coming into that port, that port will store that in that memory, and then once it realizes where the destination needs to go, it will attempt to move it to the queue to go out that port that it needs to go out.
Now the problem with this is, while it's waiting there, number one, that queue could fill up and it could start dropping packets, and number two, that frame that's sitting there could hold up a lot of other traffic on it. So there are some problems with port-based.
So the preferred breath really would be a shared memory, where it goes into a shared memory, and as things come in it goes into the shared memory, it allocates that memory dynamically, and then it sends it out to another location. Also, with port-based you may need a lot more memory involved, because every single allocated port needs to have a certain amount of memory involved, where you might be able to get away with a little bit less with the shared memory, because it can dynamically assign and adjust as the needs of that switch adjust and the needs of each of the ports adjust.
Another setting on our switches about buffering is how we're going to store that data and forward that data. We do have a store and forward, versus we have a cut-through. The store and forward is a slower process, but verifies to make sure things are okay, versus the cut-through tries to send it a little bit quicker.
With the store and forward method, what happens is the whole frame comes into the switch, and then it processes that frame and it takes a look at the trailer and sees what the consistency check is within the trailer, and does an error check on that frame to make sure that the frame is good before it sends it off to its next location.
Versus the cut-through is going to try to expedite that. It's not going to worry about if the frame is going to be fully accurate or not, it's just going to send it along its way. There are a couple of mechanisms that will do that. There's a fast forward and there's a fragment free.
The fast forward is going to do it just long enough to read the destination MAC address, and as soon as it knows the port that it needs to go out, then it's going to start sending it along its way. So we're going to take up a lot less memory with this, and we're also going to expedite our frames to get them along the way. Although we could run into issues, because we could be sending bad frames to the next location, so it could be inefficient in that manner. So that's the fast forward.
Versus fragment free will say, well, I'm going to go a little bit farther than just the destination MAC address, I'm going to actually take a look at the first 64 bytes. The idea behind that is, if there's some sort of collision that happens, it's probably going to be within the first 64 bytes of that frame coming into the switch. So fragment free just takes a look and verifies: is this going to be successful, there's no collisions? Now I'm ready to send to the next location. That's fragment free.
Just one note, bringing it back to the maximum transmission unit. This kind of shows why we need to know approximately how big these frames that are coming into the switch are going to be, because that switch needs to know how to process and handle those frames. We have memory buffering that happens on those switches, and so we need to be able to deal with those. Having a set maximum transmission unit gives an understanding about what it is that we're going to be working with, what we're going to have to be storing, and how we're going to build the hardware to be able to handle these frames that are coming through there.
TechKnowSurge builds IT and cybersecurity professionals through hands-on, concept-first training built around real understanding — not memorization. Free interactive tools, structured programs, and 25+ years of real-world experience, all in one place.
Explore free tools and programs →