A6: Nätverkstyper – WAN 1

WAN är ett nätverk som ansluter ihop olika lokala nätverk (LAN), det stora exemplet på ett WAN nätverk är Internet. På Internet överför vi filer från ett LAN till ett annat, vi kommunicerar med andra oavsett avståndet tack vare flera olika protokoll och serverapplikationer såsom DHCP, DNS, SMTP, POP, FTP, HTTP och HTTPS mm.

I denna PTA kopplas två LAN ihop så ett WAN-nätverk utformas. Till vänster av topologin placerades ett LAN som består av tre delnät, alla anslutna till router R1 via TP-kablar (representeras med raka linjer i topologin). Till höger av topologin har vi också ett liknande LAN. Mellan routrarna R1 och R2 används en seriell kabel (röda linjer utformat som liggande blixt) vilket medför en annan typ av nätverksteknologi som inte tas upp här i kursen. Seriellkommunikation kräver synkronisering och därför router R1 får rollen som DCE eller Data Communication Equipment och R2 rollen DTE.

PTA 6 bygger på genomgången om OSI och TCP/IP kommunikationsmodeller med fokus i Applikationsskiktet och Nätverksskiktet där specificeras IP-adressering, statisk routing.

Topologi

Enhet Int IP-adress Nätmask DG DNS
PC1 Fa0 172.16.0.10 255.255.252.0 172.16.0.1 172.16.8.5
PC2 Fa0 172.16.4.10 255.255.252.0 172.16.4.1 172.16.8.5
PC3 Fa0 172.16.8.10 255.255.252.0 172.16.8.1 172.16.8.5
dns1 Fa0 172.16.8.5 255.255.252.0 172.16.8.1 172.16.8.5
NPC1 Fa0 172.31.0.10 255.255.252.0 172.31.0.1 172.31.8.5
NPC2 Fa0 172.31.4.10 255.255.252.0 172.31.4.1 172.31.8.5
NPC3 Fa0 172.31.8.10 255.255.252.0 172.31.8.1 172.31.8.5
nns1 Fa0/ 172.31.8.5 255.255.252.0 172.31.8.1 172.31.8.5
R1 Gig0/0 172.16.0.1 255.255.252.0
Gig0/1 172.16.4.1 255.255.252.0
Gig0/2 172.16.8.1 255.255.252.0
R2 Gig0/0 172.31.0.1 255.255.252.0
Gig0/1 172.31.4.1 255.255.252.0
Gig0/2 172.31.8.1 255.255.252.0

Instruktioner

  1. 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 DSW1
    • DSW1(config)# no ip domain-lookup
    • DSW1(config)# service password-encryption
    • DSW1(config)# enable secret ensecP@55
    • DSW1(config)# line console 0
    • DSW1(config-line)# password consoP@55
    • DSW1(config-line)# login
    • DSW1(config-line)# logging synchronous
    • DSW1(config-line)# exit
    • DSW1(config)# line vty 0 4
    • DSW1(config-line)# password vtyliP@55
    • DSW1(config-line)# login
    • DSW1(config-line)# logging synchronous
    • DSW1(config-line)# exit
    • DSW1(config)# banner motd ”This is a secure system. Authorized Access Only!”
    • DSW1(config)# exit
    • DSW1# show running-config
    • DSW1# copy running-config startup-config
  2. IP-adressering. I enlighet med tabellen ovan anges ett exempel här nedan:
    • R1# configure terminal
    • R1(config)# interface Gig0/0
    • R1(config-if)# description Connected to LAN 172.16.0.0 /22
    • R1(config-if)# ip address 172.16.0.1 255.255.252.0
    • R1(config-if)# no shutdown
    • R1(config-if)# exit
    • R1(config)# interface Gig0/1
    • R1(config-if)# description Connected to LAN 172.16.4.0 /22
    • R1(config-if)# ip address 172.16.4.1 255.255.252.0
    • R1(config-if)# no shutdown
    • R1(config-if)# exit
    • R1(config)# interface Gig0/2
    • R1(config-if)# description Connected to LAN 172.16.8.0 /22
    • R1(config-if)# ip address 172.16.8.1 255.255.252.0
    • R1(config-if)# no shutdown
    • R1(config-if)# exit
    • R1(config)# interface s0/0/0
    • R1(config-if)# description DCE Connected to R2 NG
    • R1(config-if)# clock rate 2000000
    • R1(config-if)# ip address 221.2.0.1 255.255.255.252
    • R1(config-if)# no shutdown
    • R1(config-if)# exit
    • R1(config)#  
  3. Konfigurera R1 som DHCP server
    • R1# configure terminal
    • R1(config)# ip dhcp excluded-address 172.16.0.1 172.16.0.10
    • R1(config)# ip dhcp excluded-address 172.16.4.1 172.16.4.10
    • R1(config)# ip dhcp excluded-address 172.16.8.1 172.16.8.10
    • R1(config)# ip dhcp pool DSW1pool
    • R1(dhcp-config)# network 172.16.0.0 255.255.252.0
    • R1(dhcp-config)# default-router 172.16.0.1
    • R1(dhcp-config)# dns-server 172.16.8.5
    • R1(dhcp-config)# domain-name diginto.se
    • R1(dhcp-config)# exit
    • R1(config)# ip dhcp pool DSW2pool
    • R1(dhcp-config)# network 172.16.4.0 255.255.252.0
    • R1(dhcp-config)# default-router 172.16.4.1
    • R1(dhcp-config)# dns-server 172.16.8.5
    • R1(dhcp-config)# domain-name diginto.se
    • R1(dhcp-config)# exit
    • R1(config)# ip dhcp pool DSW3pool
    • R1(dhcp-config)# network 172.16.8.0 255.255.252.0
    • R1(dhcp-config)# default-router 172.16.8.1
    • R1(dhcp-config)# dns-server 172.16.8.5
    • R1(dhcp-config)# domain-name diginto.se
    • R1(dhcp-config)# exit
    • R1(config)#
  4. Konfigurera statisk routing på router R1
    • R1(config)# ip route 172.31.0.0 255.255.252.0 221.2.0.2
    • R1(config)# ip route 172.31.4.0 255.255.252.0 221.2.0.2
    • R1(config)# ip route 172.31.8.0 255.255.252.0 221.2.0.2
    • R1(config)# exit
    • R1# show ip interface brief
    • R1# copy running-config startup-config 
  5. IP-adressera alla PC i enlighet med tabellen.
  6. IP-adressera servrarna och konfigurera nätverkstjänster DNS samt HTTP (skapa en egen hemsida för domänerna DIGINTO och NG.
  7. Verifieringar. Här ska verifieras att IP-kommunikation fungerar, annars i felsökning kan användas olika kommando:
    • från PC exekvera kommando ipconfig, ipconfig /all, ping, tracert <host-IP>
    • 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!