Annotation of embedaddon/bird/doc/bird.conf.example, revision 1.1
1.1 ! misho 1: /*
! 2: * This is an example configuration file.
! 3: */
! 4:
! 5: # Yes, even shell-like comments work...
! 6:
! 7: # Configure logging
! 8: #log syslog { debug, trace, info, remote, warning, error, auth, fatal, bug };
! 9: #log stderr all;
! 10: #log "tmp" all;
! 11:
! 12: # Override router ID
! 13: #router id 198.51.100.1;
! 14:
! 15: # You can define your own symbols...
! 16: #define xyzzy = (120+10);
! 17: #define '1a-a1' = (30+40);
! 18:
! 19: # Define a route filter...
! 20: #filter test_filter {
! 21: # if net ~ 10.0.0.0/16 then accept;
! 22: # else reject;
! 23: #}
! 24:
! 25: #filter sink { reject; }
! 26: #filter okay { accept; }
! 27:
! 28: #include "filters.conf";
! 29:
! 30: # Define another routing table
! 31: #table testable;
! 32:
! 33: # Turn on global debugging of all protocols
! 34: #debug protocols all;
! 35:
! 36: # Turn on internal watchdog
! 37: #watchdog warning 5 s;
! 38: #watchdog timeout 30 s;
! 39:
! 40: # The direct protocol automatically generates device routes to
! 41: # all network interfaces. Can exist in as many instances as you wish
! 42: # if you want to populate multiple routing tables with device routes.
! 43: #protocol direct {
! 44: # interface "-eth*", "*"; # Restrict network interfaces it works with
! 45: #}
! 46:
! 47: # This pseudo-protocol performs synchronization between BIRD's routing
! 48: # tables and the kernel. If your kernel supports multiple routing tables
! 49: # (as Linux 2.2.x does), you can run multiple instances of the kernel
! 50: # protocol and synchronize different kernel tables with different BIRD tables.
! 51: protocol kernel {
! 52: # learn; # Learn all alien routes from the kernel
! 53: persist; # Don't remove routes on bird shutdown
! 54: scan time 20; # Scan kernel routing table every 20 seconds
! 55: # import none; # Default is import all
! 56: export all; # Default is export none
! 57: # kernel table 5; # Kernel table to synchronize with (default: main)
! 58: }
! 59:
! 60: # This pseudo-protocol watches all interface up/down events.
! 61: protocol device {
! 62: scan time 10; # Scan interfaces every 10 seconds
! 63: }
! 64:
! 65: # Static routes (again, there can be multiple instances, so that you
! 66: # can disable/enable various groups of static routes on the fly).
! 67: protocol static {
! 68: # disabled; # Disable by default
! 69: # table testable; # Connect to a non-default table
! 70: # preference 1000; # Default preference of routes
! 71: # debug { states, routes, filters, interfaces, events, packets };
! 72: # debug all;
! 73: # route 0.0.0.0/0 via 198.51.100.13;
! 74: # route 198.51.100.0/25 unreachable;
! 75: # route 10.0.0.0/8 unreachable;
! 76: # route 10.1.1.0:255.255.255.0 via 198.51.100.3;
! 77: # route 10.1.2.0:255.255.255.0 via 198.51.100.3;
! 78: # route 10.1.3.0:255.255.255.0 via 198.51.100.4;
! 79: # route 10.2.0.0/24 via "arc0";
! 80: }
! 81:
! 82: # Pipe protocol connects two routing tables... Beware of loops.
! 83: #protocol pipe {
! 84: # peer table testable;
! 85: # Define what routes do we export to this protocol / import from it.
! 86: # import all; # default is all
! 87: # export all; # default is none
! 88: # import none; # If you wish to disable imports
! 89: # import filter test_filter; # Use named filter
! 90: # import where source = RTS_DEVICE; # Use explicit filter
! 91: #}
! 92:
! 93: # RIP aka Rest In Pieces...
! 94: #protocol rip MyRIP { # You can also use an explicit name
! 95: # preference xyzzy;
! 96: # debug all;
! 97: # port 1520;
! 98: # period 7;
! 99: # infinity 16;
! 100: # garbage time 60;
! 101: # interface "*" { mode broadcast; };
! 102: # honor neighbor; # To whom do we agree to send the routing table
! 103: # honor always;
! 104: # honor never;
! 105: # passwords {
! 106: # password "nazdar";
! 107: # };
! 108: # authentication none;
! 109: # import filter { print "importing"; accept; };
! 110: # export filter { print "exporting"; accept; };
! 111: #}
! 112:
! 113: #protocol ospf MyOSPF {
! 114: # tick 2;
! 115: # rfc1583compat yes;
! 116: # area 0.0.0.0 {
! 117: # stub no;
! 118: # interface "eth*" {
! 119: # hello 9;
! 120: # retransmit 6;
! 121: # cost 10;
! 122: # transmit delay 5;
! 123: # dead count 5;
! 124: # wait 50;
! 125: # type broadcast;
! 126: # authentication simple;
! 127: # password "pass";
! 128: # };
! 129: # interface "arc0" {
! 130: # rx buffer large;
! 131: # type nonbroadcast;
! 132: # poll 14;
! 133: # dead 75;
! 134: # neighbors {
! 135: # 10.1.1.2 eligible;
! 136: # 10.1.1.4;
! 137: # };
! 138: # strict nonbroadcast yes;
! 139: # };
! 140: # interface "xxx0" {
! 141: # passwords {
! 142: # password "abc" {
! 143: # id 1;
! 144: # generate to "22-04-2003 11:00:06";
! 145: # accept to "17-01-2004 12:01:05";
! 146: # };
! 147: # password "def" {
! 148: # id 2;
! 149: # generate from "22-04-2003 11:00:07";
! 150: # accept from "17-01-2003 12:01:05";
! 151: # };
! 152: # };
! 153: # authentication cryptographic;
! 154: # };
! 155: # };
! 156: # area 20 {
! 157: # stub 1;
! 158: # interface "ppp1" {
! 159: # hello 8;
! 160: # authentication none;
! 161: # };
! 162: # interface "fr*";
! 163: # virtual link 192.168.0.1 {
! 164: # password "sdsdffsdfg";
! 165: # authentication cryptographic;
! 166: # };
! 167: # };
! 168: #}
! 169:
! 170:
! 171: #protocol bgp {
! 172: # disabled;
! 173: # description "My BGP uplink";
! 174: # local as 65000;
! 175: # neighbor 198.51.100.130 as 64496;
! 176: # multihop;
! 177: # hold time 240;
! 178: # startup hold time 240;
! 179: # connect retry time 120;
! 180: # keepalive time 80; # defaults to hold time / 3
! 181: # start delay time 5; # How long do we wait before initial connect
! 182: # error wait time 60, 300;# Minimum and maximum time we wait after an error (when consecutive
! 183: # # errors occur, we increase the delay exponentially ...
! 184: # error forget time 300; # ... until this timeout expires)
! 185: # disable after error; # Disable the protocol automatically when an error occurs
! 186: # next hop self; # Disable next hop processing and always advertise our local address as nexthop
! 187: # path metric 1; # Prefer routes with shorter paths (like Cisco does)
! 188: # default bgp_med 0; # MED value we use for comparison when none is defined
! 189: # default bgp_local_pref 0; # The same for local preference
! 190: # source address 198.51.100.14; # What local address we use for the TCP connection
! 191: # password "secret"; # Password used for MD5 authentication
! 192: # rr client; # I am a route reflector and the neighor is my client
! 193: # rr cluster id 1.0.0.1; # Use this value for cluster id instead of my router id
! 194: # export where source=RTS_STATIC;
! 195: # export filter {
! 196: # if source = RTS_STATIC then {
! 197: # bgp_community = -empty-; bgp_community = add(bgp_community,(65000,5678));
! 198: # bgp_origin = 0;
! 199: # bgp_community = -empty-; bgp_community.add((65000,5678));
! 200: # if (65000,64501) ~ bgp_community then
! 201: # bgp_community.add((0, 1));
! 202: # if bgp_path ~ [= 65000 =] then
! 203: # bgp_path.prepend(65000);
! 204: # accept;
! 205: # }
! 206: # reject;
! 207: # };
! 208: #}
! 209: #
! 210: # Template usage example
! 211: #template bgp rr_client {
! 212: # disabled;
! 213: # local as 65000;
! 214: # multihop;
! 215: # rr client;
! 216: # rr cluster id 1.0.0.1;
! 217: #}
! 218: #
! 219: #protocol bgp rr_abcd from rr_client {
! 220: # neighbor 10.1.4.7 as 65000;
! 221: #}
FreeBSD-CVSweb <freebsd-cvsweb@FreeBSD.org>