In this article we will learn about a hardware "Switch"


👀

But first lets jump for basics⚡



=>  A network switch has many ports and we can connect different computers to different ports.


⚡So switch is used to communicate between these connnected computers.⚡

switch basically rembers that which port is connected to which MAC Address





⚡⚡👀⚡⚡
(MAC Address:- Everyone should be knowing it!👀

But still
its a physical address of a device (its not a network property)

And every device has it! Dosent matter if the device os connected to a network or not!
 Now as you guys know...
Our main aim is to go to the in depth working and cleaeing the concepts...

Lets dive in🙂
👀

👀
Now the main thing is to study

 HOW DOES THE SWITCH STORES THE MAC ADDRESS AND FEW MORE THINGS

Now the main point to be noted is that the switch will never add itself the mac address of the devices connected to its ports
 instead it will keep on adding it as the data flow starts.....
 To understand it better lets take a real life example

⚡A Switch has its own LOOK UP table
 (in this table switch stores all the mac address of computers which are connected to its correponding ports!) 🙂


Now talking about the LOOK UP table....
Thats how it looks like...⚡

Currently the table is empty...  And you will soon understand why🙂



We will understand the concept with a real life flowing example
 So at the very beginning  we have connected few computers to a switch
now we power up the switch...⚡⚡⚡



⚡Now at the very beginning the LOOK UP table of the switch is empty!
 (there is nothing stored in it and infact the switch will itsef not try to fill it up itself

 like it will not write it down itself that which port is connected to which MAC address.👀


What it will do is just wait................. it will keep on waiting until)
Until any connected devices tries to send something to any other connected device🙂
Now a realastic example to replicate whatever will go on now........


Computer 1, 2 , 3, 4 are connected to the switch

Computer 1 wants to send some data to computer 3
👀
 So comp.1   will prepare a ethernet frame (people who are new to networking can consider it a simple data packet)

Ethernet frame basically consists of
= MAC address of sender
= MAC address of the computer to whom it is sending data
= The data which is being sent



👀
so what happenes is ..... switch takes the ethernet frame.

UPDATE ITS LOOK UP TABLE (ENTERS THAT PORT 1 IS CONNECTED TO MAC ADDRESS (THE MAC ADDRESS OF SENDER))
👀

👀⚡👀
 Now a very important term is to be introduced

FLOODING:-
 But still it dosent know to whom the packet needs to be sent because the recievers port and recievers mac address is not updated in the look uo table

 So switch sends that data to all the connected devices
 This is known as FLOODING


 now as the data was for comp.3.................. comp.3 will send a responce for it to comp.1
👀⚡👀
 Now in this responce the comp.3 will prepare its ethernet frame and sends to the switch

👀👀

Now from that ethernet frame the switch will again update its lookup table and adds the port and mac addrress of  comp.3



But in this case switch knows that the data is being sent to comp.1
and to which port is comp.1 connceted
as it is already present in the look up table

so this time the data will directly go to comp.1
And this process will not undergo any flooding  🙂


💎 Thats the working of a Switch guys!💎

Read it carefully⚡

Understand the working⚡

If you have any Doubs, Queries,Confusion reguarding this concept... Or article or any images shown..

Do ask!
Never build up misconceptions🙂💛


-INNOVATIVE NOOBS