• We should now be fully online following an overnight outage. Apologies for any inconvenience, we do not expect there to be any further issues.

Really innane Ethernet question?

tdowning

Member
May 29, 2003
69
0
0
This question has been rolling around in my head for a long time hnd I havn't been able to get an answer.

what happens when a 100 Mbit Ethernet computer sends a frame to a 10 Mbit computer (interface, whatever) through a hub?

I know it all goes off without a hitch, (Because I had 10/100 and 10baset computers connected to the same 10/100 hub, but the quyestion is what happens to make that work?

does a hub actually work as a bridge of two networks, (10 mbit and 100 mbit) do the 100 mbit nodes just keep track of the MAC addresses of the 10 mbit nodes?

Now I'm fairly certain that modern equipnent, (Like say Cisco and other enterprise switches,) would have to be able to buffer and re-transmit the entire frame, (Otherwise those Gbit uplink ports would be useless, cause everything would have to come in at 100 Mbit in order to get out...) but like I said, What about the cheap 100 Mbit hib that I have, that I got for $50 along with 2 NIC's and 2x Cat 5 cables?

I just want to satisfy my own curiosity
 

ScottMac

Moderator<br>Networking<br>Elite member
Mar 19, 2001
5,471
2
0
Going from the high-speed interfae to the lower-speed interface the frame is buffered. Even the dual speed "hubs" that were on the market (i.e., Intel switch hub) were doing what is essentially store & forward.

FWIW

Scott
 

Mark R

Diamond Member
Oct 9, 1999
8,513
16
81
A 10/100 hub is basically a 10 Mbps hub and a 100 Mbps hub connected via a 2 port switch (or bridge). As stated earlier, this switch operates in store-and-forward mode, and tracks the MAC addresses. This is usually all contained within a single chip which contains both hubs and the switch, and will automatically connect each port to the appropriate hub internally.

Integration and mass-market has done amazing thing to prices. I just picked up an 8-port N-Way 100 Mbps switch for less than what I paid for a 8 port 10 mbps hub 3 years ago (and it's metal and has an internal universal PSU instead of a pregnant plug).
 

yak8998

Member
May 2, 2003
135
0
0
I believe 'pregnant plug' is same thing as 'wall wart', same thing as an external AC adapter...
 

thorin

Diamond Member
Oct 9, 1999
7,573
0
0
Originally posted by: tdowning
This question has been rolling around in my head for a long time hnd I havn't been able to get an answer.

what happens when a 100 Mbit Ethernet computer sends a frame to a 10 Mbit computer (interface, whatever) through a hub?
Through a HUB the 100Mbit (capable) device simply sends at 10Mbit (just as it would if they were on a cross over cable using a direct connection).
does a hub actually work as a bridge of two networks, (10 mbit and 100 mbit) do the 100 mbit nodes just keep track of the MAC addresses of the 10 mbit nodes?
If it's a switched hub, just a plain switch, or a router with built-in switch (like most Cable/DSL routers) then it does store and forward (as other have pointed out). Not many companies manufacture bridges for domestic/SOHO use (actually I can't think of any that I've ever seen).

Thorin
 

spidey07

No Lifer
Aug 4, 2000
65,469
5
76
Not many companies manufacture bridges for domestic/SOHO use (actually I can't think of any that I've ever seen).

Every little soho switch is a multiport bridge. Heck, every switch is a bridge.

But others have already covered it pretty well. And in this case with a 10/100 "hub" there is a bridge between two hubs internally. The hub doing the layer one repeater work and the bridge handling layer 2 or possibly in this case simply forwarding every frame without even building an address table.

You may as well toss out the 10/100 hub or any 100 Base-T hub. They were very short lived and never performed very well. Collisions and half-duplex are never seen in today's networks because everything is switched.

In larger switches every single port has a buffer, sometimes as large as 32 K. While the frame is being buffered all kinds of computations are being run to see what to do with it. Where does it go? Should I modify it? What class or quality of service is needed?
 

thorin

Diamond Member
Oct 9, 1999
7,573
0
0
"Every little soho switch is a multiport bridge. Heck, every switch is a bridge."

Ok I can agree with that. I was thinking of a bridge more like the dedicated bridges you used to see in DECNet type networks. ie: A bridge as a non-integrated componenet of a network.

Thorin
 

drag

Elite Member
Jul 4, 2002
8,708
0
0
All hubs are just devices to hook wires together into a one big wire, some are passive were they are just places to plug stuff into, others are multi-port repeaters in that they have a supply of electricity to boost the signal strength. That is all hubs are. hubs are considured a level 1 device, meaning they are purely physical connectors and do not do anything other then that. If you have a 100mbit line plugged into a hub from one computer and a 10Mb line from another it will run at 10Mb speed on both lines, if they 100Mb line is set to autdetect. Even if you have a hundred 100Mb lines hooked into a hub and one 10Mb, the effective speed of the entire network will be reduced to 10Mb, even if the computers communicating are using 100Mb. You See in Ethernet all signals are sent to all computer, to the electrical signals it's just one big dumb wire. Like plugging your TV into a wall socket. A hub just provides that connection.

And remember that a repeater is simply a device to add signal streagth to make a ethernet line longer then it's normal limitations. A active hub is a multi-port repeater, and a passive hub is just a physical connection, you don't see many passive hubs no more.

Switches:

A switch is a entirely different thing. It can just be used as a hub just fine. Different switches have different capabilities, some even have router-level capabilities, but most don't need it.

Generally a switch without the added on routing capabilities is a multiport Bridge. A Bridge is a level 2 device. Meaning that it operates above the physical layer in the data link layer. This is the higher-end of the ethernet specifications. Ethernet doesn't use TCP/IP or anything like that. TCP/IP is encapsulated in a ethernet packet, but ethernet doen't depend on it in order to function. You could use netbuie for instance to operate in a ethernet network or Novell's IPX/SPX protocals. In order to identify a computer, ethernet uses the MAC address. This is a unique identifing number that is built into the hardware of every ethernet device every made and should be completely unique identifier (although some devices allow you to modify the MAC address) in all the world.

Plus remember that on a ethernet LAN using a hub every computer is normally connected to every other computer on one long "wire". Only one computer can communicate at one time, it uses up the entire bandwidth.. Because it is a "baseband" technology, One electrical pulse travels the entire length of the wire. Every computer receives the electrical signal. It's a first come first serve deal. If two computers communicate at the same time, the signal gets garbled and a collision happens, then both computers shut up for a random length of time and try again. To many computers on a LAN at once, to many collisions, with reduced bandwidth. All computer receives the signal, it it's addressed to it's MAC address it is kept, if not the packet is ignored and dumped.

A bridge creates a record of MAC addresses. Say you got 4 computers, 2 (1 and 2) on one side, 2 (3 and 4) on the other side of the bridge(bridge 1), then you have a second bridge(#2 attached to that on the 3/4 side and it has computers 5/6. The bridge receives packets and passes them thru, at the same time recording the respective MAC addresses. So then if 1 talks to 2, the bridge stops the packets, so that 3/4/5/6 can communicate freely saving bandwidth. If 1 wants to talk to 3, then the bridge1 allows the packet thru and 2/3/4 get the packet, but 2 and 4 ignores it because it's not assigned to their MAC addresses. However, if 1 wants to talk to 6 then both bridges allow the packet to pass and 2/3/4/5/6 all get the packet and all but 6 ignore it, so then you lose the nice bandwidth savings and might as well have a repeater in the last instance.

With switches, bridges are rarely used any more....

Finally you get the Router. The router operates at level 3 and 4. Meaning the network and transport layers. This is above the ethernet specification. This is were the TCP/IP comes into use. IPX/SPX is another routable protocol, but Netbuie is not(for that you must use a WINS server -crap). Say you have a router with 3 ethernet networks attached. It has three ports, a/b/c. Computers 1 and 2 are attached to A. 3/4, B. And 5/6, C. Each network will have a different subnet. All the computers are set up to use there respective router port as a "gateway". Each port on the router needs to have it's own IP address from the same subnet as the computers that are attached to that port.

1 and 2 talk freely to each other over ethernet. However if they want to talk to any others they must send it thru the router. The send the packet on the ethernet using the router's port MAC address, but with the TCP/IP address of the intended computer. The router recieves the packet, strips away the ethernet portion, looks in it's tables finds the correct network and then reattaches the Ethernet portion using it's OWN MAC address for whatever port it is SENDING from. Then sends it to the intended target.

As you see routers will save bandwidth on the network quite a bit, and bridges will too, but not as well. But routers are complicated and expensive compared to bridges. SO that's why they created switches.

Switches are multiport bridges (most of the time) Each computer is connected by it's private line to a port. It's like it's own little private collision domain (collision domain is the correct term for the ONE BIG WIRE concept from before). 1/2/3/4 are all connected to their own port on the switch. Like a bridge the switch records the the MAC address of all the computers. If 1 wants to send to 3, the switch gets the packet, filters it and only sends it out to 3, thus all the rest of computers are spared from the exess signal and are free to transmit to each other if they want.

Your cheap DSL switches for small home networks usually have primitive router stuff built into them. Enough so that they can be a gateway and retransmit the the packet into the internet thru the dsl modem or whatever. Plus they may have extra stuff built in higher up in the levels like a DHCP server to assign TCP/IP information to each computer, plus a simple http server for monitoring and configuring, a DNS server to provide name resolution to the computers.. etc etc. Professional-level switch's don't have these, but they do have many features such as a VPN.

The "levels" are from the OSI's sepifications. more info
 

Shalmanese

Platinum Member
Sep 29, 2000
2,157
0
0
Does this mean passive hubs require now power source? I would love to have a hub that could be run without needing AC power. While wireless networking is all well and good, sometimes you need 100Mbit speeds.
 

FrankSchwab

Senior member
Nov 8, 2002
218
0
0
There are no passive hubs for Ethernet. Never have been, never will be.

drag was wrong on a couple of technical points.

An Ethernet 'Hub' always requires power. It always has a chip (or an awful lot of transistors) inside; at it's most basic, it fools your inherently point-to-point wired 10- or 100- mbps twisted-pair NIC into thinking it's connected into a really old-skool Coax network, which had a bus topology rather than a star topology. It means that every packet sent by any device connected to the hub is visible to all devices connected to the hub. It means that if your NIC wants to talk, it has to listen first to see if the line is free before it starts talking. It means that your NIC has to pay attention when it starts talking to make sure no one else started talking at the same time, and if they did, to shut up and try again in a little bit. It is nearly identical with a "Repeater" used in the old-skool coax days, a very dumb device which "repeats" a packet that came in on a port out to all other ports. It is impossible to buy this kind of device new anymore, though you may find ancient examples on EBay.

A speed-sensing hub is a non-standard "enhanced" hub. It operates much as drag talked about for a "hub" - as long as everything attached to the hub is connected at 100Mbps, everything can talk 100Mbps. As soon as a 10mbps device is connected, everything has to drop down to 10 mbps. It's non-standard because there was never an "official" way to drop down to 10mbps, nor to "step up" to 100mbps if the 10mbps device went away. It is also similar to a "repeater", it's just a repeater that can change speeds. These types of devices were only sold for about three weeks ;) a long time ago, so you'll almost never find one, even on EBay.

A Dual-Speed hub is basically two internal hubs connected with a bridge. One of the internal hubs is a 10mbps device, the other a 100 mbps device. When a NIC is connected to one of its ports, it figures out what speed the NIC is capable of talking at, and internally routes the signals to the correct-speed internal hub. Internally, there is a "bridge", a device which is connected between the internal 10mbps hub and the internal 100mbps hub. The "bridge" has sufficient memory to store some number of packets (varies between manufacturers), and enough "smarts" to know whether or not to resend a packet received from one hub to the other hub. Thus, a packet that comes in on the internal 10 mbps hub gets repeated to all other devices attached to the internal 10mbps hub, including the internal bridge. The bridge looks at who the packet is addressed to (the "destination"), and decides whether or not to retransmit it on the internal 100mbps hub. The bridge receives the whole packet into memory before making that decision, so it adds a small amount of delay to the transmission time of the packet (roughly 1.5 ms for a maximum-length 10mbps ethernet packet). These devices are sometimes still found on very low-cost hubs (look for terms such as "dual-speed hub with 2-port switch").

The main function of the bridge is to separate traffic - if two devices are on the same side of the bridge, and communicating heavily with each other (say, synchronizing their pRon collection), they don't impact the amount of network bandwidth available on the other side of the bridge - this is a GOOD THING, and generally overcomes the negatives associated with the small delay they impose.

drag's description of switches is very good. Basically, a switch and a bridge are very similar things. They receive packets on one port, and make a decision whether to retransmit it on another port (or ports). Normally, a device is called a "bridge" if it only has two ports and a "switch" if it has more than two ports, though (as in the previous example) many marketing departments will call a two-port bridge a "switch". The store-and-forward switch, like the bridge, completely receives a packet before making a decision whether or not to retransmit it out its other port(s), adding a small amount of delay. This is almost invariably the type of device on the shelves down at your local computer supply store today.

(aside: During the early development of switches, there were a variety known as "cut-through" switches. In this type of device, the switch would make the decision about whether or not to retransmit the packet after only receiving the first 12 bytes of the packet, because the destination address is there. It would then, if appropriate, immediately start retransmitting the packet out the other port(s) WHILE IT WAS STILL RECEIVING on the first port. Needless to say, this reduced the added delay significantly (from 1.5 ms to 0.016 ms at 10mbps). However, the complexity of this approach and various real-world considerations (what do you do if the other port is already busy) made it a difficult product to make work correctly. I believe some manufacturers still provide a sophisticated version of this, but I am not sure.)

So, the simple answer to your question is:
The packet comes in on the 100 mbps port of a bridge/switch inside the little black box with all the wires connected to it. It is stored in memory. The bridge/switch looks at the destination address that is attached to the packet, goes and looks in a table to see which port it should send the packet back out on, and then sends it out that port if necessary. There are a few complications here (for example, it doesn't resend it out the same port it came in on), but that's the gist of it.


/frank