L7: VOIP


Voice over IP (VoIP) innebär att röstkommunikation skickas som IP-paket över ett datanät. Eftersom rösttrafik är realtidskänslig påverkas samtalskvaliteten direkt av fördröjning, jitter och paketförlust, vilket ställer särskilda krav på nätverksdesign.

I denna laboration bygger och konfigurerar vi ett distribuerat företagsnätverk med flera geografiska platser sammankopplade via WAN-länkar. Varje plats representeras av en router med tillhörande access-switch och är uppdelad i separata VLAN för DATA och VOICE.

I laborationen konfigureras:

  • VLAN och trunking för logisk segmentering
  • Router-on-a-Stick för inter-VLAN-routing
  • OSPF som dynamiskt routingprotokoll för all IP-trafik
  • Central DHCP-server för DATA-nät
  • Lokal DHCP på varje router för VOICE-nät
  • Cisco Unified CME för lokal IP-telefoni
  • Dial-peers (VoIP) för samtalsrouting mellan platser

Laborationen visar tydligt skillnaden mellan routing av datapaket via OSPF och routing av telefonsamtal via dial-peers. Fokus ligger på korrekt design, tydlig adressering, stabil routing och pedagogisk uppdelning mellan DATA- och VOICE-trafik.

Topologi

I laborationen används Cisco ISR 2800-serien (t.ex. 2811/2851), som kan fungera både som traditionell router och som voice gateway. Routrarna i denna serie har stöd för IP-telefoni genom Cisco Unified CME (CallManager Express). Detta innebär att routern kan köra kommandon som telephony-service, hantera ephone och ephone-dn, tillhandahålla DHCP-adresser till IP-telefoner samt routa telefonsamtal mellan nätverk med hjälp av VoIP dial-peers.

Tekniska principer och kommandon

Varje access-switch i nätverket använder ett DATA-VLAN, som är unikt för varje site, samt ett gemensamt VOICE-VLAN (VLAN 100). Uppdelningen mellan DATA och VOICE ger både logisk separation och bättre kontroll över trafiken i nätverket.

Trunkporten mellan switch och router är konfigurerad för att endast transportera de VLAN som faktiskt behövs på länken. Detta minskar onödig broadcast-trafik och följer etablerad best practice inom företagsnätverk.

Routern använder subinterfaces för inter-VLAN-routing (Router-on-a-Stick). Varje subinterface fungerar som default gateway för sitt VLAN och utgör samtidigt ett Layer-3-interface som används för routing och, i förekommande fall, DHCP relay.

DHCP-design

För DATA-nätet används en central DHCP-server som är placerad i ett separat Servers-nät. Eftersom klienterna befinner sig i andra VLAN används DHCP relay på routrarna. Detta uppnås genom kommandot ip helper-address, som vidarebefordrar DHCP-förfrågningar till serverns IP-adress (192.168.100.130).

För VOICE-nätet fungerar varje router som lokal DHCP-server. En separat DHCP-pool konfigureras för varje VOICE-subnät, där routerns VOICE-interface anges som default gateway. I DHCP-poolen används även option 150, som pekar ut routerns CME/TFTP-adress. Detta gör att IP-telefonerna automatiskt kan hitta rätt call-control-tjänst vid uppstart.

OSPF – dynamisk routing

OSPF används som dynamiskt routingprotokoll för all IP-trafik i nätverket, inklusive DATA-nät, VOICE-nät, servernät samt WAN-länkar mellan routrarna. Genom OSPF uppnås full IP-connectivity mellan alla platser utan behov av statiska routes.

LAN-interface mot switchar är konfigurerade som passive, vilket innebär att de annonseras i OSPF men inte skickar OSPF-hellos. Endast WAN-interface mellan routrar tillåts bilda OSPF-grannskap. På detta sätt sprids alla nät i routingtabellen samtidigt som onödig routingtrafik i access-näten undviks.

Cisco Unified CME

Varje router kör en lokal instans av Cisco Unified CallManager Express (CME). CME konfigureras med kommandot telephony-service och binds till routerns VOICE-interface med ip source-address. Routern fungerar därmed som call-control-enhet för sin sajt.

CME ansvarar för registrering av IP-telefoner samt för hantering av lokala samtal inom samma sajt, utan att trafiken behöver lämna den lokala routern.

Nummerplan

Varje sajte tilldelas ett eget nummerintervall för IP-telefoni. FINANCE använder numren 1001–1010, HR 2001–2010, SALES 3001–3010 och ICT 4001–4010. Denna konsekventa nummerplan gör det enkelt att identifiera var en anknytning hör hemma och förenklar både felsökning och samtalsrouting.

Dial-peers – samtalsrouting

För samtal mellan olika platser används VoIP dial-peers. En dial-peer matchar ett visst nummermönster med destination-pattern och anger vart samtalet ska skickas med session target.

Dial-peers behövs endast för externa nummer, det vill säga nummer som inte tillhör den lokala sajten. session target pekar på VOICE-VLAN:s default gateway på den mottagande routern, där CME-tjänsten är aktiv.

OSPF ansvarar för den underliggande IP-transporten mellan routrarna, medan dial-peers enbart styr samtalslogiken.

Separation mellan IP-routing och call routing

En central lärdom i laborationen är skillnaden mellan IP-routing och call routing. OSPF avgör hur IP-paket färdas genom nätverket, medan dial-peers avgör hur telefonsamtal kopplas och vart de ska skickas. Båda mekanismerna är nödvändiga för att uppnå fungerande IP-telefoni mellan olika platser.

Konfigurationer

FIN-SW konfiguration
  • FIN-SW(config)# no ip domain-lookup
  • ! ====== VLAN DATA och VOICE ======
  • FIN-SW(config)# vlan 10
  • FIN-SW(config-vlan)# name FIN-DATA
  • FIN-SW(config-vlan)# exit
  • FIN-SW(config)# vlan 100
  • FIN-SW(config-vlan)# name VOICE
  • FIN-SW(config-vlan)# exit
  • !===== Fa0/1-10: IP Phone + PC bakom telefon =======
  • FIN-SW(config)# interface range fa0/1 - 10
  • FIN-SW(config-if-range)# switchport mode access
  • FIN-SW(config-if-range)# switchport access vlan 10
  • FIN-SW(config-if-range)# switchport voice vlan 100
  • FIN-SW(config-if-range)# mls qos trust cos
  • FIN-SW(config-if-range)# spanning-tree portfast
  • FIN-SW(config-if-range)# spanning-tree bpduguard enable
  • FIN-SW(config-if-range)# exit
  • !==========> Trunk allowed vlan 10,100============
  • FIN-SW(config)# interface fa0/24
  • FIN-SW(config-if)# switchport mode trunk
  • FIN-SW(config-if)# switchport trunk allowed vlan 10,100
  • FIN-SW(config-if)# exit
  • FIN-SW(config)# end
  • FIN-SW# write memory
HR-SW konfiguration
  • HR-SW(config)# no ip domain-lookup
  • ! ====== VLAN DATA och VOICE ======
  • HR-SW(config)# vlan 20
  • HR-SW(config-vlan)# name HR-DATA
  • HR-SW(config-vlan)# exit
  • HR-SW(config)# vlan 100
  • HR-SW(config-vlan)# name VOICE
  • HR-SW(config-vlan)# exit
  • !===== Fa0/1-10: IP Phone + PC bakom telefon =======
  • HR-SW(config)# interface range fa0/1 - 10
  • HR-SW(config-if-range)# switchport mode access
  • HR-SW(config-if-range)# switchport access vlan 20
  • HR-SW(config-if-range)# switchport voice vlan 100
  • HR-SW(config-if-range)# mls qos trust cos
  • HR-SW(config-if-range)# spanning-tree portfast
  • HR-SW(config-if-range)# spanning-tree bpduguard enable
  • HR-SW(config-if-range)# exit
  • !==========> Trunk allowed vlan 20,100============
  • HR-SW(config)# interface fa0/24
  • HR-SW(config-if)# switchport mode trunk
  • HR-SW(config-if)# switchport trunk allowed vlan 20,100
  • HR-SW(config-if)# exit
  • HR-SW(config)# end
  • HR-SW# write memory
SA-SW konfiguration
  • SA-SW(config)# no ip domain-lookup
  • ! ====== VLAN DATA och VOICE ======
  • SA-SW(config)# vlan 30
  • SA-SW(config-vlan)# name SA-DATA
  • SA-SW(config-vlan)# exit
  • SA-SW(config)# vlan 100
  • SA-SW(config-vlan)# name VOICE
  • SA-SW(config-vlan)# exit
  • ! ====== Fa0/1-10: IP Phone + PC bakom telefon =====
  • SA-SW(config)# interface range fa0/1 - 10
  • SA-SW(config-if-range)# switchport mode access
  • SA-SW(config-if-range)# switchport access vlan 30
  • SA-SW(config-if-range)# switchport voice vlan 100
  • SA-SW(config-if-range)# mls qos trust cos
  • SA-SW(config-if-range)# spanning-tree portfast
  • SA-SW(config-if-range)# spanning-tree bpduguard enable
  • SA-SW(config-if-range)# exit
  • !====== Trunk allowed vlan 30,100 =========
  • SA-SW(config)# interface fa0/24
  • SA-SW(config-if)# switchport mode trunk
  • SA-SW(config-if)# switchport trunk allowed vlan 30,100
  • SA-SW(config-if)# exit
  • SA-SW(config)# end
  • SA-SW# write memory

ICT-SW konfiguration

  • ICT-SW(config)# no ip domain-lookup
  • ! ====== VLAN DATA och VOICE ======
  • ICT-SW(config)# vlan 40
  • ICT-SW(config-vlan)# name ICT-DATA
  • ICT-SW(config-vlan)# exit
  • ICT-SW(config)# vlan 100
  • ICT-SW(config-vlan)# name VOICE
  • ICT-SW(config-vlan)# exit
  • !===== Fa0/1-10: IP Phone + PC bakom telefon ======
  • ICT-SW(config)# interface range fa0/1 - 10
  • ICT-SW(config-if-range)# switchport mode access
  • ICT-SW(config-if-range)# switchport access vlan 40
  • ICT-SW(config-if-range)# switchport voice vlan 100
  • ICT-SW(config-if-range)# mls qos trust cos
  • ICT-SW(config-if-range)# spanning-tree portfast
  • ICT-SW(config-if-range)# spanning-tree bpduguard enable
  • ICT-SW(config-if-range)# exit
  • !========> Trunk allowed vlan 40,100========
  • ICT-SW(config)# interface fa0/24
  • ICT-SW(config-if)# switchport mode trunk
  • ICT-SW(config-if)# switchport trunk allowed vlan 40,100
  • ICT-SW(config-if)# exit
  • ICT-SW(config)# end
  • ICT-SW# write memory
SVR-SW konfiguration
  • SVR-SW(config)# no ip domain-lookup
  • ! ====== VLAN DATA  ======
  • SVR-SW(config)# vlan 50
  • SVR-SW(config-vlan)# name SVR-DATA
  • SVR-SW(config-vlan)# exit
  • !===== Fa0/1-10: IP Phone + PC bakom telefon =======
  • SVR-SW(config)# interface range fa0/1 - 10
  • SVR-SW(config-if-range)# switchport mode access
  • SVR-SW(config-if-range)# switchport access vlan 50
  • SVR-SW(config-if-range)# exit
  • !======> Trunk allowed vlan 10,100==========
  • SVR-SW(config)# interface fa0/24
  • SVR-SW(config-if)# switchport mode trunk
  • SVR-SW(config-if)# switchport trunk allowed vlan 50
  • SVR-SW(config-if)# exit
  • SVR-SW(config)# end
  • SVR-SW# write memory
FIN-RO konfiguration
  • FIN-RO(config)# no ip domain-lookup
  • !==================================================
    ! LAN mot FIN-SW – Router-on-a-Stick
    !==================================================
  • FIN-RO(config)# interface fa0/0
  • FIN-RO(config-if)# no shutdown
  • FIN-RO(config-if)# exit
  • FIN-RO(config)# interface fa0/0.10
  • FIN-RO(config-subif)# encapsulation dot1Q 10
  • FIN-RO(config-subif)# ip address 192.168.100.1 255.255.255.224
  • FIN-RO(config-subif)# ip helper-address 192.168.100.130
  • FIN-RO(config-subif)#exit
  • FIN-RO(config)# interface fa0/0.100
  • FIN-RO(config-subif)# encapsulation dot1Q 100
  • FIN-RO(config-subif)# ip address 172.16.100.1 255.255.255.224
  • FIN-RO(config-subif)# exit
  • !==================================================
    ! DHCP – VOICE
    !==================================================
  • FIN-RO(config)# ip dhcp excluded-address 172.16.100.1 172.16.100.5
  • FIN-RO(config)# ip dhcp pool FIN-VOICE
  • FIN-RO(config-dhcp)# network 172.16.100.0 255.255.255.224
  • FIN-RO(config-dhcp)# default-router 172.16.100.1
  • FIN-RO(config-dhcp)# option 150 ip 172.16.100.1
  • FIN-RO(config-dhcp)# exit
  • !==================================================
    ! Cisco Unified CME
    !==================================================
  • FIN-RO(config)# telephony-service
  • FIN-RO(config-telephony)# max-ephones 10
  • FIN-RO(config-telephony)# max-dn 10
  • FIN-RO(config-telephony)# ip source-address 172.16.100.1 port 2000
  • FIN-RO(config-telephony)# auto assign 1 to 10
  • FIN-RO(config-telephony)# create cnf-files
  • FIN-RO(config-telephony)# exit
  • !==================================================
    ! ephone-dn – FIN nummerplan (1001–1010)
    !==================================================
  • FIN-RO(config)# ephone-dn 1
  • FIN-RO(config-ephone)# number 1001
  • FIN-RO(config-ephone)# exit
  • FIN-RO(config)# ephone-dn 2
  • FIN-RO(config-ephone)# number 1002
  • FIN-RO(config-ephone)# exit
  • FIN-RO(config)# ephone-dn 3
  • FIN-RO(config-ephone)# number 1003
  • FIN-RO(config-ephone)# exit
  • FIN-RO(config)# ephone-dn 4
  • FIN-RO(config)# number 1004
  • FIN-RO(config-ephone)# exit
  • FIN-RO(config)# ephone-dn 5
  • FIN-RO(config-ephone)# number 1005
  • FIN-RO(config-ephone)# exit
  • FIN-RO(config)# ephone-dn 6
  • FIN-RO(config-ephone)# number 1006
  • FIN-RO(config-ephone)# exit
  • FIN-RO(config)# ephone-dn 7
  • FIN-RO(config-ephone)# number 1007
  • FIN-RO(config-ephone)# exit
  • FIN-RO(config)# ephone-dn 8
  • FIN-RO(config-ephone)# number 1008
  • FIN-RO(config-ephone)# exit
  • FIN-RO(config)# ephone-dn 9
  • FIN-RO(config-ephone)# number 1009
  • FIN-RO(config-ephone)# exit
  • FIN-RO(config)# ephone-dn 10
  • FIN-RO(config-ephone)# number 1010
  • FIN-RO(config-ephone)# exit
  • !==================================================
    ! WAN-länkar
    !==================================================
  • ! ====== WAN mot ICT-RO ======
  • FIN-RO(config)# interface s0/0/0
  • FIN-RO(config-if)# description DCE WAN link to ICT-RO
  • FIN-RO(config-if)# clock rate 2000000
  • FIN-RO(config-if)# ip address 10.10.10.5 255.255.255.252
  • FIN-RO(config-if)# no shutdown
  • FIN-RO(config-if)# exit
  • ! ====== WAN mot HR-RO ======
  • FIN-RO(config)# interface s0/0/1
  • FIN-RO(config-if)# description DCE WAN link to HR-RO
  • FIN-RO(config-if)# clock rate 2000000
  • FIN-RO(config-if)# ip address 10.10.10.1 255.255.255.252
  • FIN-RO(config-if)# no shutdown
  • FIN-RO(config-if)# exit
  • !==================================================
    ! OSPF – Dynamisk routing
    !==================================================
  • FIN-RO(config)# router ospf 110
  • FIN-RO(config-router)# router-id 1.1.1.1
  • FIN-RO(config-router)# passive-interface fa0/0
  • FIN-RO(config-router)# network 10.10.10.0 0.0.0.3 area 0
  • FIN-RO(config-router)# network 10.10.10.4 0.0.0.3 area 0
  • FIN-RO(config-router)# network 172.16.100.0 0.0.0.31 area 0
  • FIN-RO(config-router)# network 192.168.100.0 0.0.0.31 area 0
  • FIN-RO(config-router)# exit
  • FIN-RO(config)# end
  • FIN-RO# write memory
  • !==================================================
    ! VoIP-routing – Dial-peers
    !==================================================
  • FIN-RO# configure terminal
  • FIN-RO(config)# dial-peer voice 12 voip
  • FIN-RO(config-dial-peer)# destination-pattern 2...
  • FIN-RO(config-dial-peer)# session target ipv4:172.16.100.33
  • FIN-RO(config-dial-peer)# exit
  • FIN-RO(config)#dial-peer voice 13 voip
  • FIN-RO(config-dial-peer)# destination-pattern 3...
  • FIN-RO(config-dial-peer)# session target ipv4:172.16.100.65
  • FIN-RO(config-dial-peer)# exit
  • FIN-RO(config)# dial-peer voice 14 voip
  • FIN-RO(config-dial-peer)# destination-pattern 4...
  • FIN-RO(config-dial-peer)# session target ipv4:172.16.100.97
  • FIN-RO(config-dial-peer)# exit
  • FIN-RO(config)# end
  • FIN-RO# write memory
HR-RO konfiguration
  • HR-RO(config)# no ip domain-lookup
  • !==================================================
    ! LAN mot HR-SW – Router-on-a-Stick
    !==================================================
  • HR-RO(config)# interface fa0/0
  • HR-RO(config-if)# no shutdown
  • HR-RO(config-if)# exit
  • HR-RO(config)# interface fa0/0.20
  • HR-RO(config-subif)# encapsulation dot1Q 20
  • HR-RO(config-subif)# ip address 192.168.100.33 255.255.255.224
  • HR-RO(config-subif)# ip helper-address 192.168.100.130
  • HR-RO(config-subif)# exit
  • HR-RO(config)# interface fa0/0.100
  • HR-RO(config-subif)# encapsulation dot1Q 100
  • HR-RO(config-subif)# ip address 172.16.100.33 255.255.255.224
  • HR-RO(config-subif)# exit
  • !==================================================
    ! DHCP – VOICE
    !==================================================
  • HR-RO(config)# ip dhcp excluded-address 172.16.100.33 172.16.100.35
  • !
  • HR-RO(config)# ip dhcp pool HR-VOICE
  • HR-RO(config-dhcp)# network 172.16.100.32 255.255.255.224
  • HR-RO(config-dhcp)# default-router 172.16.100.33
  • HR-RO(config-dhcp)# option 150 ip 172.16.100.33
  • HR-RO(config-dhcp)# exit
  • !==================================================
    ! Cisco Unified CME
    !==================================================
  • HR-RO(config)# telephony-service
  • HR-RO(config-telephony)# max-ephones 10
  • HR-RO(config-telephony)# max-dn 10
  • HR-RO(config-telephony)# ip source-address 172.16.100.33 port 2000
  • HR-RO(config-telephony)# auto assign 1 to 10
  • HR-RO(config-telephony)# create cnf-files
  • HR-RO(config-telephony)# exit
  • !==================================================
    ! ephone-dn – HR nummerplan (2001–2010)
    !==================================================
  • HR-RO(config)# ephone-dn 1
  • HR-RO(config-ephone)# number 2001
  • HR-RO(config-ephone)# exit
  • HR-RO(config)# ephone-dn 2
  • HR-RO(config-ephone)# number 2002
  • HR-RO(config-ephone)# exit
  • HR-RO(config)# ephone-dn 3
  • HR-RO(config-ephone)# number 2003
  • HR-RO(config-ephone)# exit
  • HR-RO(config)# ephone-dn 4
  • HR-RO(config-ephone)# number 2004
  • HR-RO(config-ephone)# exit
  • HR-RO(config)# ephone-dn 5
  • HR-RO(config-ephone)# number 2005
  • HR-RO(config-ephone)# exit
  • HR-RO(config-ephone)# ephone-dn 6
  • HR-RO(config-ephone)# number 2006
  • HR-RO(config-ephone)# exit
  • HR-RO(config)# ephone-dn 7
  • HR-RO(config-ephone)# number 2007
  • HR-RO(config-ephone)# exit
  • HR-RO(config)# ephone-dn 8
  • HR-RO(config-ephone)# number 2008
  • HR-RO(config-ephone)# exit
  • HR-RO(config)# ephone-dn 9
  • HR-RO(config-ephone)# number 2009
  • HR-RO(config-ephone)# exit
  • HR-RO(config)# ephone-dn 10
  • HR-RO(config-ephone)# number 2010
  • HR-RO(config-ephone)# exit
  • !==================================================
    ! WAN-länkar
    !==================================================
  • ! ====== WAN mot SA-RO ======
  • HR-RO(config)# interface s0/0/0
  • HR-RO(config-if)# description WAN link to SA-RO
  • HR-RO(config-if)# ip address 10.10.10.9 255.255.255.252
  • HR-RO(config-if)# no shutdown
  • HR-RO(config-if)# exit
  • ! ====== WAN mot FIN-RO ======
  • HR-RO(config)# interface s0/0/1
  • HR-RO(config-if)# description WAN link to FIN-RO
  • HR-RO(config-if)# ip address 10.10.10.2 255.255.255.252
  • HR-RO(config-if)# no shutdown
  • HR-RO(config-if)# exit
  • !==================================================
    ! OSPF – Dynamisk routing
    !==================================================
  • HR-RO(config)# router ospf 110
  • HR-RO(config-if)# router-id 2.2.2.2
  • HR-RO(config-if)# passive-interface fa0/0
  • HR-RO(config-if)# network 10.10.10.0 0.0.0.3 area 0
  • HR-RO(config-if)# network 10.10.10.8 0.0.0.3 area 0
  • HR-RO(config-if)# network 172.16.100.32 0.0.0.31 area 0
  • HR-RO(config-if)# network 192.168.100.32 0.0.0.31 area 0
  • HR-RO(config-if)# exit
  • HR-RO(config)# end
  • HR-RO# write memory
  • !==================================================
    ! VoIP-routing – Dial-peers
    !==================================================
  • HR-RO> enable
  • HR-RO# configure terminal
  • HR-RO(config)# dial-peer voice 21 voip
  • HR-RO(config-dial-peer)# destination-pattern 1...
  • HR-RO(config-dial-peer)# session target ipv4:172.16.100.1
  • HR-RO(config-dial-peer)# exit
  • !
  • HR-RO(config)# dial-peer voice 23 voip
  • HR-RO(config-dial-peer)# destination-pattern 3...
  • HR-RO(config-dial-peer)# session target ipv4:172.16.100.65
  • HR-RO(config-dial-peer)# exit
  • !
  • HR-RO(config)# dial-peer voice 24 voip
  • HR-RO(config-dial-peer)# destination-pattern 4...
  • HR-RO(config-dial-peer)# session target ipv4:172.16.100.97
  • HR-RO(config-dial-peer)# exit
  • !
  • HR-RO(config)# end
  • HR-RO# write memory
SA-RO konfiguration
  • SA-RO(config)# no ip domain-lookup
  • !==================================================
    ! LAN mot SA-SW – Router-on-a-Stick
    !==================================================
  • SA-RO(config)# interface fa0/0
  • SA-RO(config-if)# no shutdown
  • SA-RO(config-if)# exit
  • SA-RO(config-)# interface fa0/0.30
  • SA-RO(config-subif)# encapsulation dot1Q 30
  • SA-RO(config-subif)# ip address 192.168.100.65 255.255.255.224
  • SA-RO(config-subif)# ip helper-address 192.168.100.130
  • SA-RO(config-subif)# exit
  • SA-RO(config)# interface fa0/0.100
  • SA-RO(config-subif)# encapsulation dot1Q 100
  • SA-RO(config-subif)# ip address 172.16.100.65 255.255.255.224
  • SA-RO(config-subif)# exit
  • !==================================================
    ! DHCP – VOICE
    !==================================================
  • SA-RO(config)# ip dhcp excluded-address 172.16.100.65 172.16.100.67
  • !
  • SA-RO(config-dhcp)# ip dhcp pool SA-VOICE
  • SA-RO(config-dhcp)# network 172.16.100.64 255.255.255.224
  • SA-RO(config-dhcp)# default-router 172.16.100.65
  • SA-RO(config-dhcp)# option 150 ip 172.16.100.65
  • SA-RO(config-dhcp)# exit
  • !==================================================
    ! Cisco Unified CME
    !==================================================
  • SA-RO(config)# telephony-service
  • SA-RO(config-telephony)# max-ephones 10
  • SA-RO(config-telephony)# max-dn 10
  • SA-RO(config-telephony)# ip source-address 172.16.100.65 port 2000
  • SA-RO(config-telephony)# auto assign 1 to 10
  • SA-RO(config-telephony)# create cnf-files
  • SA-RO(config-telephony)# exit
  • !==================================================
    ! ephone-dn – SA nummerplan (3001–3010)
    !==================================================
  • SA-RO(config)# ephone-dn 1
  • SA-RO(config-ephone)# number 3001
  • SA-RO(config-ephone)# exit
  • SA-RO(config)# ephone-dn 2
  • SA-RO(config-ephone)# number 3002
  • SA-RO(config-ephone)# exit
  • SA-RO(config)# ephone-dn 3
  • SA-RO(config-ephone)# number 3003
  • SA-RO(config-ephone)# exit
  • SA-RO(config)# ephone-dn 4
  • SA-RO(config-ephone)# number 3004
  • SA-RO(config-ephone)# exit
  • SA-RO(config)# ephone-dn 5
  • SA-RO(config-ephone)# number 3005
  • SA-RO(config-ephone)# exit
  • SA-RO(config)# ephone-dn 6
  • SA-RO(config-ephone)# number 3006
  • SA-RO(config-ephone)# exit
  • SA-RO(config)# ephone-dn 7
  • SA-RO(config-ephone)# number 3007
  • SA-RO(config-ephone)# exit
  • SA-RO(config)# ephone-dn 8
  • SA-RO(config-ephone)# number 3008
  • SA-RO(config-ephone)# exit
  • SA-RO(config)# ephone-dn 9
  • SA-RO(config-ephone)# number 3009
  • SA-RO(config-ephone)# exit
  • SA-RO(config)# ephone-dn 10
  • SA-RO(config-ephone)# number 3010
  • SA-RO(config-ephone)# exit
  • !==================================================
    ! WAN-länkar
    !==================================================
  • ! ====== WAN mot HR-RO ======
  • SA-RO(config)# interface s0/0/0
  • SA-RO(config-if)# description DCE WAN link to HR-RO
  • SA-RO(config-if)# clock rate 2000000
  • SA-RO(config-if)# ip address 10.10.10.10 255.255.255.252
  • SA-RO(config-if)# no shutdown
  • SA-RO(config-if)# exit
  • ! ====== WAN mot ICT-RO ======
  • SA-RO(config)# interface s0/0/1
  • SA-RO(config-if)# description DCE WAN link to ICT-RO
  • SA-RO(config-if)# clock rate 2000000
  • SA-RO(config-if)# ip address 10.10.10.13 255.255.255.252
  • SA-RO(config-if)# no shutdown
  • SA-RO(config-if)# exit
  • !==================================================
    ! OSPF – Dynamisk routing
    !==================================================
  • SA-RO(config)# router ospf 110
  • SA-RO(config-router)# router-id 3.3.3.3
  • SA-RO(config-router)# passive-interface fa0/0
  • SA-RO(config-router)# network 10.10.10.8 0.0.0.3 area 0
  • SA-RO(config-router)# network 10.10.10.12 0.0.0.3 area 0
  • SA-RO(config-router)# network 172.16.100.64 0.0.0.31 area 0
  • SA-RO(config-router)# network 192.168.100.64 0.0.0.31 area 0
  • SA-RO(config-router)# exit
  • SA-RO(config)# end
  • SA-RO# write memory
  • !==================================================
    ! VoIP-routing – Dial-peers
    !==================================================
  • SA-RO> enable
  • SA-RO(config)# configure terminal
  • SA-RO(config)# dial-peer voice 31 voip
  • SA-RO(config-dial-peer)# destination-pattern 1...
  • SA-RO(config-dial-peer)# session target ipv4:172.16.100.1
  • SA-RO(config-dial-peer)# exit
  • !
  • SA-RO(config)# dial-peer voice 32 voip
  • SA-RO(config-dial-peer)# destination-pattern 2...
  • SA-RO(config-dial-peer)# session target ipv4:172.16.100.33
  • SA-RO(config-dial-peer)# exit
  • !
  • SA-RO(config)# dial-peer voice 34 voip
  • SA-RO(config-dial-peer)# destination-pattern 4...
  • SA-RO(config-dial-peer)# session target ipv4:172.16.100.97
  • SA-RO(config-dial-peer)# exit
  • SA-RO(config)# end
  • SA-RO# write memory
ICT-RO konfiguration
  • ICT-RO(config)# no ip domain-lookup
  • !==================================================
    ! LAN mot ICT-SW – Router-on-a-Stick (VLAN 40 + 100)
    !==================================================
  • ICT-RO(config)# interface fa0/0
  • ICT-RO(config-if)# no shutdown
  • ICT-RO(config-if)# exit
  • ICT-RO(config)# interface fa0/0.40
  • ICT-RO(config-subif)# encapsulation dot1Q 40
  • ICT-RO(config-subif)# ip address 192.168.100.97 255.255.255.224
  • ICT-RO(config-subif)# ip helper-address 192.168.100.130
  • ICT-RO(config-subif)# exit
  • ICT-RO(config)# interface fa0/0.100
  • ICT-RO(config-subif)# encapsulation dot1Q 100
  • ICT-RO(config-subif)# ip address 172.16.100.97 255.255.255.224
  • ICT-RO(config-subif)# exit
  • !==================================================
    ! LAN mot SRV-SW – Router-on-a-Stick (VLAN 50 Servers)
    !==================================================
  • ICT-RO(config)# interface fa0/1
  • ICT-RO(config-if)# no shutdown
  • ICT-RO(config-if)# exit
  • ICT-RO(config)# interface fa0/1.50
  • ICT-RO(config-subif)# encapsulation dot1q 50
  • ICT-RO(config-subif)# ip address 192.168.100.129 255.255.255.248
  • ICT-RO(config-subif)# exit
  • !==================================================
    ! DHCP – VOICE
    !==================================================
  • ICT-RO(config)# ip dhcp excluded-address 172.16.100.97 172.16.100.99
  • !
  • ICT-RO(config)# ip dhcp pool ICT-VOICE
  • ICT-RO(config-dhcp)# network 172.16.100.96 255.255.255.224
  • ICT-RO(config-dhcp)# default-router 172.16.100.97
  • ICT-RO(config-dhcp)# option 150 ip 172.16.100.97
  • ICT-RO(config-dhcp)# exit
  • !==================================================
    ! Cisco Unified CME
    !==================================================
  • ICT-RO(config)# telephony-service
  • ICT-RO(config-telephony)# max-ephones 10
  • ICT-RO(config-telephony)# max-dn 10
  • ICT-RO(config-telephony)# ip source-address 172.16.100.97 port 2000
  • ICT-RO(config-telephony)# auto assign 1 to 10
  • ICT-RO(config-telephony)# create cnf-files
  • ICT-RO(config-telephony)# exit
  • !==================================================
    ! ephone-dn – ICT nummerplan (4001–4010)
    !==================================================
  • ICT-RO(config-ephone)# ephone-dn 1
  • ICT-RO(config-ephone)# number 4001
  • ICT-RO(config-ephone)# exit
  • ICT-RO(config)# ephone-dn 2
  • ICT-RO(config-ephone)# number 4002
  • ICT-RO(config-ephone)# exit
  • ICT-RO(config)# ephone-dn 3
  • ICT-RO(config-ephone)# number 4003
  • ICT-RO(config-ephone)# exit
  • ICT-RO(config)# ephone-dn 4
  • ICT-RO(config-ephone)# number 4004
  • ICT-RO(config-ephone)# exit
  • ICT-RO(config)# ephone-dn 5
  • ICT-RO(config-ephone)# number 4005
  • ICT-RO(config-ephone)# exit
  • ICT-RO(config)# ephone-dn 6
  • ICT-RO(config-ephone)# number 4006
  • ICT-RO(config-ephone)# exit
  • ICT-RO(config)# ephone-dn 7
  • ICT-RO(config-ephone)# number 4007
  • ICT-RO(config-ephone)# exit
  • ICT-RO(config)# ephone-dn 8
  • ICT-RO(config-ephone)# number 4008
  • ICT-RO(config-ephone)# exit
  • ICT-RO(config)# ephone-dn 9
  • ICT-RO(config-ephone)# number 4009
  • ICT-RO(config-ephone)# exit
  • ICT-RO(config)# ephone-dn 10
  • ICT-RO(config-ephone)# number 4010
  • ICT-RO(config-ephone)# exit
  • !==================================================
    ! WAN-länkar
    !==================================================
  • ! ====== WAN mot FIN-RO ======
  • ICT-RO(config)# interface s0/0/0
  • ICT-RO(config-if)# description WAN link to FIN-RO
  • ICT-RO(config-if)# ip address 10.10.10.6 255.255.255.252
  • ICT-RO(config-if)# no shutdown
  • ICT-RO(config-if)# exit
  • ! ====== WAN mot SA-RO ======
  • ICT-RO(config)# interface s0/0/1
  • ICT-RO(config-if)# description WAN link to SA-RO
  • ICT-RO(config-if)# ip address 10.10.10.14 255.255.255.252
  • ICT-RO(config-if)# no shutdown
  • ICT-RO(config-if)# exit
  • !==================================================
    ! OSPF – Dynamisk routing
    !==================================================
  • ICT-RO(config)# router ospf 110
  • ICT-RO(config-router)# router-id 4.4.4.4
  • ICT-RO(config-router)# passive-interface fa0/0
  • ICT-RO(config-router)# passive-interface fa0/1
  • ICT-RO(config-router)# network 10.10.10.4 0.0.0.3 area 0
  • ICT-RO(config-router)# network 10.10.10.12 0.0.0.3 area 0
  • ICT-RO(config-router)# network 172.16.100.96 0.0.0.31 area 0
  • ICT-RO(config-router)# network 192.168.100.96 0.0.0.31 area 0
  • ICT-RO(config-router)# network 192.168.100.128 0.0.0.7 area 0
  • ICT-RO(config-router)# exit
  • ICT-RO(config)# end
  • ICT-RO# write memory
  • !==================================================
    ! VoIP-routing – Dial-peers
    !==================================================
  • ICT-RO> enable
  • ICT-RO# configure terminal
  • ICT-RO(config)# dial-peer voice 41 voip
  • ICT-RO(config-dial-peer)# destination-pattern 1...
  • ICT-RO(config-dial-peer)# session target ipv4:172.16.100.1
  • ICT-RO(config-dial-peer)# exit
  • !
  • ICT-RO(config)# dial-peer voice 42 voip
  • ICT-RO(config-dial-peer)# destination-pattern 2...
  • ICT-RO(config-dial-peer)# session target ipv4:172.16.100.33
  • ICT-RO(config-dial-peer)# exit
  • !
  • ICT-RO(config)# dial-peer voice 43 voip
  • ICT-RO(config-dial-peer)# destination-pattern 3...
  • ICT-RO(config-dial-peer)# session target ipv4:172.16.100.65
  • ICT-RO(config-dial-peer)# exit
  • ICT-RO(config)#end
  • ICT-RO# write memory