Skip to content
GitLab
Projects Groups Snippets
  • /
  • Help
    • Help
    • Support
    • Community forum
    • Submit feedback
    • Contribute to GitLab
  • Sign in / Register
  • B BIRD Internet Routing Daemon
  • Project information
    • Project information
    • Activity
    • Labels
    • Members
  • Repository
    • Repository
    • Files
    • Commits
    • Branches
    • Tags
    • Contributors
    • Graph
    • Compare
  • Merge requests 3
    • Merge requests 3
  • CI/CD
    • CI/CD
    • Pipelines
    • Jobs
    • Schedules
  • Deployments
    • Deployments
    • Environments
    • Releases
  • Packages and registries
    • Packages and registries
    • Container Registry
  • Analytics
    • Analytics
    • Value stream
    • CI/CD
    • Repository
  • Wiki
    • Wiki
  • Activity
  • Graph
  • Jobs
  • Commits
Collapse sidebar
  • labs
  • BIRD Internet Routing Daemon
  • Wiki
  • BGP_example_1

BGP_example_1 · Changes

Page history
Rename pages authored Jun 03, 2013 by Ondřej Surý's avatar Ondřej Surý
Hide whitespace changes
Inline Side-by-side
BGP_example_1.md 0 → 100644
View page @ e466a356
# BGP example 1
Here is an example of a gateway router for a leaf AS, which uses BGP just for propagating its prefixes to its upstream ISP. The config uses two static protocols named static_bgp and static_ospf. First one is used for prefixes that are propagated to the upstream ISP. These prefixes are represented as unreachable routes, which seems strange but it does not matter for BGP and has a secondary advantage that packets for AS-local but unreachable destinations are rejected and not sent to the upstream. The second static protocol (static_ospf) specifies the default route, which is used both locally and propagated to the OSPF protocol.
Because we use BGP protocol just to propagate our prefixes and we use the default route, we could ignore received prefixes (_import none_ in BGP) so we don't need any filtering. XXXX is the local ASN, YYYY is the upstream ASN and W.X.Y.Z is the IP address of the upstream BGP router.
log syslog all;
router id A.B.C.D;
protocol device {
scan time 10;
}
protocol kernel {
export all;
scan time 15;
}
protocol static static_bgp {
import all;
route A.B.C.0/24 reject;
route D.E.F.0/24 reject;
}
protocol static static_ospf {
import all;
route 0.0.0.0/0 via W.X.Y.Z;
}
protocol bgp {
import none;
export where proto = "static_bgp";
local as XXXX;
neighbor W.X.Y.Z as YYYY;
}
protocol ospf {
import all;
export where proto = "static_ospf";
...
}
Clone repository
  • BGP_example_1
  • BGP_example_2
  • BGP_filtering
  • Command_interface_examples
  • Examples
  • FAQ
  • OSPF_example
  • Policy_routing
  • Related
  • Route_server_with_community_based_filtering_and_multiple_RIBs
  • Route_server_with_community_based_filtering_and_single_RIB
  • Simple_route_server
  • Home
  • transition notes to bird 2