Escolar Documentos
Profissional Documentos
Cultura Documentos
config t
hostname Router1
no ip domain-lookup
username Andrei password ccna
line con 0
logg sync
exec-timeout 0 0
line vty 0 4
login local
do wr
2. Adresare IP
#R1:
enable
config t
interface fa1/0
ip address 33.44.55.130 255.255.255.248
no shut
int se0/1
ip add 20.30.40.9 255.255.255.252
no shut
int se0/0
ip add 20.30.40.13 255.255.255.252
no shut
#R2
int se0/0
ip add 20.30.40.10 255.255.255.252
no shut
int fa0/0
ip add 20.30.40.2 255.255.255.248
no shut
#R3
int se0/0
ip add 20.30.40.14 255.255.255.252
no shut
int fa0/0
ip add 20.30.40.3 255.255.255.248
no shut
#R4
conf t
int fa0/1
ip add 192.168.0.25 255.255.255.240
no shut
int fa0/0.13
encapsulation dot1Q 13
ip add 192.168.0.3 255.255.255.240
no shut
int fa0/0.26
encapsulation dot1Q 26
ip add 192.168.0.11 255.255.255.240
no shut
int fa0/0.39
encapsulation dot1Q 39
ip add 192.168.0.19 255.255.255.240
no shut
int fa0/0
no shut
router ospf 1
router ospf 2
network 192.168.0.24 0.0.0.255 area 1
router ospf 1
#R1
router ospf 1
network 20.30.40.9 0.0.0.3 area 0
network 20.30.40.13 0.0.0.3 area 0
#R2
router ospf 1
network 20.30.40.10 0.0.0.3 area 0
network 20.30.40.0 0.0.0.7 area 0
#R3
router ospf 1
network 20.30.40.14 0.0.0.3 area 0
network 20.30.40.0 0.0.0.7 area 0
#R4
router ospf 1
network 20.30.40.0 0.0.0.7 area 0
3. DR/BDR
#R3
int fa0/0
ip ospf priority 255
#R4
router ospf 1
router-id 200.0.0.0
Pentru a forta realegerea DR/BDR, pe toate routerele se execut
do clear ip ospf process
4. Configurare PortChannel
#S1
interface range fa0/1-2
channel-group 1 mode passive
#S3
interface range fa0/1-2
channel-group 1 mode active
5. Configurare VLANs
#Pe toate routerele (inlocuibil cu VTP)
config t
vlan 11
exit
vlan 22
exit
vlan 33
exit
#Sw1
interface port-channel 1
switchport mode trunk
switchport trunk allowed vlan 11,22
interface fa0/3
switchport mode trunk
switchport trunk allowed vlan 11,22,33
interface fa0/24
switchport mode access
switchport access vlan 22
#Sw3
interface port-channel 1
switchport mode trunk
switchport trunk allowed vlan 11,22
interface fa0/3
switchport mode trunk
switchport trunk allowed vlan 11,22,33
interface fa0/24
switchport mode access
switchport access vlan 11
#Sw2
interface range fa 0/1 , fa 0/2 , fa0/23
switchport mode trunk
switchport trunk allowed vlan 11,22,33
interface fa0/24
switchport mode access
switchport access vlan 33
6. STP
#Sw1
spanning-tree vlan 33 root primary
#Sw2
spanning-tree vlan 11 root primary
#Sw3
spanning-tree vlan 22 root primary
#Pe toate
interface fa0/24
spanning-tree portfast
7. Conectivitate
#R4
router ospf 1
redistribute connected subnets
#R1
ip route 0.0.0.0 0.0.0.0 fa1/0
router ospf 1
default-information originate
originate
Enter OSPF router configuration mode:
1 R1(config)# router ospf 10 ! 10 = process ID
Configure one or more network commands to identify which interfaces will run OSP
F:
1
2
3 R1(config-router)# network 10.0.0.0 0.255.255.255 area 0
R1(config-router)# network 172.16.8.0 0.0.7.255 area 0
R1(config-router)# network 192.168.1.254 0.0.0.0 area 1
Configure router ID either (Optional):
Using router-id ospf subcommand:
1 R1(config-router)# router-id 1.1.1.1
Configuring an IP address on a loopback interface:
en
conf t
router ospf 1
network 10.10.10.0 0.0.0.7 area 1
auto-cost reference-bandwidth 1000
passive-interface gigabitEthernet 0/1
ip ospf hello-interval 4
ip ospf dead-interval 12
1
2 R1(config-if)# ip ospf authentication
R1(config-if)# ip ospf authentication-key cisco
Type 2 authentication (md5):
1
2 R1(config-if)# ip ospf authentication message-digest
R1(config-if)# ip ospf message-digest-key 1 md5 cisco
Configure maximum equal-cost paths (Optional):
1 R1(config-router)# maximum paths 6
en
write
en
conf t
router eigrp 1
no auto-summary
network 172.16.1.0 0.0.0.255
key chain 1