Vi bruker små nette dingser for å kunne gjøre dette billig men lærerikt. Hver deltager bruker en https://routerboard.com/RB941-2nD-TC
«Sentral» router er også en mikrotik router, Vi bruker en slik https://routerboard.com/RB2011iLS-IN , men det er ikke så viktig hva slags device som brukes der.
Konfigurasjon på «sentral router»:
# apr/03/2017 15:49:07 by RouterOS 6.38.5 # software id = 9ZQJ-BZN6 # /interface vlan add interface=ether5 name=vlan99 vlan-id=99 add interface=ether5 name=vlan100 vlan-id=100 add interface=ether5 name=vlan101 vlan-id=101 add interface=ether5 name=vlan102 vlan-id=102 add interface=ether5 name=vlan103 vlan-id=103 add interface=ether5 name=vlan104 vlan-id=104 add interface=ether5 name=vlan105 vlan-id=105 add interface=ether5 name=vlan106 vlan-id=106 add interface=ether5 name=vlan107 vlan-id=107 add interface=ether5 name=vlan108 vlan-id=108 add interface=ether5 name=vlan109 vlan-id=109 add interface=ether5 name=vlan110 vlan-id=110 add interface=ether5 name=vlan111 vlan-id=111 add interface=ether5 name=vlan112 vlan-id=112 add interface=ether5 name=vlan113 vlan-id=113 add interface=ether5 name=vlan114 vlan-id=114 add interface=ether5 name=vlan115 vlan-id=115 add interface=ether5 name=vlan116 vlan-id=116 /ip pool add name=pool100 ranges=192.168.90.2 add name=pool101 ranges=192.168.90.6 add name=pool102 ranges=192.168.90.10 add name=pool103 ranges=192.168.90.14 add name=pool104 ranges=192.168.90.18 add name=pool105 ranges=192.168.90.22 add name=pool106 ranges=192.168.90.26 add name=pool107 ranges=192.168.90.30 add name=pool108 ranges=192.168.90.34 add name=pool109 ranges=192.168.90.38 add name=pool110 ranges=192.168.90.42 add name=pool111 ranges=192.168.90.46 add name=pool112 ranges=192.168.90.50 add name=pool113 ranges=192.168.90.54 add name=pool114 ranges=192.168.90.58 add name=pool115 ranges=192.168.90.62 add name=pool116 ranges=192.168.90.66 /ip dhcp-server add address-pool=pool100 authoritative=yes disabled=no interface=vlan100 \ lease-time=1h name=server100 add address-pool=pool101 authoritative=yes disabled=no interface=vlan101 \ lease-time=1h name=server101 add address-pool=pool102 authoritative=yes disabled=no interface=vlan102 \ lease-time=1h name=server102 add address-pool=pool103 authoritative=yes disabled=no interface=vlan103 \ lease-time=1h name=server103 add address-pool=pool104 authoritative=yes disabled=no interface=vlan104 \ lease-time=1h name=server104 add address-pool=pool105 authoritative=yes disabled=no interface=vlan105 \ lease-time=1h name=server105 add address-pool=pool106 authoritative=yes disabled=no interface=vlan106 \ lease-time=1h name=server106 add address-pool=pool107 authoritative=yes disabled=no interface=vlan107 \ lease-time=1h name=server107 add address-pool=pool108 authoritative=yes disabled=no interface=vlan108 \ lease-time=1h name=server108 add address-pool=pool109 authoritative=yes disabled=no interface=vlan109 \ lease-time=1h name=server109 add address-pool=pool110 authoritative=yes disabled=no interface=vlan110 \ lease-time=1h name=server110 add address-pool=pool111 authoritative=yes disabled=no interface=vlan111 \ lease-time=1h name=server111 add address-pool=pool112 authoritative=yes disabled=no interface=vlan112 \ lease-time=1h name=server112 add address-pool=pool113 authoritative=yes disabled=no interface=vlan113 \ lease-time=1h name=server113 add address-pool=pool114 authoritative=yes disabled=no interface=vlan114 \ lease-time=1h name=server114 add address-pool=pool115 authoritative=yes disabled=no interface=vlan115 \ lease-time=1h name=server115 add address-pool=pool116 authoritative=yes disabled=no interface=vlan116 \ lease-time=1h name=server116 /routing ospf instance set [ find default=yes ] router-id=192.168.99.1 /ip address add address=172.16.4.250/24 interface=ether5 network=172.16.4.0 add address=192.168.90.1/30 interface=vlan100 network=192.168.90.0 add address=192.168.90.5/30 interface=vlan101 network=192.168.90.4 add address=192.168.90.9/30 interface=vlan102 network=192.168.90.8 add address=192.168.90.13/30 interface=vlan103 network=192.168.90.12 add address=192.168.90.17/30 interface=vlan104 network=192.168.90.16 add address=192.168.90.21/30 interface=vlan105 network=192.168.90.20 add address=192.168.90.25/30 interface=vlan106 network=192.168.90.24 add address=192.168.90.29/30 interface=vlan107 network=192.168.90.28 add address=192.168.90.33/30 interface=vlan108 network=192.168.90.32 add address=192.168.90.37/30 interface=vlan109 network=192.168.90.36 add address=192.168.90.41/30 interface=vlan110 network=192.168.90.40 add address=192.168.90.45/30 interface=vlan111 network=192.168.90.44 add address=192.168.90.49/30 interface=vlan112 network=192.168.90.48 add address=192.168.90.53/30 interface=vlan113 network=192.168.90.52 add address=192.168.90.57/30 interface=vlan114 network=192.168.90.56 add address=192.168.90.61/30 interface=vlan115 network=192.168.90.60 add address=192.168.90.65/30 interface=vlan116 network=192.168.90.64 add address=192.168.99.1/24 interface=vlan99 network=192.168.99.0 /ip dhcp-server network add address=192.168.90.0/30 dns-server=192.168.99.10 domain=ao-test.com \ gateway=192.168.90.1 netmask=30 ntp-server=91.205.185.94,188.94.222.237 add address=192.168.90.4/30 dns-server=192.168.99.10 domain=ao-test.com \ gateway=192.168.90.5 netmask=30 ntp-server=91.205.185.94,188.94.222.237 add address=192.168.90.8/30 dns-server=192.168.99.10 domain=ao-test.com \ gateway=192.168.90.9 netmask=30 ntp-server=91.205.185.94,188.94.222.237 add address=192.168.90.12/30 dns-server=192.168.99.10 domain=ao-test.com \ gateway=192.168.90.13 netmask=30 ntp-server=91.205.185.94,188.94.222.237 add address=192.168.90.16/30 dns-server=192.168.99.10 domain=ao-test.com \ gateway=192.168.90.17 netmask=30 ntp-server=91.205.185.94,188.94.222.237 add address=192.168.90.20/30 dns-server=192.168.99.10 domain=ao-test.com \ gateway=192.168.90.21 netmask=30 ntp-server=91.205.185.94,188.94.222.237 add address=192.168.90.24/30 dns-server=192.168.99.10 domain=ao-test.com \ gateway=192.168.90.25 netmask=30 ntp-server=91.205.185.94,188.94.222.237 add address=192.168.90.28/30 dns-server=192.168.99.10 domain=ao-test.com \ gateway=192.168.90.29 netmask=30 ntp-server=91.205.185.94,188.94.222.237 add address=192.168.90.32/30 dns-server=192.168.99.10 domain=ao-test.com \ gateway=192.168.90.33 netmask=30 ntp-server=91.205.185.94,188.94.222.237 add address=192.168.90.36/30 dns-server=192.168.99.10 domain=ao-test.com \ gateway=192.168.90.37 netmask=30 ntp-server=91.205.185.94,188.94.222.237 add address=192.168.90.40/30 dns-server=192.168.99.10 domain=ao-test.com \ gateway=192.168.90.41 netmask=30 ntp-server=91.205.185.94,188.94.222.237 add address=192.168.90.44/30 dns-server=192.168.99.10 domain=ao-test.com \ gateway=192.168.90.45 netmask=30 ntp-server=91.205.185.94,188.94.222.237 add address=192.168.90.48/30 dns-server=192.168.99.10 domain=ao-test.com \ gateway=192.168.90.49 netmask=30 ntp-server=91.205.185.94,188.94.222.237 add address=192.168.90.52/30 dns-server=192.168.99.10 domain=ao-test.com \ gateway=192.168.90.53 netmask=30 ntp-server=91.205.185.94,188.94.222.237 add address=192.168.90.56/30 dns-server=192.168.99.10 domain=ao-test.com \ gateway=192.168.90.57 netmask=30 ntp-server=91.205.185.94,188.94.222.237 add address=192.168.90.60/30 dns-server=192.168.99.10 domain=ao-test.com \ gateway=192.168.90.61 netmask=30 ntp-server=91.205.185.94,188.94.222.237 add address=192.168.90.64/30 dns-server=192.168.99.10 domain=ao-test.com \ gateway=192.168.90.65 netmask=30 ntp-server=91.205.185.94,188.94.222.237 /ip dns set servers=172.16.4.19 /ip firewall nat add action=masquerade chain=srcnat out-interface=ether5 /ip route add distance=1 gateway=172.16.4.254 add disabled=yes distance=1 dst-address=192.168.100.0/24 gateway=192.168.90.2 add disabled=yes distance=1 dst-address=192.168.101.0/24 gateway=192.168.90.6 add disabled=yes distance=1 dst-address=192.168.102.0/24 gateway=\ 192.168.90.10 add disabled=yes distance=1 dst-address=192.168.103.0/24 gateway=\ 192.168.90.14 add disabled=yes distance=1 dst-address=192.168.104.0/24 gateway=\ 192.168.90.18 add disabled=yes distance=1 dst-address=192.168.105.0/24 gateway=\ 192.168.90.22 add disabled=yes distance=1 dst-address=192.168.106.0/24 gateway=\ 192.168.90.26 add disabled=yes distance=1 dst-address=192.168.107.0/24 gateway=\ 192.168.90.30 add disabled=yes distance=1 dst-address=192.168.108.0/24 gateway=\ 192.168.90.34 add disabled=yes distance=1 dst-address=192.168.109.0/24 gateway=\ 192.168.90.38 add disabled=yes distance=1 dst-address=192.168.110.0/24 gateway=\ 192.168.90.42 add disabled=yes distance=1 dst-address=192.168.111.0/24 gateway=\ 192.168.90.46 add disabled=yes distance=1 dst-address=192.168.112.0/24 gateway=\ 192.168.90.50 add disabled=yes distance=1 dst-address=192.168.113.0/24 gateway=\ 192.168.90.54 add disabled=yes distance=1 dst-address=192.168.114.0/24 gateway=\ 192.168.90.58 add disabled=yes distance=1 dst-address=192.168.115.0/24 gateway=\ 192.168.90.62 add disabled=yes distance=1 dst-address=192.168.116.0/24 gateway=\ 192.168.90.66 /routing ospf network add area=backbone disabled=yes network=192.168.0.0/16 /system clock set time-zone-name=Europe/Oslo
DNS server er en Raspberry Pi med Raspian, statisk IP og bind9 som er konfigurert med allow-recursion { any; };
Web server for test av NAT er også en Raspberry Pi med webserver.
For å knytte samen hele nettet trenger man en svitsj med støtte for å konfigurere et VLAN til hver deltager i tillegg til instruktør, «ISP» og det nettet man kobler hele oppsette til. Det er jo en fordel om det er en svitsj som ikke støyer så veldig. Vi bruker en gammel HP 1810G-24.