### L3VPN Configuration Example Source: https://bird.xmsl.dev/docs/user-guide/6-12-l3vpn A complete configuration example demonstrating an L3VPN setup with BGP peering, kernel VRF integration, and MPLS domain configuration. ```bird2 # MPLS 基础配置 mpls domain mdom; mpls table mtab; protocol kernel krt_mpls { mpls { table mtab; export all; }; } vpn4 table vpntab4; vpn6 table vpntab6; # 通过 BGP 交换 VPN 路由 protocol bgp { vpn4 { table vpntab4; import all; export all; }; vpn6 { table vpntab6; import all; export all; }; mpls { label policy aggregate; }; local 10.0.0.1 as 10; neighbor 10.0.0.2 as 10; } # VRF 0 ipv4 table vrf0v4; ipv6 table vrf0v6; protocol kernel kernel0v4 { vrf "vrf0"; ipv4 { table vrf0v4; export all; }; kernel table 100; } protocol kernel kernel0v6 { vrf "vrf0"; ipv6 { table vrf0v6; export all; }; kernel table 100; } protocol l3vpn l3vpn0 { vrf "vrf0"; ipv4 { table vrf0v4; }; ipv6 { table vrf0v6; }; vpn4 { table vpntab4; }; vpn6 { table vpntab6; }; mpls { label policy vrf; }; rd 10:12; import target [(rt, 10, 32..40)]; export target [(rt, 10, 30), (rt, 10, 31)]; } ``` -------------------------------- ### BGP Protocol Configuration Example Source: https://bird.xmsl.dev/docs/user-guide/6-1-bgp A complete BGP protocol block demonstrating multi-hop setup, TCP-AO authentication with key management, and protocol-specific export/import filters. ```bird2 protocol bgp { local 198.51.100.14 as 65000; # 使用私有 AS 号 neighbor 198.51.100.130 as 64496; # 我们的邻居... multihop; # ...间接连接 authentication ao; # 使用 TCP-AO 认证 keys { key { id 0; secret "hello321"; algorithm hmac sha256; preferred; }; key { send id 2; recv id 1; secret "bye123"; algorithm cmac aes128; }; }; ipv4 { export filter { # 使用非平凡的 export 规则 if source = RTS_STATIC then { # 仅导出静态路由 # 分配我们的团体属性 bgp_community.add((65000,64501)); # 通过两次通告本地 AS 号 # 人为增加路径长度 if bgp_path ~ [= 65000 =] then bgp_path.prepend(65000); accept; } reject; }; import all; next hop self; # 将本路由器作为下一跳通告 igp table myigptable4; # IPv4 下一跳的 IGP 表 igp table myigptable6; # IPv6 下一跳的 IGP 表 }; ipv6 { export filter mylargefilter; # 使用命名过滤器 import all; missing lladdr self; igp table myigptable4; igp table myigptable6; }; ipv4 multicast { import all; export filter someotherfilter; table mymulticasttable4; # 另一个 IPv4 表,专用于组播 igp table myigptable4; }; } ``` -------------------------------- ### Enable and start BIRD service Source: https://bird.xmsl.dev/docs/user-guide/1-2-installing Reload systemd configuration and start the BIRD service. ```bash systemctl daemon-reload systemctl enable bird systemctl start bird ``` -------------------------------- ### Compile and install BIRD Source: https://bird.xmsl.dev/docs/user-guide/1-2-installing Generate the makefile, configure installation paths, and compile the source code. ```bash cd BIRD-$_BIRD_VERSION autoconf ./configure --prefix= --sysconfdir=/etc/bird --runstatedir=/var/run/bird make && make install ``` -------------------------------- ### Install git and curl by distribution Source: https://bird.xmsl.dev/docs/user-guide/1-2-installing Install git and curl utilities required for downloading the BIRD source code. ```bash apt install git curl ``` ```bash dnf install git curl ``` ```bash pacman -Syu --needed git curl ``` ```bash apk add git curl ``` -------------------------------- ### Basic BIRD Configuration Example Source: https://bird.xmsl.dev/docs/user-guide/3-1-introduction A sample configuration enabling kernel route synchronization, device monitoring, and the RIP protocol. ```cs protocol kernel { ipv4 { export all; /* 在此配置下导出 `master4` 表的路由到内核,默认配置则是不导出路由 */ }; persist; /* 在 BIRD 关闭时不收回路由 */ } protocol device { } protocol rip { ipv4 { import all; export all; }; interface "*"; /* 使用所有的网络接口 */ } ``` -------------------------------- ### Install BIRD on Fedora/RHEL Source: https://bird.xmsl.dev/docs/user-guide/1-2-installing Installs BIRD using the dnf package manager. ```bash dnf install bird ``` -------------------------------- ### Install BIRD on Arch Linux Source: https://bird.xmsl.dev/docs/user-guide/1-2-installing Installs BIRD from the Extra repository using pacman. ```bash pacman -Syu --needed --repository=extra bird ``` -------------------------------- ### Start BIRD service on Alpine Linux Source: https://bird.xmsl.dev/docs/user-guide/1-2-installing Enables and starts the BIRD service using OpenRC. ```bash # 启用并启动 BIRD 服务 rc-update add bird default rc-service bird start ``` -------------------------------- ### Install BIRD 2.x on Debian/Ubuntu via CZ.NIC Source: https://bird.xmsl.dev/docs/user-guide/1-2-installing Installs BIRD 2.x using the official CZ.NIC repository. ```bash sudo apt update && sudo apt -y install apt-transport-https ca-certificates wget lsb-release sudo wget -O /usr/share/keyrings/cznic-labs-pkg.gpg https://pkg.labs.nic.cz/gpg echo "deb [signed-by=/usr/share/keyrings/cznic-labs-pkg.gpg] https://pkg.labs.nic.cz/bird2 $(lsb_release -sc) main" | sudo tee /etc/apt/sources.list.d/cznic-labs-bird2.list sudo apt update && sudo apt install bird2 ``` -------------------------------- ### Install BIRD 3.x on Debian/Ubuntu via CZ.NIC Source: https://bird.xmsl.dev/docs/user-guide/1-2-installing Installs BIRD 3.x using the official CZ.NIC repository. ```bash sudo apt update && sudo apt -y install apt-transport-https ca-certificates wget lsb-release sudo wget -O /usr/share/keyrings/cznic-labs-pkg.gpg https://pkg.labs.nic.cz/gpg echo "deb [signed-by=/usr/share/keyrings/cznic-labs-pkg.gpg] https://pkg.labs.nic.cz/bird3 $(lsb_release -sc) main" | sudo tee /etc/apt/sources.list.d/cznic-labs-bird3.list sudo apt update && sudo apt install bird3 ``` -------------------------------- ### Install BIRD 2.x on Ubuntu via noble channel Source: https://bird.xmsl.dev/docs/user-guide/1-2-installing Installs BIRD 2.x by adding the noble repository channel. ```bash echo "deb http://archive.ubuntu.com/ubuntu/ $(lsb_release -sc)-noble main contrib non-free" | tee -a /etc/apt/sources.list apt update apt install -t $(lsb_release -sc)-noble bird2 ``` -------------------------------- ### Install BIRD on Alpine Linux Source: https://bird.xmsl.dev/docs/user-guide/1-2-installing Commands to install BIRD on Alpine Linux from Edge or stable repositories. ```bash # 添加 Edge 社区仓库 echo "https://dl-cdn.alpinelinux.org/alpine/edge/community" >> /etc/apk/repositories # 更新包索引并安装 BIRD apk update && apk add bird ``` ```bash # 启用社区仓库(如果尚未启用) sed -i 's/#.*community//' /etc/apk/repositories # 更新包索引并安装 BIRD apk update && apk add bird ``` -------------------------------- ### Install build dependencies by distribution Source: https://bird.xmsl.dev/docs/user-guide/1-2-installing Install necessary build tools and libraries required for compiling BIRD on various Linux distributions. ```bash apt install gcc make binutils m4 flex bison libncurses-dev libreadline-dev autoconf ``` ```bash dnf install gcc make binutils m4 flex bison ncurses-devel readline-devel autoconf ``` ```bash pacman -Syu --needed gcc make binutils m4 flex bison ncurses readline autoconf ``` ```bash apk add gcc make binutils m4 flex bison ncurses-dev readline-dev autoconf ``` -------------------------------- ### Multi-Table Kernel Protocol Configuration Source: https://bird.xmsl.dev/docs/user-guide/6-5-kernel An example demonstrating how to configure multiple kernel protocol instances for different routing tables, including learning and persistence settings. ```bird2 protocol kernel { # 主路由表 learn; # 从内核学习外来路由 persist; # BIRD 关闭时不删除路由 scan time 10; # 每 10 秒扫描内核路由表 ipv4 { import all; export all; }; } protocol kernel { # 辅路由表 kernel table 100; ipv4 { table auxtable; export all; }; } ``` -------------------------------- ### Install BIRD 2.x on Debian via Backports Source: https://bird.xmsl.dev/docs/user-guide/1-2-installing Installs BIRD 2.x using the Debian Backports channel. ```bash echo "deb http://deb.debian.org/debian $(lsb_release -sc)-backports main" > tee -a /etc/apt/sources.list apt update apt install -t $(lsb_release -sc)-backports bird2 ``` -------------------------------- ### Direct Protocol Configuration Example Source: https://bird.xmsl.dev/docs/user-guide/6-7-direct A standard configuration for the Direct protocol, enabling both IPv4 and IPv6, filtering interfaces, and enabling link state checks. ```bird2 protocol direct { ipv4; # 自动生成 IPv4 路由 ipv6; # 自动生成 IPv6 路由 interface "-arc*", "*"; # 排除 ARCnets check link yes; # 检查链路状态 } ``` -------------------------------- ### BIRD 2 BGP Configuration Example Source: https://bird.xmsl.dev/docs/collections/bird-bgp-kickstart-moesoha A comprehensive configuration file for BIRD 2, implementing static routes, BGP templates, and specific import/export filters for transit and peer sessions. ```bird2 log syslog all; router id 10.0.0.1; define LOCAL_ASN = 65550; protocol device {} protocol kernel { ipv6 { export all; }; } # 公网上约定俗成的最小前缀长度是 24(IPv4)和 48(IPv6),所以要在导出的时候过滤 function net_len_too_long(){ case net.type { NET_IP4: return net.len > 24; # IPv4 CIDR 大于 /24 为太长 NET_IP6: return net.len > 48; # IPv6 CIDR 大于 /48 为太长 else: print "net_len_too_long: unexpected net.type ", net.type, " ", net; return false; } } # 目标 1 function bgp_export() { if net_len_too_long() then return false; if source != RTS_STATIC then return false; if net !~ [2001:db8:1000::/44{44,46}] then return false; return true; } # 目标 2 protocol static { ipv6; route 2001:db8:1000::/44 reject; } # 目标 8 protocol static { ipv6; route 2001:db8:100a::/48 via "tun-a"; } # 使用模板减少重复代码 template bgp tpl_bgp { graceful restart; local as LOCAL_ASN; ipv6 { import where !net_len_too_long(); export where bgp_export(); }; } template bgp tpl_ibgp from tpl_bgp { med metric; direct; ipv6 { next hop self; gateway direct; import all; export all; }; } # 目标 3 protocol bgp bgp_as64501 from tpl_bgp { source address 2001:db8:ffff:1::6:5550; neighbor 2001:db8:ffff:1::6:4501 as 64501; ipv6 { import filter { if net_len_too_long() then reject; if (64501, 1, 65511) ~ bgp_large_community then reject; # 目标 5 accept; }; export filter { if !bgp_export() then reject; bgp_community.add((0, 65510)); # 目标 4 accept; } }; } # 目标 6 protocol bgp bgp_as64502 from tpl_bgp { source address 2001:db8:ffff:2::6:5550; neighbor 2001:db8:ffff:2::6:4502 as 64502; ipv6 { import filter { if net_len_too_long() then reject; bgp_local_pref = 1000; # 目标 7 accept; }; # export 使用了 template 中的默认值 }; } # 目标 9 protocol bgp ibgp_b from tpl_ibgp { source address 2001:db8:eeee:b::1; neighbor 2001:db8:eeee:b::b as LOCAL_ASN; } ``` -------------------------------- ### Configure RAdv Protocol in BIRD 2 Source: https://bird.xmsl.dev/docs/user-guide/6-15-radv Example configuration demonstrating static route propagation, interface-specific settings, and RDNSS/DNSSL options. ```bird2 ipv6 table radv_routes; # 手动配置的路由放到这里 protocol static { ipv6 { table radv_routes; }; route 2001:0DB8:4000::/48 unreachable; route 2001:0DB8:4010::/48 unreachable; route 2001:0DB8:4020::/48 unreachable { ra_preference = RA_PREF_HIGH; ra_lifetime = 3600; }; } protocol radv { propagate routes yes; # 传播来自 radv_routes 表的路由 ipv6 { table radv_routes; export all; }; interface "eth2" { max ra interval 5; # 多路由器场景下的快速故障切换 managed yes; # 在 eth2 上使用 DHCPv6 prefix ::/0 { autonomous off; # 因此不自动配置任何 IP }; }; interface "eth*"; # 其他接口无需任何选项 prefix 2001:0DB8:1234::/48 { preferred lifetime 0; # 已弃用的地址范围 }; prefix 2001:0DB8:2000::/48 { autonomous off; # 不进行自动配置 }; rdnss 2001:0DB8:1234::10; # RDNSS 简写形式 rdnss { lifetime mult 10; ns 2001:0DB8:1234::11; ns 2001:0DB8:1234::12; }; dnssl { lifetime 3600; domain "abc.com"; domain "xyz.com"; }; } ``` -------------------------------- ### Configure Static Routes in BIRD Source: https://bird.xmsl.dev/docs/user-guide/6-4-static Examples of static protocol blocks for IPv4 and IPv6, demonstrating various route types, next-hop configurations, and attribute settings. ```bird2 protocol static { ipv4 { table testable; }; # 连接到非默认路由表 check link; # 仅在链路正常时宣告路由 route 0.0.0.0/0 via 198.51.100.130; # 默认路由 route 10.0.0.0/8 # 多路径路由 via 198.51.100.10 weight 2 via 198.51.100.20 bfd # BFD 控制的下一跳 via 192.0.2.1; route 203.0.113.0/24 blackhole; # 沉没路由 route 10.2.0.0/24 via "arc0"; # 直连路由 route 10.2.2.0/24 via 192.0.2.1 dev "eth0" onlink; # 同时指定下一跳和接口 route 192.168.10.0/24 via 198.51.100.100 { ospf_metric1 = 20; # 设置扩展属性 }; route 192.168.11.0/24 via 198.51.100.100 { ospf_metric2 = 100; # 设置扩展属性 ospf_tag = 2; # 设置扩展属性 }; route 192.168.12.0/24 via 198.51.100.100 { bgp_community.add((65535, 65281)); # 设置扩展 BGP 属性 bgp_large_community.add((64512, 1, 1)); # 设置扩展 BGP 属性 }; } ``` ```bird2 protocol static { ipv6; # 通道是必选的 route 2001:db8:10::/48 via 2001:db8:1::1; # 全局下一跳路由 route 2001:db8:20::/48 via fe80::10%eth0; # 链路本地下一跳路由 route 2001:db8:30::/48 via fe80::20%'eth1.60'; # 含特殊字符的接口 route 2001:db8:40::/48 via fe80::30 dev "eth1"; # 另一种链路本地下一跳 route 2001:db8:50::/48 via "eth2"; # 指向 eth2 的直连路由 route 2001:db8::/32 unreachable; # 不可达路由 route ::/0 via 2001:db8:1::1 bfd; # BFD 控制的默认路由 } ``` -------------------------------- ### Configure Protocol Channels Source: https://bird.xmsl.dev/docs/collections/bird-bgp-kickstart-moesoha Example of configuring import/export filters and route limits within a protocol channel. ```bird2 protocol some_proto { /* 略 */ ipv6 { export filter some_filter1; import filter some_filter2; # 下面这两个是可选项,默认是不做限制的 export limit 100 action disable; # 导出的路由数量多于 100 后自动停止该协议,避免传出过多路由(往往这个时候是漏路由了) import limit 100 action restart; # 导入的路由数量多于 100 后自动重启该协议,限制对端传入的路由数 }; } ``` -------------------------------- ### Check BIRD version Source: https://bird.xmsl.dev/docs/user-guide/1-2-installing Command to verify the currently installed version of BIRD. ```bash birdc -v ``` -------------------------------- ### Configure BIRD Device Protocol Source: https://bird.xmsl.dev/docs/user-guide/6-6-device Example configuration for the device protocol, including scan interval settings and preferred IP address definitions for specific interfaces. ```bird2 protocol device { scan time 10; #扫描间隔 10 秒 interface "eth0" { #指定网卡 eth0 preferred 192.168.1.1; #选择优先的 IPv4 地址 preferred 2001:db8:1:10::1; #选择优先的 IPv6 地址 preferred fd00::1; #选择优先的 IPv6 本地链路地址 }; } ``` -------------------------------- ### OSPF Protocol Configuration Source: https://bird.xmsl.dev/docs/user-guide/6-2-ospf Example configuration for an OSPF protocol instance, including export filters, area definitions, interface settings, and authentication methods. ```bird2 protocol ospf MyOSPF { ipv4 { export filter { if source = RTS_BGP then { ospf_metric1 = 100; accept; } reject; }; }; area 0.0.0.0 { interface "eth*" { cost 11; hello 15; priority 100; retransmit 7; authentication simple; password "aaa"; }; interface "ppp*" { cost 100; authentication cryptographic; password "abc" { id 1; generate to "2023-04-22 11:00:06"; accept from "2021-01-17 12:01:05"; algorithm hmac sha384; }; password "def" { id 2; generate to "2025-07-22"; accept from "2021-02-22"; algorithm hmac sha512; }; }; interface "arc0" { cost 10; stub yes; }; interface "arc1"; }; area 120 { stub yes; networks { 172.16.1.0/24; 172.16.2.0/24 hidden; }; interface "-arc0" , "arc*" { type nonbroadcast; authentication none; strict nonbroadcast yes; wait 120; poll 40; dead count 8; neighbors { 192.168.120.1 eligible; 192.168.120.2; 192.168.120.10; }; }; }; } ``` -------------------------------- ### Configure BIRD Pipe Protocol for Policy Routing Source: https://bird.xmsl.dev/docs/user-guide/6-11-pipe Example demonstrating the use of two routing tables (as1 and as2) with kernel synchronization, BGP protocols, and a pipe protocol to exchange routes with modified preferences and BGP paths. ```bird2 ipv4 table as1; # 定义路由表 ipv4 table as2; protocol kernel kern1 { # 与内核同步 ipv4 { table as1; export all; }; kernel table 1; } protocol kernel kern2 { ipv4 { table as2; export all; }; kernel table 2; } protocol bgp bgp1 { # 外部连接 ipv4 { table as1; import all; export all; }; local as 1; neighbor 192.168.0.1 as 1001; } protocol bgp bgp2 { ipv4 { table as2; import all; export all; }; local as 2; neighbor 10.0.0.1 as 1002; } protocol pipe { # 管道协议 table as1; peer table as2; export filter { if net ~ [ 1.0.0.0/8+] then { # 仅 AS1 网络 if preference>10 then preference = preference-10; if source=RTS_BGP then bgp_path.prepend(1); accept; } reject; }; import filter { if net ~ [ 2.0.0.0/8+] then { # 仅 AS2 网络 if preference>10 then preference = preference-10; if source=RTS_BGP then bgp_path.prepend(2); accept; } reject; }; } ``` -------------------------------- ### Specify Configuration and Socket Paths Source: https://bird.xmsl.dev/docs/user-guide/1-3-running Use -c to define the configuration file path and -s to define the control socket path. ```bash $ bird -c /path/to/bird.conf ``` ```bash $ bird -s /path/to/bird.ctl ``` -------------------------------- ### Display Help Information Source: https://bird.xmsl.dev/docs/user-guide/1-3-running Shows command-line help for BIRD. ```bash $ bird -h ``` ```bash $ bird --help ``` -------------------------------- ### Run in Foreground Source: https://bird.xmsl.dev/docs/user-guide/1-3-running Starts BIRD in the foreground without outputting debug information. ```bash $ bird -f ``` -------------------------------- ### Run in Debug Mode Source: https://bird.xmsl.dev/docs/user-guide/1-3-running Starts BIRD in the foreground with verbose debugging output. ```bash $ bird -d ``` -------------------------------- ### Define Bytestring Source: https://bird.xmsl.dev/docs/user-guide/5-2-data-types Examples of defining bytestrings using hexadecimal sequences or the from_hex function. ```text 01:23:45:67:89:ab:cd:ef:01:23:45:67:89:ab:cd:ef 0123456789abcdef0123456789abcdef hex: hex:12:34:56 hex:12345678 from_hex(" 12.34 56:78 ab-cd-ef ") ``` -------------------------------- ### Protocol Instance Syntax Source: https://bird.xmsl.dev/docs/collections/bird-bgp-kickstart-moesoha The general structure for defining a protocol instance in BIRD configuration. ```bird2 protocol <协议> [实例名] { /* 参数们 */ <频道> { /* 频道参数 */ } } ``` -------------------------------- ### Define a BIRD Function Source: https://bird.xmsl.dev/docs/collections/bird-bgp-kickstart-moesoha A function example showing parameter definition, local variables, and the use of 'case' statements for network type checking. ```bird2 function net_len_too_long(int hello) # 这里定义的参数 hello 没啥意义,只是让大家知道可以定义参数,不定义括号内留空即可 int world; { # ^ 这里的变量定义没啥意义,只是让大家知道可以定义局部变量 case net.type { NET_IP4: return net.len > 24; # IPv4 CIDR 大于 /24 为太长 NET_IP6: return net.len > 48; # IPv6 CIDR 大于 /48 为太长 else: print "net_len_too_long: unexpected net.type ", net.type, " ", net; return false; } } ``` -------------------------------- ### configure Source: https://bird.xmsl.dev/docs/user-guide/4-command-line-interface Commands for reloading, checking, and rolling back BIRD configurations. ```APIDOC ## configure [soft] ["config file"] [timeout [num]] ### Description Reloads the configuration from a file. Supports soft reloads to avoid protocol restarts and timed rollbacks for safety. ## configure confirm ### Description Confirms a configuration change and disables the rollback timer. ## configure undo ### Description Rolls back to the previously saved configuration. ## configure check ["config file"] ### Description Parses and validates the specified configuration file without applying it. ``` -------------------------------- ### BIRD 文档翻译计划邮件模板 Source: https://bird.xmsl.dev/pages/join-us 用于申请加入 git 组织或直接提交文档翻译内容的邮件格式模板。 ```txt To: join-bird@xmsl.dev Subject: 申请加入 BIRD 中文文档翻译计划 我是 {昵称},我希望加入 BIRD 中文文档翻译计划,我 Email 地址为 {你的邮箱地址}。 我同意遵守 BIRD 中文文档翻译计划的所有规定,我将尽我所能为 BIRD 中文文档翻译计划做出贡献。 我已阅读并同意 CC BY-NC-SA 4.0 协议。 ``` ```txt To: bird@xmsl.dev Subject: BIRD-CN 文档投稿 / {翻译文档名称} 我是 {昵称},我希望投稿 BIRD 中文文档翻译计划,我 Email 地址为 {你的邮箱地址}。 [markdown 文档内容附件] ``` -------------------------------- ### Display Version Information Source: https://bird.xmsl.dev/docs/user-guide/1-3-running Outputs the current version of BIRD. ```bash $ bird --version ``` -------------------------------- ### Define ROA entries in JSON Source: https://bird.xmsl.dev/docs/user-guide/2-2-routes-and-network-types Example structure for defining ROA (Route Origin Authorization) entries for IPv4 and IPv6 to validate BGP route origins. ```json { "roa4": [ { // [!code focus] "prefix": "198.18.0.0/16", // [!code focus] "maxLength": 24, // [!code focus] "asn": 123456 // [!code focus] } ], "roa6": [ { // [!code focus] "prefix": "2001:db8::/32", // [!code focus] "maxLength": 48, // [!code focus] "asn": 123456 // [!code focus] } ] } ``` -------------------------------- ### 引入配置文件 Source: https://bird.xmsl.dev/docs/user-guide/3-2-global-options 使用 include 语句在配置文件中引入其他文件,必须位于行首。 ```shell ipv6 table include "tablename.conf";; # include 位于所在行的开头 ``` -------------------------------- ### 调试 BIRD 过滤器命令行示例 Source: https://bird.xmsl.dev/docs/user-guide/5-1-introduction 通过 birdc 客户端与 BIRD 交互,使用 show route 命令测试过滤器逻辑。 ```bash $ birdc -s bird.ctl ``` ```bash bird> show route 10.0.0.0/8 dev eth0 [direct1 23:21] (240) 195.113.30.2/32 dev tunl1 [direct1 23:21] (240) 127.0.0.0/8 dev lo [direct1 23:21] (240) ``` ```bash bird> show route ? show route [] [table ] [filter ] [all] [primary]... ``` ```bash bird> show route filter { if 127.0.0.5 ~ net then accept; } 127.0.0.0/8 dev lo [direct1 23:21] (240) ``` -------------------------------- ### Create systemd service file Source: https://bird.xmsl.dev/docs/user-guide/1-2-installing Define the systemd unit file for managing the BIRD daemon. ```ini # /etc/systemd/system/bird.service [Unit] Description="BIRD Internet Routing Daemon" After=network.target [Service] Type=simple ExecStartPre=/usr/sbin/bird -p ExecReload=/usr/sbin/birdc configure ExecStart=/usr/sbin/bird -f -u bird -g bird Restart=on-abort [Install] WantedBy=multi-user.target ```