Vlan Base:
The role of VLANs: Put physically segmented users, and let them logically together.
Vlan Range: 0-4095
0 4095 is reserved and cannot be used
1 Cisco Credit VLAN
Standard VLAN 1-1005
Extended VLAN 1006-4094 is established and deleted only in global configuration command mode. Will not be transferred by VTP except for VTP v3
Vlan Establishment of:
The effect is the same in both ways:
First:
switch#
Switch#vlan database//Enter VLAN database mode
Switch (VLAN) #vlan 2 name vlan2//Build VLAN 2 named "vlan2" name is only locally valid
VLAN 2 added:
Name:vlan2
Switch (VLAN) #vlan 3 name Vlan3
VLAN 3 added:
Name:vlan3
Switch (VLAN) #exit
APPLY completed.
Exiting ....
switch#
Second:
Switch (config) #
Switch (config) #vlan 2//Build VLAN in global command mode 2
Switch (Config-vlan) #name vlan2//named "Vlan2" is valid locally
Switch (Config-vlan) #exi
Switch (config) #
interface Join VLAN (Make VLAN function):
Switch (config) #int F0/1
Switch (CONFIG-IF) #switchport mode access//Make switch interface mode into Access mode
Switch (config-if) #switchport access VLAN 2//Add interface to VLAN 2
Switch (config-if) #exit
One interface can only join one VLAN
Configuration Summary for VLANs:
- Building VLANs
- Interface joins VLAN
To view VLAN information: Show VLAN Brief
Trunk
Trunks are links that are used to transmit multiple VLAN information.
Trunk Package Standard:
- Dot1q public, is to insert information (VLAN number) in the data frame
- ISL Cisco Private, which is the encapsulation of the data frame
Trunk Configuration
Switch (config) #int F0/1
Switch (config-if) #switchport trunk Encapsulation dot1q//trunk package for dot1q standard
Switch (config-if) #switchport mode trunk//interface mode for trunk
DTP (Trunk transport protocol, used to dynamically negotiate a trunk):
One end configuration: The other end is configured
Mode trunk trunk,auto.desirable link can Chilai into trunk
Mode dynamic Auto Trunk,desirable link can Chilai into trunk
mode dynamic desirable trunk,auto,desirable link can Chilai into trunk
Link needs to be trunk, but DTP is turned off
Switch (config-if) #switchport mode trunk
Switch (config-if) #switchport nonegotiate
Configuration steps for VLAN under LAN:
1. Trunk between switches
2. All switches establish the same VLAN, (VTP)
3. Each switch strokes the interface into the appropriate VLAN
4. Configuring Layer 3 Information (IP)
Vtp
VTP is used to unify the creation and deletion of VLAN information.
VTP3 mode:
Server: Can add, remove VLANs, learn VLAN information, transmit VLAN information to other people
Client: Can not add, delete VLAN, can learn VLAN information from server, pass the learning information to others
Transparent: You can only add and delete your own VLAN information. Do not learn VLAN information from server, can pass VLAN information learned from server to other people
VTP configuration:
Link between switches requires trunk configuration
Switch#vlan Database
Switch (VLAN) #vtp domain CCNA//Set VTP for a device under the same domain name to learn
Switch (VLAN) #vtp server//Set VTP mode to server
Device mode already VTP SERVER.
Switch (VLAN) #exit
APPLY completed.
Exiting ....
Or
Switch (config) #vtp domain CCNA
Switch (config) #vtp mode server
Single-Arm routing configuration:
1. Switch-to-router link, switch-side trunk
2. Router-side:
int f0/0
No IP Add//physical port does not configure IP address
No sh
Exit
int f0/0.1//Establish sub-interface, 1 to connect the opening mark
En do 2//traffic that hosts VLAN 2
IP Add xx.xx.xx.xx
Exit
int f0/0.x//can establish multiple sub-interfaces
The 3.PC terminal needs to configure the gateway, the gateway address is
The IP address of the VLAN sub-interface where you are located
Stp
Role:
1. Make a physically ring topology so that it is logically non-circular.
2. Dynamic Backup
STP communicates through BPDUs which interface is chosen by block.
STP Standard:
802.1D Standard STP CSTP convergence time 50s
802.1W Fast STP RSTP to complete convergence in 1s
802.1s Multi-instance STP MSTP
CISCO:PVSTP each VLAN has its own one STP
Ssh
Configuration by SSH Manager:
R1 (config) #username aa password AA//Set user name and password for administrator login
R1 (config) #hostname R1
R1 (config) #ip domain name ccxx.com
R1 (config) #crypto key generate RSA//Open SSH generate key
R1 (config) #line vty 0 4//Open vty Line
R1 (config-line) #login Local//Login method
R1 (Config-line) #end
Landed by:
R2#ssh–l AA 1.1.1.1//R2 ssh using username "AA" Login 1.1.1.1
CCNA Course IV