You are on page 1of 35

BGP on Mikrotik

GLC webinar, 6 october 2016

Achmad Mardiansyah
achmad@glcnetworks.com
GLC Networks, Indonesia
www.glcnetworks.com
Agenda

● Introduction
● BGP
● BGP on mikrotik
● Demo
● Q&A

2
www.glcnetworks.com
What is GLC?

● Garda Lintas Cakrawala (www.glcnetworks.com)


● An Indonesian company
● Located in Bandung
● Areas: Training, IT Consulting
● Mikrotik Certified Training Partner
● Mikrotik Certified Consultant
● Mikrotik distributor

3
www.glcnetworks.com
Trainer Introduction

● Name: Achmad Mardiansyah


● Base: bandung, Indonesia
● Linux user since ’99
● Certified Trainer (MTCNA/RE/WE/UME/INE/TCE)
● Mikrotik Certified Consultant
● Work: Telco engineer, Sysadmin, PHP programmer,
and Lecturer
● Personal website: http://achmad.glcnetworks.com
● More info:
http://au.linkedin.com/in/achmadmardiansyah

4
www.glcnetworks.com
Please introduce yourself

● Your name
● Your company/university?
● Your networking experience?
● Your mikrotik experience?
● Your expectation from this course?

5
www.glcnetworks.com
What is Mikrotik?

● Name of a company
● A brand
● A program (e.g. mikrotik academy)
● Headquarter: Riga, Latvia

6
www.glcnetworks.com
What are mikrotik products?

● Router OS
○ The OS. Specialized for networking
○ Website: www.mikrotik.com/download
● RouterBoard
○ The hardware
○ RouterOS installed
○ Website: www.routerboard.com

7
www.glcnetworks.com
What Router OS can do?

● Go to www.mikrotik.com
○ Download: what_is_routeros.pdf
○ Download: product catalog
○ Download: newsletter

8
www.glcnetworks.com
What are Mikrotik training & certifications?

Certificate validity is 3 years

9
www.glcnetworks.com
BGP (Border Gateway Protocol)

10
www.glcnetworks.com
What is BGP?

● Path Vector Protocol


● Incremental Updates
● Many options for policy enforcement
● Support VLSM
● Classless Inter Domain Routing (CIDR)
● Widely used for Internet backbone
● Connects Autonomous systems

11
www.glcnetworks.com
What is VLSM?

● Variable-Length Subnet Masking (VLSM)


● Can divide an IP address block into subnets of different sizes using / (slash)
notation
● Solution the in efficient of classful IP address (fixed length). No more class A,
class B, Class C -> pleeease dont say this classes anymore
● making it possible to create subnets with very different host counts without
wasting large numbers of addresses.
● RFC: 1878 (1995)
● Basis for CIDR
● Example: 23.45.0.0/16
○ 23.45.0.0/25
○ 23.45.0.128/25

12
www.glcnetworks.com
VLSM RFC

13
www.glcnetworks.com
What is CIDR?

● CIDR: Classless Inter-Domain Routing (sometimes is called supernetting)


● CIDR solves problem of wasted address spaceby providing a new and more
flexible way to specify network addresses in routers (using slash as notation)
● allow flexible allocation of Internet Protocol (IP) addresses.
● Replaces classfull network (class A,B,C,D). Please dont ever mention this
anymore...
● CIDR lets a routing table entry represent an aggregation of networks that exist
in the forward path
● Each IP address has a network prefix that identifies either one or several
network gateways.
● RFC: 1519

14
www.glcnetworks.com
CIDR

15
www.glcnetworks.com
Path Vector Protocol

● BGP is classified as a path vector routing protocol (see RFC 1322)


● A path vector protocol defines a route as a pairing between a destination and
the attributes of the path to that destination.
● See AS path below

16
www.glcnetworks.com
Path vector protocol

Image source: philip smith,


introduction to BGP
(http://www.bgp4all.com.au)
17
www.glcnetworks.com
Definitions

● Transit - service provided by an ISP to carry other ISP/customer traffic to


other network (internet). Usually is for commercial (paid service)
● Peering - 2 ISPs or more exchange traffic and routing information. Can be
commercial or non commercial (gratis). Example: peering on IXP (Internet
Exchange Point)
● Default - default route, sending traffic to default router of there is no explicit
match on routing table

18
www.glcnetworks.com
Peering and transit example (IIX vs openIXP?)

source: philip smith,


introduction to BGP
(http://www.bgp4all.com.au)

19
www.glcnetworks.com
Autonomous System (AS)

● Collection of networks with same routing policy


● Single routing protocol
● Usually under single ownership, trust and administrative control
● Identified by a unique 32-bit integer (ASN)

source: philip smith,


introduction to BGP
(http://www.bgp4all.com.au)
20
www.glcnetworks.com
BGP basics

source: philip smith,


introduction to BGP
(http://www.bgp4all.com.au)
21
www.glcnetworks.com
Building forwarding table for BGP

source: philip smith,


introduction to BGP
(http://www.bgp4all.com.au) 22
www.glcnetworks.com
eBGP & iBGP

● BGP is used
○ Internally, inside AS (iBGP - internal BGP)
○ Externally, between AS (eBGP - external BGP)
● iBGP is used to carry
○ Some/all Internet prefixes across ISP backbone
○ Prefixes from ISP customers
● eBGP is used to
○ Exchange prefixes with other ASes
○ Implement routing policy

23
www.glcnetworks.com
eBGP & iBGP

IGP: interior Gateway source: philip smith,


Protocol. E.g. RIP, OSPF, introduction to BGP
IEGRP (http://www.bgp4all.com.au)
24
www.glcnetworks.com
External BGP Peering (eBGP)

● Between BGP speakers in different AS


● Should be directly connected
● Never run an IGP between eBGP peers

source: philip smith,


introduction to BGP
(http://www.bgp4all.com.au)
25
www.glcnetworks.com
Internal BGP (iBGP)

● BGP peer within the same AS


● Not required to be directly connected
○ IGP takes care of inter-BGP speaker connectivity
● iBGP speakers must be fully meshed:
○ They originate connected networks
○ They pass on prefixes learned from outside the ASN
○ They do not pass on prefixes learned from other iBGP speakers
● Recommended to do peer with loopback interface
● To avoid mesh peering: AS confederation, route reflector

source: philip smith,


introduction to BGP
(http://www.bgp4all.com.au)

26
www.glcnetworks.com
BGP on Mikrotik

27
www.glcnetworks.com
Setup instance

28
www.glcnetworks.com
Setup BGP peer

29
www.glcnetworks.com
Display peer

30
www.glcnetworks.com
Display routing table

31
www.glcnetworks.com
Demo

32
www.glcnetworks.com
33
www.glcnetworks.com
QA

34
www.glcnetworks.com
End of slides

● Thank you for your attention


● Please submit your feedback: http://bit.ly/glcfeedback
● Like our facebook page: “GLC networks”
● Stay tune with our schedule

35
www.glcnetworks.com

You might also like