SWITCHING 
• Switch is a layer 2 Device 
• Two types of switches:- 
1. Manageable 
• Switches which has a console port 
• It is costly 
• Ex: Cisco catalyst 2950 
1. Non-manageable- 
• Switches which does not have console port 
• Less expensive 
• Ex: D-link, Net gear
FURTHER CLASSIFICATION 
1. Cut through 
 Cut through switch is one which has no error checking on incoming 
frame 
 Ex: Normal Switch 
2. Store and Forward 
 Store and forward has a buffer (small memory) in which the incoming 
frame is saved in it , checks the error and transmits
FUNCTIONS OF SWITCH 
• Address Learning 
• No entries are in MAC table initially 
• Each port broad cast to find its device for communication 
• The frame contains SMAC and source port no: 
• It is entered into the MAC table 
• After finding its device , the details are entered into the MAC table
• Forwarding 
• Forwarding is the process in which the frames are transferred according to 
MAC table 
• Loop avoidance 
• Two links are connected to two switches. 
• A loop occurs between the loops
STP (SPANNING TREE PROTOCOL) 
• Provides a loop-free redundant network topology by 
placing certain ports in the blocking state. 
• It is to avoid Looping in switches
BRIDGE ID 
• It is an address used to identify switches 
• It is a combination of priority value + MAC address 
• Ex: 32768:aa:bb:cc:dd
ROUTE BRIDGE 
• The highest priority switch among network of switch. 
• It controls the other ones. 
• Only one Route Bridge is in a network 
• The other switches are called non-Route Bridge
DESIGNATED PORT 
• The forwarding port of frame is called DP 
• All ports in Route Bridge are Designated ports 
• All ports in a non-Route Bridge are non- Designated ports
ROOT PORT 
• The ports in which designated and Non-Designated ports 
communicate.
STP OPERATION 
• BPDU (Bridge Protocol Data Unit), with the help of this packet, Root 
Bridge is elected. 
• The Root Bridge is elected with comparing Bridge ID and Root ID. 
• The lowest BPDU Root ID is the Root Bridge. 
• Initially BPDU packets are sent to all switches. 
• A Root Port is selected with the help of Path Cost. 
• The port in which Path cost having lowest value is the Root port.
SWITCH COMPONENTS 
• Processor 
• Motherboard 
• SMPS 
• RAM 
• NVRAM 
• FLASH 
• Switches typically have no power switch to turn them on and off. 
They simply connect or disconnect from a power source.
COMMAND LINE INTERFACE 
• The command line interface of switch is same as that of a Router 
• The Port interface is automatically assigned with IP and by default the 
status is up.
SWITCH PORT TYPES 
1. Trunk 
 A Switch to Switch connections are Trunk 
2. Access 
 PC- Switch connections are Access
SETTING ACCESS & TRUNK PORT 
Switch(config)#interface fastethernet 0/1 
Switch(config-if)#switchport mode access (For Access Port) 
Switch(config-if)#switchport mode trunk
PORT SECURITY 
Switch(config)#interface fastethernet 0/1 
Switch(config-if)#switchport mode access 
Switch(config-if)# switchport port-security 
Switch(config-if)#switchport port-security maximum 1 
Switch(config-if)# switchport port-security mac address sticky 
Switch(config-if)# switchport port-security violation shutdown 
Switch# show port-security (To Verify)
VLAN 
• Switch is a single broadcast domain 
• Converting a single broadcast domain into multiple broadcast 
domain is called Vlan. 
• It is a virtual LAN created in a switch. 
• Two types:- 
• 1- 1005 standard 
• 1006 – 4096 extended 
• All ports in a switch comes under Vlan 1 or administrative vlan by 
default (name default) 
• Mainly Vlan is implemented for logical grouping 
• A device under one Vlan area will not communicate with other Vlan 
area 
• Implements security
CREATING VLAN 
Switch(config)#vlan 100 
Switch(config-vlan)#name vlan100 
• Assigning a port to vlan:- 
Switch(config)#interface fastethernet 0/1 
Or 
Switch(config)#interface range fastethernet 0/1 – 10 
Switch(config-if)#switchport access vlan 100 
• To remove:- 
Switch(config)#no vlan 100 
Switch(config-if)#no switchport access vlan 100
ASSIGNING IP 
Switch(config)#interface vlan 100 
Switch(config-if)#ip address 192.168.1.1 255.255.255.0 
Switch(config-if)#no shut down
VLAN IDENTIFICATION OR FRAME 
TAGGING 
• Adding Vlan ID to each frame containing the details of destination 
Vlan ID is called Vlan Identification 
• Trunk port is used to connect two switch which passes multiple Vlan 
information 
• Access port is used to connect PC and switch which passes single 
Vlan information 
• Types:- 
• ISL (Interlink Switch)- Encapsulation method of CISCO 
• IEEE 802.1Q or dot1Q- Open support all switches
ROUTER ON STICK 
In Router:- 
Router(config)#interface fastethernet f0/0.1 
Router(config-if)#encapsulation dot1q 100 
Router(config-if)#ip address 10.0.0.1 255.0.0.0 
Router(config)#interface fastethernet f0/0.2 
Router(config-if)#encapsulation dot1q 200 
Router(config-if)#ip address 20.0.0.1 255.0.0.0 
Router(config)#interface fastethernet f0/0.3 
Router(config-if)#encapsulation dot1q 200 
Router(config-if)#ip address 30.0.0.1 255.0.0.0 
Router(config)#interface fastethernet f0/0 
Router(config-if)no shut down 
In Switch:- 
Switch(config)interface fastethernet 0/1 
Switch(config-if)switchport mode trunk 
Switch#show interface trunk
VTP (VLAN TRUNKING PROTOCOL) 
• VTP is used to create domain environment in a switching network 
• VTP modes:- 
• Server 
• Client 
• Transparent
• Cannot create, 
change, or delete 
VLANs 
• Forwards 
advertisements 
• Synchronizes 
VLAN 
configurations 
• Does not save in 
NVRAM 
• Creates, modifies, and deletes 
VLANs 
• Sends and forwards 
advertisements 
• Synchronizes VLAN 
configurations 
• Saves configuration in NVRAM 
• Creates, modifies, and 
deletes VLANs locally 
only 
• Forwards 
advertisements 
• Does not 
synchronize VLAN 
configurations 
• Saves configuration in 
NVRAM
VTP DOMAIN 
• VTP updates will not be received in switch which is having different 
domain name. 
• It receives when domain name is same 
Switch(config)#vtp domain NS (To create domain) 
Switch(config)#vtp mode ? (To change the VTP mode)
CONFIGURATION REVISION 
NUMBER 
• A switch having higher revision number database overwrites to 
another switch having lower revision number. 
• To avoid this we make the switch which has higher revision number 
into transparent mode.
VTP PRUNING MODE 
• This mode controls transferring unwanted updates from server to un 
manual switch.

CCNA ppt Day 8

  • 1.
    SWITCHING • Switchis a layer 2 Device • Two types of switches:- 1. Manageable • Switches which has a console port • It is costly • Ex: Cisco catalyst 2950 1. Non-manageable- • Switches which does not have console port • Less expensive • Ex: D-link, Net gear
  • 2.
    FURTHER CLASSIFICATION 1.Cut through  Cut through switch is one which has no error checking on incoming frame  Ex: Normal Switch 2. Store and Forward  Store and forward has a buffer (small memory) in which the incoming frame is saved in it , checks the error and transmits
  • 3.
    FUNCTIONS OF SWITCH • Address Learning • No entries are in MAC table initially • Each port broad cast to find its device for communication • The frame contains SMAC and source port no: • It is entered into the MAC table • After finding its device , the details are entered into the MAC table
  • 4.
    • Forwarding •Forwarding is the process in which the frames are transferred according to MAC table • Loop avoidance • Two links are connected to two switches. • A loop occurs between the loops
  • 5.
    STP (SPANNING TREEPROTOCOL) • Provides a loop-free redundant network topology by placing certain ports in the blocking state. • It is to avoid Looping in switches
  • 6.
    BRIDGE ID •It is an address used to identify switches • It is a combination of priority value + MAC address • Ex: 32768:aa:bb:cc:dd
  • 7.
    ROUTE BRIDGE •The highest priority switch among network of switch. • It controls the other ones. • Only one Route Bridge is in a network • The other switches are called non-Route Bridge
  • 8.
    DESIGNATED PORT •The forwarding port of frame is called DP • All ports in Route Bridge are Designated ports • All ports in a non-Route Bridge are non- Designated ports
  • 9.
    ROOT PORT •The ports in which designated and Non-Designated ports communicate.
  • 10.
    STP OPERATION •BPDU (Bridge Protocol Data Unit), with the help of this packet, Root Bridge is elected. • The Root Bridge is elected with comparing Bridge ID and Root ID. • The lowest BPDU Root ID is the Root Bridge. • Initially BPDU packets are sent to all switches. • A Root Port is selected with the help of Path Cost. • The port in which Path cost having lowest value is the Root port.
  • 11.
    SWITCH COMPONENTS •Processor • Motherboard • SMPS • RAM • NVRAM • FLASH • Switches typically have no power switch to turn them on and off. They simply connect or disconnect from a power source.
  • 12.
    COMMAND LINE INTERFACE • The command line interface of switch is same as that of a Router • The Port interface is automatically assigned with IP and by default the status is up.
  • 13.
    SWITCH PORT TYPES 1. Trunk  A Switch to Switch connections are Trunk 2. Access  PC- Switch connections are Access
  • 14.
    SETTING ACCESS &TRUNK PORT Switch(config)#interface fastethernet 0/1 Switch(config-if)#switchport mode access (For Access Port) Switch(config-if)#switchport mode trunk
  • 15.
    PORT SECURITY Switch(config)#interfacefastethernet 0/1 Switch(config-if)#switchport mode access Switch(config-if)# switchport port-security Switch(config-if)#switchport port-security maximum 1 Switch(config-if)# switchport port-security mac address sticky Switch(config-if)# switchport port-security violation shutdown Switch# show port-security (To Verify)
  • 16.
    VLAN • Switchis a single broadcast domain • Converting a single broadcast domain into multiple broadcast domain is called Vlan. • It is a virtual LAN created in a switch. • Two types:- • 1- 1005 standard • 1006 – 4096 extended • All ports in a switch comes under Vlan 1 or administrative vlan by default (name default) • Mainly Vlan is implemented for logical grouping • A device under one Vlan area will not communicate with other Vlan area • Implements security
  • 17.
    CREATING VLAN Switch(config)#vlan100 Switch(config-vlan)#name vlan100 • Assigning a port to vlan:- Switch(config)#interface fastethernet 0/1 Or Switch(config)#interface range fastethernet 0/1 – 10 Switch(config-if)#switchport access vlan 100 • To remove:- Switch(config)#no vlan 100 Switch(config-if)#no switchport access vlan 100
  • 18.
    ASSIGNING IP Switch(config)#interfacevlan 100 Switch(config-if)#ip address 192.168.1.1 255.255.255.0 Switch(config-if)#no shut down
  • 19.
    VLAN IDENTIFICATION ORFRAME TAGGING • Adding Vlan ID to each frame containing the details of destination Vlan ID is called Vlan Identification • Trunk port is used to connect two switch which passes multiple Vlan information • Access port is used to connect PC and switch which passes single Vlan information • Types:- • ISL (Interlink Switch)- Encapsulation method of CISCO • IEEE 802.1Q or dot1Q- Open support all switches
  • 20.
    ROUTER ON STICK In Router:- Router(config)#interface fastethernet f0/0.1 Router(config-if)#encapsulation dot1q 100 Router(config-if)#ip address 10.0.0.1 255.0.0.0 Router(config)#interface fastethernet f0/0.2 Router(config-if)#encapsulation dot1q 200 Router(config-if)#ip address 20.0.0.1 255.0.0.0 Router(config)#interface fastethernet f0/0.3 Router(config-if)#encapsulation dot1q 200 Router(config-if)#ip address 30.0.0.1 255.0.0.0 Router(config)#interface fastethernet f0/0 Router(config-if)no shut down In Switch:- Switch(config)interface fastethernet 0/1 Switch(config-if)switchport mode trunk Switch#show interface trunk
  • 21.
    VTP (VLAN TRUNKINGPROTOCOL) • VTP is used to create domain environment in a switching network • VTP modes:- • Server • Client • Transparent
  • 22.
    • Cannot create, change, or delete VLANs • Forwards advertisements • Synchronizes VLAN configurations • Does not save in NVRAM • Creates, modifies, and deletes VLANs • Sends and forwards advertisements • Synchronizes VLAN configurations • Saves configuration in NVRAM • Creates, modifies, and deletes VLANs locally only • Forwards advertisements • Does not synchronize VLAN configurations • Saves configuration in NVRAM
  • 23.
    VTP DOMAIN •VTP updates will not be received in switch which is having different domain name. • It receives when domain name is same Switch(config)#vtp domain NS (To create domain) Switch(config)#vtp mode ? (To change the VTP mode)
  • 24.
    CONFIGURATION REVISION NUMBER • A switch having higher revision number database overwrites to another switch having lower revision number. • To avoid this we make the switch which has higher revision number into transparent mode.
  • 25.
    VTP PRUNING MODE • This mode controls transferring unwanted updates from server to un manual switch.