How are cascading hubs working

2

I have a 1Gbit/s LAN. I have connected a multi-speed switch that supports 10 Mbit/s to that LAN. On the other side of the multi-speed switching hub is a Ethernet device that has only 10 Mbit/s.

The multi-speed hub receives the packets at one side into an internal buffer and sends the packet on the other side after the receive is complete and the packet is valid.

I have observed that TCP connections work in both direction without packet loss and TCP re-transmission. Such a TCP traffic sends a bunch of packets with TCP segments before the ACK for the first segment is received.

If the multi-speed hub receives the packets at 1 GBit/s and can only send at a speed of 1 percent, why doesn't it lose packets? I don't think that it can have eternal buffer capacity.

Edit: To make the question more clear... The node that sends IP packets with TCP segments send up to 20 packets in a row without waiting for any TCP-ACK packet from the node at the low-speed side. This is allows by the TCP window size. If the 10 MBit/s link isn't able to transfer the data, where is it (temporary) stored?

harper

Posted 2019-03-11T07:01:55.043

Reputation: 860

You say it doesn't have "eternal buffer capacity" but as your edit makes clear, it would only need to buffer 20 packets, less than 64KB, to avoid packet loss. – David Schwartz – 2019-03-22T21:18:34.003

Answers

1

It is important to make the distinction between a Hub, and a Switch.

Hubs

  • Dumb devices, sometimes called a bit spitter or repeater. what comes in one port gets repeated on every other port.
  • Internally these devices are a Bus Topology, which means it will be using Carrier sense multiple access with collision detection (CSMA/CD).

  • Each device connected to a hub port is in a shared collision domain, only one device can send or receive at a time. If any devices do have a collision (both try to TX at the same time.) then both devices wait for a random "back-off" timer to re-transmit. This is also called "Half-Duplex" communication.

  • Traditionally these devices reside at the physical layer of the OSI-Model (Layer-1)

Switches

  • "Smart devices" when a packet is received on a ingress port, the switch (also applies to bridges) looks at a MAC-table or CAM-table and determines what egress port the intended device is connected to. If a device is not known, or has aged out of the MAC-table the switch will flood all the ports (excluding the ingress port) to learn the device mac-address and add it to the table.
  • in reference to CSMA\CD, each switch port is in its own collision domain.
  • Modern switches have buffers (internal memory) for ingress/egress of each port. (this may not be the case for consumer grade gear that may have a ingress/egress internal buffer that's shared between all the switch ports.)
  • Traditionally resides at Layer-2 of the OSI-Model, but more modern switches transcend that gap and can perform functions at layer-3.


You may be wondering how all this applies to the question. without knowing the switch model and 10Mbps devices NIC make/model, its almost impossible to give a definitive answer. (This is if the manufacturer even bothered to mention the buffers in the documentation.)

An educated guess would be this.

If one 10Mbps device is connected to the switch port, there is no contention for bandwidth.

The 10/100/1000Mbps switch has internal buffers that can take something sent at the device using 1Gbps, and bleed it to the 10Mbps device using the internal buffers, and doesn't need to drop packets.

I may have missed some things in the distinction of the two, its been awhile since i learned about the differences.

~Best Regards

This question over at networkengineering.SE may also help.

Tim_Stewart

Posted 2019-03-11T07:01:55.043

Reputation: 3 983

Everything you write is reasonable true. I used the term hub, since these multi-speed devices are sold as "switching hub"s. Keeping this naming flaw aside, there is still the question about the mechanism that controls the 1GB transmitting side to avoid a buffer overflow in the switching hub. There is no eternal RAM inside. – harper – 2019-03-23T08:19:01.153

What's the model, I'm willing to bet it's buffers are vampiric to the main ram on the switch motherboard. (It has to have buffers from somewhere, or it would just toss the packets) this is actually ok in the TCP/IP scheme, they would normally be retransmitted with the sequence check. – Tim_Stewart – 2019-03-23T17:24:20.000

You're right. An approach as described in your answer causes massive retransmission due to tossed packets. This would be a systemic error. I am convinced this has been found someone before me and the problem has been solved. I am asking, HOW this is done. – harper – 2019-03-23T18:02:25.200

0

The speed of the transfer has nothing to do with the speed of the connection.
Think of it this way: Your car goes 150 MPH, but that doesnt mean it is always going that fast. The data isnt being sent at 1 Gb/s. The switch might be connected at gigabit speeds, but it doesnt mean is has to send data at that speed. Whatever device is sending data to the slow 10 Mb/s device is waiting for acknowledgments from the slow device to send more data.

Keltari

Posted 2019-03-11T07:01:55.043

Reputation: 57 019

1I made the question more clear. I observed that the sender is not waiting for a TCP ACK. Waiting for a TCP ACK would dramatically limit the bandwidth because the sender would always have to wait for the round-trip-time. – harper – 2019-03-11T10:30:35.410