Are bridges like hubs or switches?

The name of the pictureThe name of the pictureThe name of the pictureClash Royale CLAN TAG#URR8PPP











up vote
0
down vote

favorite












It is my understanding that the main difference between a network hub and a network switch is that the hub always sends out all packets to all (other?) hosts while the switch is smart about it and keeps track of which port belongs to which MAC address via ARP tables and whatnot. If a packet is addressed to a host which is connected to the switch but have never sent or received anything, the switch acts like a hub would. But every subsequent packet addressed to that host is not broadcast to the other hosts but forwarded only to that specific host. Please correct me if I got something wrong.



Does a network bridge in Linux act like a hub would, or like a switch?







share|improve this question




















  • A bridge is a special case of a switch in the network theory, no matter what tech you are using. This does not seems a Unix doubt.
    – Rui F Ribeiro
    Mar 15 at 14:12











  • The reason I posted it here was because I suspect that a bridge net device might be implemented differently on different platforms/paradigms.
    – lindhe
    Mar 15 at 14:16














up vote
0
down vote

favorite












It is my understanding that the main difference between a network hub and a network switch is that the hub always sends out all packets to all (other?) hosts while the switch is smart about it and keeps track of which port belongs to which MAC address via ARP tables and whatnot. If a packet is addressed to a host which is connected to the switch but have never sent or received anything, the switch acts like a hub would. But every subsequent packet addressed to that host is not broadcast to the other hosts but forwarded only to that specific host. Please correct me if I got something wrong.



Does a network bridge in Linux act like a hub would, or like a switch?







share|improve this question




















  • A bridge is a special case of a switch in the network theory, no matter what tech you are using. This does not seems a Unix doubt.
    – Rui F Ribeiro
    Mar 15 at 14:12











  • The reason I posted it here was because I suspect that a bridge net device might be implemented differently on different platforms/paradigms.
    – lindhe
    Mar 15 at 14:16












up vote
0
down vote

favorite









up vote
0
down vote

favorite











It is my understanding that the main difference between a network hub and a network switch is that the hub always sends out all packets to all (other?) hosts while the switch is smart about it and keeps track of which port belongs to which MAC address via ARP tables and whatnot. If a packet is addressed to a host which is connected to the switch but have never sent or received anything, the switch acts like a hub would. But every subsequent packet addressed to that host is not broadcast to the other hosts but forwarded only to that specific host. Please correct me if I got something wrong.



Does a network bridge in Linux act like a hub would, or like a switch?







share|improve this question












It is my understanding that the main difference between a network hub and a network switch is that the hub always sends out all packets to all (other?) hosts while the switch is smart about it and keeps track of which port belongs to which MAC address via ARP tables and whatnot. If a packet is addressed to a host which is connected to the switch but have never sent or received anything, the switch acts like a hub would. But every subsequent packet addressed to that host is not broadcast to the other hosts but forwarded only to that specific host. Please correct me if I got something wrong.



Does a network bridge in Linux act like a hub would, or like a switch?









share|improve this question











share|improve this question




share|improve this question










asked Mar 15 at 14:08









lindhe

1,23731226




1,23731226











  • A bridge is a special case of a switch in the network theory, no matter what tech you are using. This does not seems a Unix doubt.
    – Rui F Ribeiro
    Mar 15 at 14:12











  • The reason I posted it here was because I suspect that a bridge net device might be implemented differently on different platforms/paradigms.
    – lindhe
    Mar 15 at 14:16
















  • A bridge is a special case of a switch in the network theory, no matter what tech you are using. This does not seems a Unix doubt.
    – Rui F Ribeiro
    Mar 15 at 14:12











  • The reason I posted it here was because I suspect that a bridge net device might be implemented differently on different platforms/paradigms.
    – lindhe
    Mar 15 at 14:16















A bridge is a special case of a switch in the network theory, no matter what tech you are using. This does not seems a Unix doubt.
– Rui F Ribeiro
Mar 15 at 14:12





A bridge is a special case of a switch in the network theory, no matter what tech you are using. This does not seems a Unix doubt.
– Rui F Ribeiro
Mar 15 at 14:12













The reason I posted it here was because I suspect that a bridge net device might be implemented differently on different platforms/paradigms.
– lindhe
Mar 15 at 14:16




The reason I posted it here was because I suspect that a bridge net device might be implemented differently on different platforms/paradigms.
– lindhe
Mar 15 at 14:16










2 Answers
2






active

oldest

votes

















up vote
7
down vote













A bridge is a network aggregation device, similar in practice to a switch. The bridges implemented in the Linux kernel follow this model. Like any bridge, they forward traffic based on destination MAC addresses, once the MAC address mapping is known. They are actually more featureful than most switches, since they also support firewalling, traffic shaping etc., using ebtables.



See the bridge documentation for details.






share|improve this answer
















  • 1




    (I implemented bridges in DOS and Cisco in the 90s supporting port-based firewalling ;) in Linux too later on, but honestly cant remember for what. Protecting the gateway of a wifi network? Cant remember. I also have a Linux bridge at home because of Apple multicast protocols )
    – Rui F Ribeiro
    Mar 15 at 14:17


















up vote
-1
down vote













actually there is a small difference between the switch and hub.hub don't store the mac of connected devices,so the packets received from any host reaches every other connected hosts .Where as switch stores the mac of connected devices and send the packet to respective receiver whose details(like mac,ip) mentioned in packet headers....






share|improve this answer
















  • 2




    I don't think I understand what you mean I got wrong. To me, it seems like I described it similar to what you say. Also, I think this is not an anser to my question, but rather a comment (which I appreciate, btw). Also also, when talking about switches, it's usually implied that it is L2 switches, and they do not care about any packet header, only the frame header (so no IP).
    – lindhe
    Mar 15 at 20:00











Your Answer







StackExchange.ready(function()
var channelOptions =
tags: "".split(" "),
id: "106"
;
initTagRenderer("".split(" "), "".split(" "), channelOptions);

StackExchange.using("externalEditor", function()
// Have to fire editor after snippets, if snippets enabled
if (StackExchange.settings.snippets.snippetsEnabled)
StackExchange.using("snippets", function()
createEditor();
);

else
createEditor();

);

function createEditor()
StackExchange.prepareEditor(
heartbeatType: 'answer',
convertImagesToLinks: false,
noModals: false,
showLowRepImageUploadWarning: true,
reputationToPostImages: null,
bindNavPrevention: true,
postfix: "",
onDemand: true,
discardSelector: ".discard-answer"
,immediatelyShowMarkdownHelp:true
);



);








 

draft saved


draft discarded


















StackExchange.ready(
function ()
StackExchange.openid.initPostLogin('.new-post-login', 'https%3a%2f%2funix.stackexchange.com%2fquestions%2f430407%2fare-bridges-like-hubs-or-switches%23new-answer', 'question_page');

);

Post as a guest






























2 Answers
2






active

oldest

votes








2 Answers
2






active

oldest

votes









active

oldest

votes






active

oldest

votes








up vote
7
down vote













A bridge is a network aggregation device, similar in practice to a switch. The bridges implemented in the Linux kernel follow this model. Like any bridge, they forward traffic based on destination MAC addresses, once the MAC address mapping is known. They are actually more featureful than most switches, since they also support firewalling, traffic shaping etc., using ebtables.



See the bridge documentation for details.






share|improve this answer
















  • 1




    (I implemented bridges in DOS and Cisco in the 90s supporting port-based firewalling ;) in Linux too later on, but honestly cant remember for what. Protecting the gateway of a wifi network? Cant remember. I also have a Linux bridge at home because of Apple multicast protocols )
    – Rui F Ribeiro
    Mar 15 at 14:17















up vote
7
down vote













A bridge is a network aggregation device, similar in practice to a switch. The bridges implemented in the Linux kernel follow this model. Like any bridge, they forward traffic based on destination MAC addresses, once the MAC address mapping is known. They are actually more featureful than most switches, since they also support firewalling, traffic shaping etc., using ebtables.



See the bridge documentation for details.






share|improve this answer
















  • 1




    (I implemented bridges in DOS and Cisco in the 90s supporting port-based firewalling ;) in Linux too later on, but honestly cant remember for what. Protecting the gateway of a wifi network? Cant remember. I also have a Linux bridge at home because of Apple multicast protocols )
    – Rui F Ribeiro
    Mar 15 at 14:17













up vote
7
down vote










up vote
7
down vote









A bridge is a network aggregation device, similar in practice to a switch. The bridges implemented in the Linux kernel follow this model. Like any bridge, they forward traffic based on destination MAC addresses, once the MAC address mapping is known. They are actually more featureful than most switches, since they also support firewalling, traffic shaping etc., using ebtables.



See the bridge documentation for details.






share|improve this answer












A bridge is a network aggregation device, similar in practice to a switch. The bridges implemented in the Linux kernel follow this model. Like any bridge, they forward traffic based on destination MAC addresses, once the MAC address mapping is known. They are actually more featureful than most switches, since they also support firewalling, traffic shaping etc., using ebtables.



See the bridge documentation for details.







share|improve this answer












share|improve this answer



share|improve this answer










answered Mar 15 at 14:16









Stephen Kitt

141k22307367




141k22307367







  • 1




    (I implemented bridges in DOS and Cisco in the 90s supporting port-based firewalling ;) in Linux too later on, but honestly cant remember for what. Protecting the gateway of a wifi network? Cant remember. I also have a Linux bridge at home because of Apple multicast protocols )
    – Rui F Ribeiro
    Mar 15 at 14:17













  • 1




    (I implemented bridges in DOS and Cisco in the 90s supporting port-based firewalling ;) in Linux too later on, but honestly cant remember for what. Protecting the gateway of a wifi network? Cant remember. I also have a Linux bridge at home because of Apple multicast protocols )
    – Rui F Ribeiro
    Mar 15 at 14:17








1




1




(I implemented bridges in DOS and Cisco in the 90s supporting port-based firewalling ;) in Linux too later on, but honestly cant remember for what. Protecting the gateway of a wifi network? Cant remember. I also have a Linux bridge at home because of Apple multicast protocols )
– Rui F Ribeiro
Mar 15 at 14:17





(I implemented bridges in DOS and Cisco in the 90s supporting port-based firewalling ;) in Linux too later on, but honestly cant remember for what. Protecting the gateway of a wifi network? Cant remember. I also have a Linux bridge at home because of Apple multicast protocols )
– Rui F Ribeiro
Mar 15 at 14:17













up vote
-1
down vote













actually there is a small difference between the switch and hub.hub don't store the mac of connected devices,so the packets received from any host reaches every other connected hosts .Where as switch stores the mac of connected devices and send the packet to respective receiver whose details(like mac,ip) mentioned in packet headers....






share|improve this answer
















  • 2




    I don't think I understand what you mean I got wrong. To me, it seems like I described it similar to what you say. Also, I think this is not an anser to my question, but rather a comment (which I appreciate, btw). Also also, when talking about switches, it's usually implied that it is L2 switches, and they do not care about any packet header, only the frame header (so no IP).
    – lindhe
    Mar 15 at 20:00















up vote
-1
down vote













actually there is a small difference between the switch and hub.hub don't store the mac of connected devices,so the packets received from any host reaches every other connected hosts .Where as switch stores the mac of connected devices and send the packet to respective receiver whose details(like mac,ip) mentioned in packet headers....






share|improve this answer
















  • 2




    I don't think I understand what you mean I got wrong. To me, it seems like I described it similar to what you say. Also, I think this is not an anser to my question, but rather a comment (which I appreciate, btw). Also also, when talking about switches, it's usually implied that it is L2 switches, and they do not care about any packet header, only the frame header (so no IP).
    – lindhe
    Mar 15 at 20:00













up vote
-1
down vote










up vote
-1
down vote









actually there is a small difference between the switch and hub.hub don't store the mac of connected devices,so the packets received from any host reaches every other connected hosts .Where as switch stores the mac of connected devices and send the packet to respective receiver whose details(like mac,ip) mentioned in packet headers....






share|improve this answer












actually there is a small difference between the switch and hub.hub don't store the mac of connected devices,so the packets received from any host reaches every other connected hosts .Where as switch stores the mac of connected devices and send the packet to respective receiver whose details(like mac,ip) mentioned in packet headers....







share|improve this answer












share|improve this answer



share|improve this answer










answered Mar 15 at 15:30









saicharan

1




1







  • 2




    I don't think I understand what you mean I got wrong. To me, it seems like I described it similar to what you say. Also, I think this is not an anser to my question, but rather a comment (which I appreciate, btw). Also also, when talking about switches, it's usually implied that it is L2 switches, and they do not care about any packet header, only the frame header (so no IP).
    – lindhe
    Mar 15 at 20:00













  • 2




    I don't think I understand what you mean I got wrong. To me, it seems like I described it similar to what you say. Also, I think this is not an anser to my question, but rather a comment (which I appreciate, btw). Also also, when talking about switches, it's usually implied that it is L2 switches, and they do not care about any packet header, only the frame header (so no IP).
    – lindhe
    Mar 15 at 20:00








2




2




I don't think I understand what you mean I got wrong. To me, it seems like I described it similar to what you say. Also, I think this is not an anser to my question, but rather a comment (which I appreciate, btw). Also also, when talking about switches, it's usually implied that it is L2 switches, and they do not care about any packet header, only the frame header (so no IP).
– lindhe
Mar 15 at 20:00





I don't think I understand what you mean I got wrong. To me, it seems like I described it similar to what you say. Also, I think this is not an anser to my question, but rather a comment (which I appreciate, btw). Also also, when talking about switches, it's usually implied that it is L2 switches, and they do not care about any packet header, only the frame header (so no IP).
– lindhe
Mar 15 at 20:00













 

draft saved


draft discarded


























 


draft saved


draft discarded














StackExchange.ready(
function ()
StackExchange.openid.initPostLogin('.new-post-login', 'https%3a%2f%2funix.stackexchange.com%2fquestions%2f430407%2fare-bridges-like-hubs-or-switches%23new-answer', 'question_page');

);

Post as a guest













































































Popular posts from this blog

How to check contact read email or not when send email to Individual?

Bahrain

Postfix configuration issue with fips on centos 7; mailgun relay