Switch
Switch is an intelligent device.
As soon as switch receives a frame on its port switch will check its mac address, refer
mac table and take forwarding decision. because mac address is a layer 2 address, mac
table is a layer 2 table. hence switch is a layer 2 device.
Upon receiving a frame on its port, switch will open layer 2 information, check
destination mac address, refer mac table and forward the frame to relevant port only and
not to all other ports, whereas hub will forward it to all other ports. Switch segments the
network, Hub extends the network.
Because switch refers mac table to take forwarding decision. Hence, mac table must be
populated with mac addresses.
Mac addresses can be populated in two ways:
1. Administrator can make static mac entries in switches mac table.
2. Switch can self learn mac addresses when a frame traverses the switch.
Because switch does self-learning of mac addresses. Mac table size can become huge
Huge MAC table has 3 issues:
1. High memory utilization;
2. High CPU utilization;
3. Frame Forwarding delay
To overcome these issues following solutions were created:
1. cisco defined a limit of 4096 mac entries in mac table.
2. Any mac entry in mac table that is not sending frame in 5 mins will be considered as
stale and removed from mac table.
Switch creates multiple copies of broadcast frame received on a port and forward it to all
other ports.
L2 switch is a technology device that facilitate communication and does not participate
in communication, devices that do not participate in communication cannot broadcast.
Hence on L2 switch we do not configure IP/MAC address.
VLAN 1 is default VLAN, Management VLAN.
Switch 1
On L2 switch, we cannot configure IP addresses on ports but we can configure IP
addresses on VLAN 1 using following command.
int vlan 1
ip address 10.0.0.100 255.255.255.0
This IP is management IP used for telnet purpose only.
Operations
1. When switch receive a broadcast frame on its port, then switch will create multiple
copies of the frame and forward it to all other ports but not on the same port.
2. If sender and receiver are on the same port then switch will discard the frame. Switch
switches between the port not within the port.
3. If switch receives a frame whose destination mac is not known then switch will create
multiple copies of the frame and forward it to all other ports. which means that switch
will create multiple copies in two scenarios :
a. When it receives a broadcast frame.
b. When it receives a frame whose destination mac address is not known then it will
create multiple copies of such frame and forward it to all other ports.
4. If sender and receiver are on different port then switch will bridge the information to
relevant ports only and not to all other ports. Whereas hub will forward it to all ports.
5. Switch allows simultaneous communication between multiple communication pairs
connected on different ports. Switch works exactly as per CSMA/CD fundamental but
with the help of intelligent hardware it eliminates the flaw of CSMA/CD which is also a
software.
6. Every port of a Switch has its own dedicated bandwidth. Switch is a dedicated bandwidth
device.
7. Every port of Hub shares the same bandwidth. Hub is a shared bandwidth device.
8. Every port of a Switch is a member of separate collision domain. Switch is a multiple
collision domain device.
9. Every port of a Switch is a member of same broadcast domain. Switch is a single
broadcast domain device.
Switch 2
Switch 3