Friday, 23 November 2012

Basic Switch Configuration

Configure Switch hostname as SWITCH1
hostname SWITCH1

Configure the message of the day as "LAB SWITCH Unauthorized access is forbidden"
banner motd #
LAB SWITCH Unauthorized access is forbidden#

Configure the password for privileged mode access as "cisco". The password must be md5 encrypted
enable secret cisco

Configure password encryption on the switch using the global configuration command
service password-encryption

Configure CONSOLE access
line con 0
password ciscoswitch
logging synchronous
login
history size 15
exec-timeout 6 45

Configure TELNET access
line vty 0 15
exec-timeout 8 20
password ciscotelnet
logging synchronous
login
history size 15

Configure the IP address of the switch as 192.168.1.2/24 and it's default gateway IP (192.168.1.1).
interface Vlan1
ip address 192.168.1.2 255.255.255.0
ip default-gateway 192.168.1.1


configure each Switch1 fastethernet switchport for operation.
Switch(config)#interface FastEthernet0/1
switchport mode access
duplex full
speed 100
Switch(config)#interface FastEthernet0/2
switchport mode access
duplex full
speed 100
Switch(config)#interface FastEthernet0/3
switchport mode access
duplex full
speed 100
Switch(config)#interface FastEthernet0/4
switchport mode access
duplex full
speed 100

PC "192.168.1.4" seems to be unable to ping other PCs in the network. Check switch configuration.
Switch(config)#interface FastEthernet0/4
Switch(config-if)#switchport mode access
Switch(config-if)#switchport access vlan 1



Choose the right cable to connect :
- Switch0 gigabitethernet 1/1 to Switch1 gigabitethernet 1/1
- Switch1 gigabitethernet 1/2 to Switch2 gigabitethernet 1/2

Packet Tracer 5.3 - Switch interfaces configuration lab solution

Configure those two links as trunk lines without using trunk negotiation between switches
On every interface that has to be configured for trunk operation, configure the following settings
Switch(config)#interface GigabitEthernet1/X
Switch(config-if)#switchport mode trunk

Verify interface operational mode using the "show interface GigabitEthernet1/X switchport command" :
Name: Gig1/2
Switchport: Enabled
Administrative Mode: trunk
Operational Mode: trunk
Administrative Trunking Encapsulation: dot1q
Operational Trunking Encapsulation: dot1q
Negotiation of Trunking: On
Access Mode VLAN: 1 (default)
Trunking Native Mode VLAN: 1 (default)
Voice VLAN: none


Another usefull ios command is "show interfaces trunk" :
Switch#sh interfaces trunk
Port        Mode         Encapsulation  Status        Native vlan
Gig1/2      on           802.1q         trunking      1

Port        Vlans allowed on trunk
Gig1/2      1-1005

Port        Vlans allowed and active in management domain
Gig1/2      1

Port        Vlans in spanning tree forwarding state and not pruned
Gig1/2      1

No comments:

Post a Comment