I denna PTA ska konfigureras exemplet i lektionen om CIDR och VLSM. Aktiviteten bygger på genomgången om Classless IP-adressering, Cisco IOS kommando och statisk routing.
Topologi
IP adressering
Enhet | Int | IP-adress | Nätmask | DG | DNS |
---|---|---|---|---|---|
hqns1 | Fa0 | 172.16.0.5 | 255.255.254.0 | 172.16.0.1 | 172.16.0.5 |
HQLT1 | Fa0 | DHCP | 255.255.254.0 | 172.16.0.1 | 172.16.0.5 |
HQLPC1 | Fa0 | DHCP | 255.255.254.0 | 172.16.0.1 | 172.16.0.5 |
HQLPT1 | Fa0 | DHCP | 255.255.254.0 | 172.16.0.1 | 172.16.0.5 |
sans1 | Fa0 | 172.16.2.5 | 255.255.255.0 | 172.16.2.1 | 172.16.2.5 |
SALT1 | Fa0 | DHCP | 255.255.255.0 | 172.16.2.1 | 172.16.2.5 |
SAPC1 | Fa0 | DHCP | 255.255.255.0 | 172.16.2.1 | 172.16.2.5 |
SALPT1 | Fa0 | DHCP | 255.255.255.0 | 172.16.2.1 | 172.16.2.5 |
hrns1 | Fa0 | 172.16.3.5 | 255.255.255.192 | 172.16.3.1 | 172.16.3.5 |
HRLT1 | Fa0 | DHCP | 255.255.255.192 | 172.16.3.1 | 172.16.3.5 |
HRPC1 | Fa0 | DHCP | 255.255.255.192 | 172.16.3.1 | 172.16.3.5 |
HRLTP1 | Fa0 | DHCP | 255.255.255.192 | 172.16.3.1 | 172.16.3.5 |
lens1 | Fa0 | 172.16.3.70 | 255.255.255.224 | 172.16.3.65 | 172.16.3.70 |
LEPC1 | Fa0 | DHCP | 255.255.255.224 | 172.16.3.65 | 172.16.3.70 |
LELPT1 | Fa0 | DHCP | 255.255.255.224 | 172.16.3.65 | 172.16.3.70 |
HQ | Gig0/1 | 172.16.0.1 | 255.255.254.0 | ||
Se0/0/0 | 172.16.3.97 | 255.255.255.252 | |||
Se0/0/1 | 172.16.3.101 | 255.255.255.252 | |||
Se0/1/0 | 172.16.3.105 | 255.255.255.252 | |||
SALES | Gig0/1 | 172.16.0.1 | 255.255.255.0 | ||
Se0/0/1 | 172.16.0.102 | 255.255.255.252 | |||
HR | Gig0/1 | 172.16.3.1 | 255.255.255.192 | ||
Se0/0/0 | 172.16.3.98 | 255.255.255.252 | |||
LEGAL | Gig0/2 | 172.16.3.65 | 255.255.255.224 | ||
Se0/0/0 | 172.16.3.106 | 255.255.255.252 |
Instruktioner
- Grundkonfigurationer på switchar och routrar (hostname, no ip domain-lookup, enable secret, console 0, vty 0 4, login, logging synchronous, och banner. Här nedan anges ett exempel:
- Switch> enable
- Switch# configure terminal
- Switch(config)# hostname HQSW1
- HQSW1(config)# no ip domain-lookup
- HQSW1(config)# service password-encryption
- HQSW1(config)# enable secret ensecP@55
- HQSW1(config)# line console 0
- HQSW1(config-line)# password consoP@55
- HQSW1(config-line)# login
- HQSW1(config-line)# logging synchronous
- HQSW1(config-line)# exit
- HQSW1(config)# line vty 0 4
- HQSW1(config-line)# password vtyliP@55
- HQSW1(config-line)# login
- HQSW1(config-line)# logging synchronous
- HQSW1(config-line)# exit
- HQSW1(config)# banner motd ”This is a secure system. Authorized Access Only!”
- HQSW1(config)# exit
- HQSW1# show running-config
- HQSW1# copy running-config startup-config
- Router konfigurering. Grundkonfigurationer och IP-adressering. I enlighet med tabellen ovan anges ett exempel här nedan:
- HQ# configure terminal
- HQ(config)# interface Gig0/1
- HQ(config-if)# description Connected to LAN HQ
- HQ(config-if)# ip address 172.16.0.1 255.255.254.0
- HQ(config-if)# no shutdown
- HQ(config-if)# exit
- Q(config)# interface s0/0/0
- HQ(config-if)# description DCE Connected to router HR
- HQ(config-if)# clock rate 2000000
- HQ(config-if)# ip address 172.16.3.97 255.255.255.252
- HQ(config-if)# no shutdown
- HQ(config-if)# exit
- Q(config)# interface s0/0/1
- HQ(config-if)# description DCE Connected to router SALES
- HQ(config-if)# clock rate 2000000
- HQ(config-if)# ip address 172.16.3.101 255.255.255.252
- HQ(config-if)# no shutdown
- HQ(config-if)# exit
- HQ(config)# interface s0/1/0
- HQ(config-if)# description DCE Connected to router LEGAL
- HQ(config-if)# clock rate 2000000
- HQ(config-if)# ip address 172.16.3.105 255.255.255.252
- HQ(config-if)# no shutdown
- HQ(config-if)# exit
- IP routing på HQ router
- HQ(config)# ip route 172.16.2.0 255.255.255.0 172.16.3.102
- HQ(config)# ip route 172.16.3.0 255.255.255.192 172.16.3.98
- HQ(config)# ip route 172.16.3.64 255.255.255.224 172.16.3.106
- HQ(config)# exit
- HQ# show ip interface brief
- HQ# show ip route static
- HQ# copy running-config startup-config
- IP routing på HR, SALES och LEGAL routrar
- HR(config)# ip route 0.0.0.0 0.0.0.0 172.16.3.97
- SALES(config)# ip route 0.0.0.0 0.0.0.0 172.16.3.101
- LEGAL(config)# ip route 0.0.0.0 0.0.0.0 172.16.3.105
- Verifiera konfigurationer på alla fyra routrar med kommandon
- Router# show ip interface brief
- Router# show ip route static
- Router# show running-config
- Spara konfigurationer med kommando
- Router# copy running-config startup-config
- IP-adressera alla servrar enligt tabellen IP adressering
- Konfigurera DNS server och dess poster:
- hqns1.hq.com NS 172.16.0.5
- hqns1.hq.com A 172.16.0.5
- www.hq.com A 172.16.0.5
- www.sales.hq.com A 172.16.2.5
- www.hr.hq.com A 172.16.3.5
- www.legalhq.com A 172.16.3.70
- Konfigurera hemsidor på alla HTTP-servrar (teckenstorlek 8 och ändra rubriken HQ, HR, SALES, LEGAL)
- Konfigurera DHCP servrar enligt tabellen nedan:
Pool Name | DG | DNS | Start IP | SM | Max Users |
---|---|---|---|---|---|
HQpool | 172.16.0.1 | 172.16.0.5 | 172.16.0.10 | 255.255.254.0 | 500 |
SApool | 172.16.2.1 | 172.16.2.5 | 172.16.2.10 | 255.255.255.0 | 200 |
HRpool | 172.16.3.1 | 172.16.3.5 | 172.16.3.10 | 255.255.255.192 | 50 |
LEpool | 172.16.3.65 | 172.16.3.70 | 172.16.3.71 | 255.255.255.224 | 20 |
- IP-adressera via DHCP alla PC i enlighet med tabellen ovan
- IP-adressera skrivaren med en statik IP-adress (exkluderas från DHCP Pool i alla servrar)
- Verifieringar. Här ska verifieras att IP-kommunikation och DNS samt HTTP fungerar, annars i felsökning kan användas olika kommando:
- från PC exekvera kommando ipconfig, ipconfig /all, ping, tracert <host-IP>, nslookup
- på router exekvera kommando show ip route static, ping och tracer (inte tracert)
- i fall du vill ta bort felaktiga konfigureringar använd det magiska ordet no, till exempel Router(config-if)#no ip address 172.165.0.1 255.255.252.0 eller
Router(config)# no ip route 172.165.0.0 255.0.0.0
Labben klar!