Revision 1632f1fe

View differences:

doc/bird.sgml
177 177
<sect>Introduction
178 178

  
179 179
<p>BIRD is configured using a text configuration file. Upon startup, BIRD reads <file>$prefix/bird.conf</file> (unless the
180
<tt/-c/ command line option is given). Configuration may be changed on user's request: if you modify
181
config file and then signal BIRD with SIGHUP, it will adjust to the new
182
config. Then there's the client,
183
which allows you to talk with BIRD in an extensive way. (Of course you can tell BIRD to reconfigure from BIRDC, you can also tell it to shut down, dump various info etc.).
180
<tt/-c/ command line option is given). Configuration may be changed at user's request: if you modify
181
the config file and then signal BIRD with <tt/SIGHUP/, it will adjust to the new
182
config. Then there's the client
183
which allows you to talk with BIRD in an extensive way.
184 184

  
185 185
<p>In the config, everything on a line after <cf/#/ or inside <cf>/*
186 186
*/</cf> is a comment, whitespace characters are treated as a single space. If there's a variable number of options, they are grouped using
......
214 214

  
215 215
<p><descrip>
216 216
	<tag>log "<m/filename/"|syslog|stderr all|{ <m/list of classes/ }</tag> 
217
	Set logging of messages having the given (either <cf/all/ or <cf/{
217
	Set logging of messages having the given class (either <cf/all/ or <cf/{
218 218
	error, trace }/ etc.) into selected destination. Classes are:
219
	<cf/info/, <cf/warning/, <cf/error/ and <cf/fatal/ for messages about local problems
219
	<cf/info/, <cf/warning/, <cf/error/ and <cf/fatal/ for messages about local problems,
220 220
	<cf/debug/ for debugging messages, 
221 221
	<cf/trace/ when you want to know what happens in the network, 
222 222
	<cf/remote/ for messages about misbehavior of remote machines, 
......
239 239
	about functions in the following chapter.
240 240
 
241 241
	<tag>protocol rip|ospf|bgp|... <m/[name]/ { <m>protocol options</m> }</tag> Define a protocol
242
	instance called <cf><m/name/</cf> (or with a name like "rip5" generated automatically, if you don't specify <cf><m/name/</cf>). You can learn more
242
	instance called <cf><m/name/</cf> (or with a name like "rip5" generated automatically if you don't specify any <cf><m/name/</cf>). You can learn more
243 243
	about configuring protocols in their own chapters. You can run more than one instance of
244 244
	most protocols (like RIP or BGP). By default, no instances are configured.
245 245

  
246 246
	<tag>define <m/constant/ = (<m/expression/)|<m/number/|<m/IP address/</tag> Define a constant. You can use it later in every place
247
	you could use a simple integer or IP address.
247
	you could use a simple integer or an IP address.
248 248

  
249 249
	<tag>router id <m/IPv4 address/</tag> Set BIRD's router ID. It's a world-wide unique identification of your router, usually one of router's IPv4 addresses. Default: in IPv4 version, the lowest IP address of a non-loopback interface. In IPv6 version, this option is mandatory. 
250 250

  
......
253 253
	to be added by this command.
254 254

  
255 255
	<tag>eval <m/expr/</tag> Evaluates given filter expression. It
256
	is used by us for testing filters.
256
	is used by us for testing of filters.
257 257
</descrip>
258 258

  
259 259
<sect>Protocol options
......
287 287
	<cf/packets/ for packets sent and received by the protocol. Default: off.
288 288

  
289 289
	<tag>import all | none | filter <m/name/ | filter { <m/filter commands/ } | where <m/filter expression/</tag> 
290
	Specify a filter to be used for filtering routes coming from protocol to the routing table. <cf/all/ is shorthand for <cf/where true/ and <cf/none/ is shorthand for <cf/where false/. Default: <cf/all/.
290
	Specify a filter to be used for filtering routes coming from the protocol to the routing table. <cf/all/ is shorthand for <cf/where true/ and <cf/none/ is shorthand for <cf/where false/. Default: <cf/all/.
291 291

  
292
	<tag>export <m/filter/</tag> This is similar to <cf>import</cf> keyword, except that it
293
	works in direction from the routing table to the protocol. Default: <cf/none/.
292
	<tag>export <m/filter/</tag> This is similar to the <cf>import</cf> keyword, except that it
293
	works in the direction from the routing table to the protocol. Default: <cf/none/.
294 294

  
295 295
	<tag>table <m/name/</tag> Connect this protocol to a non-default routing table.
296 296
</descrip>
......
300 300
<descrip>
301 301
	<tag>passwords { password "<m/password/" from <m/time/ to <m/time/ passive <m/time/ id
302 302
	<m/num/ [...] }</tag> Specifies passwords to be used with this protocol. <cf>Passive <m/time/</cf> is
303
	time from which the password is not used for sending, but it is recognized on reception. <cf/id/ is password ID, as needed by
303
	time from which the password is not used for sending, but it is recognized on reception. <cf/id/ is password ID as needed by
304 304
	certain protocols. Format of <cf><m/time/</cf> is <tt>dd-mm-yyyy HH:MM:SS</tt>.
305 305

  
306 306
	<tag>interface "<m/mask/"|<m/prefix/ [ { <m/option/ ; [ ... ] } ]</tag> Specifies which
307
	interfaces this protocol is active on, and allows you to set options on
308
	per-interface basis. Mask is specified in shell-like patterns, thus <cf>interface
307
	interfaces is this protocol active on and allows you to set options on a
308
	per-interface basis. Mask is specified as in shell-like patterns, thus <cf>interface
309 309
	"*" { mode broadcast; };</cf> will start the protocol on all interfaces with <cf>mode
310
	broadcast;</cf> option. If first character of mask is <cf/-/, such interfaces are
310
	broadcast;</cf> option. If the first character of mask is <cf/-/, such interfaces are
311 311
	excluded. Masks are parsed left-to-right, thus <cf/interface "-eth*", "*";/ means all but
312 312
	the ethernets. Default: none.
313 313

  
......
316 316
<chapt>Remote control
317 317

  
318 318
<p>You can use the command-line client <file>birdc</file> to talk with
319
a running BIRD. Communication is done using <file/bird.ctl/ UNIX domain
319
a running BIRD. Communication is done using a <file/bird.ctl/ UNIX domain
320 320
socket (unless changed with the <tt/-s/ option given to both the server and
321
the client). The client can do simple actions such as enabling/disabling
322
protocols, telling BIRD to show various information, telling it to
323
show routing table filtered by any filter, or telling bird to
321
the client). The commands can perform simple actions such as enabling/disabling
322
of protocols, telling BIRD to show various information, telling it to
323
show routing table filtered by filter, or asking BIRD to
324 324
reconfigure. Press <tt/?/ at any time to get online help. Option
325
<tt/-v/ can be passed to the client, telling it to dump numeric return
326
codes. You do not necessarily need to use BIRDC to talk to BIRD, your
327
own application could do that, too -- format of communication between
328
BIRD and BIRDC is stable (see programmer's documentation).
325
<tt/-v/ can be passed to the client, to make it dump numeric return
326
codes along with the messages. You do not necessarily need to use BIRDC to talk to BIRD, your
327
own applications could do that, too -- the format of communication between
328
BIRD and BIRDC is stable (see the programmer's documentation).
329 329

  
330 330
<p>Here is a brief list of supported functions:
331 331

  
......
334 334
	Dump contents of internal data structures to the debugging output.
335 335

  
336 336
	<tag>show status</tag>
337
	Show router status, that is bird version, uptime and time from last reconfiguration.
337
	Show router status, that is BIRD version, uptime and time from last reconfiguration.
338 338

  
339 339
	<tag>show protocols [all]</tag>
340
	Show list of protocols along with tables they are connected to and status, possibly giving verbose information.
340
	Show list of protocol instances along with tables they are connected to and protocol status, possibly giving verbose information, if <cf/all/ is specified.
341 341

  
342 342
	<tag>show ospf [interface|neighbors] [<m/name/] ["<m/interface/"]</tag>
343 343
	Show detailed information about OSPF protocol, possibly giving a verbose list of interfaces and neighbors. The <m/name/ of the protocol instance can be omitted if there exists only a single instance.
......
346 346
	Show detailed information about static routes. The <m/name/ of the protocol instance can be omitted if there exists only a single instance.
347 347
	
348 348
	<tag>show interfaces [summary]</tag>
349
	Show list of interfaces. For each interface, print its type, state, MTU and addresses assigned. 
349
	Show the list of interfaces. For each interface, print its type, state, MTU and addresses assigned. 
350 350

  
351 351
	<tag>show symbols</tag>
352
	Show list of symbols defined in the configuration (names of protocols, routing tables etc.).
352
	Show the list of symbols defined in the configuration (names of protocols, routing tables etc.).
353 353

  
354 354
	<tag>show route [<m/prefix/|for <m/prefix or IP/] [primary] [table <m/sym/] [all] [stats|count] [filter <m/name/|where <m/condition/] [(import|proto) <m/sym/]</tag>
355 355
	Show contents of a routing table (by default of the main one),
356
	i.e. routes, their metrics and (in case the <cf/all/ switch is given)
356
	that is routes, their metrics and (in case the <cf/all/ switch is given)
357 357
	all their attributes.
358 358

  
359 359
	<p>You can specify a <m/prefix/ if you want to print routes for a
......
375 375
	you use <cf/count/ instead, only the statistics will be printed.
376 376

  
377 377
	<tag>enable|disable|restart <m/name/|"<m/pattern/"|all</tag>
378
	Enable, disable or restart given protocol instance, instances matching the <cf><m/pattern/</cf> or <cf/all/ instances.
378
	Enable, disable or restart a given protocol instance, instances matching the <cf><m/pattern/</cf> or <cf/all/ instances.
379 379

  
380 380
	<tag>configure ["<m/config file/"]</tag>
381 381
	Reload configuration from a given file.
......
391 391

  
392 392
<sect>Introduction
393 393

  
394
<p>BIRD contains a rather simple programming language. (No, it can't yet read mail :-). There are
395
two objects in this language: filters and functions. Filters are called by BIRD core when a route is
396
being passed between protocols and routing tables. Filter language contains control structures such
397
as if's and switches, but it allows no loops. Filters are
398
interpreted. An example of a filter using many features can be found in <file>filter/test.conf</file>. 
394
<p>BIRD contains a simple programming language. (No, it can't yet read mail :-). There are
395
two objects in this language: filters and functions. Filters are interpreted by BIRD core when a route is
396
being passed between protocols and routing tables. The filter language contains control structures such
397
as if's and switches, but it allows no loops. An example of a filter using many features can be found in <file>filter/test.conf</file>. 
399 398

  
400 399
<p>Filter gets the route, looks at its attributes and
401 400
modifies some of them if it wishes. At the end, it decides whether to
402
pass the changed route through (using <cf/accept/) or whether to <cf/reject/ given route. A simple filter looks
401
pass the changed route through (using <cf/accept/) or whether to <cf/reject/ it. A simple filter looks
403 402
like this:
404 403

  
405 404
<code>
......
420 419
</code>
421 420

  
422 421
<p>As you can see, a filter has a header, a list of local variables, and a body. The header consists of
423
the <cf/filter/ keyword, followed by a (unique) name of filter. List of local variables consists of
424
pairs <cf><M>type name</M>;</cf>, where each pair defines one local variable. Body consists of
425
<cf> { <M>statements</M> }</cf>. Each <m/statement/ is terminated by <cf/;/. You can group
426
several statements into one by using braces (<cf>{ <M>statements</M> }</cf>), that is useful if
427
you want to make bigger block of code conditional.
428

  
429
<p>BIRD supports functions, so that you don't have to repeat same blocks of code over and
430
over. Functions can have zero or more parameters and they can have local variables. Recursion is not allowed. They
422
the <cf/filter/ keyword followed by a (unique) name of filter. The list of local variables consists of
423
<cf><M>type name</M>;</cf> pairs where each pair defines one local variable. The body consists of
424
<cf> { <M>statements</M> }</cf>. Each <m/statement/ is terminated by a <cf/;/. You can group
425
several statements to a single compound statement by using braces (<cf>{ <M>statements</M> }</cf>) which is useful if
426
you want to make a bigger block of code conditional.
427

  
428
<p>BIRD supports functions, so that you don't have to repeat the same blocks of code over and
429
over. Functions can have zero or more parameters and they can have local variables. Recursion is not allowed. Function definitions
431 430
look like this:
432 431

  
433 432
<code>
......
443 442
}
444 443
</code>
445 444

  
446
<p>Unlike in C, variables are declared after function line but before the first {. You can't declare
445
<p>Unlike in C, variables are declared after the <cf/function/ line, but before the first <cf/{/. You can't declare
447 446
variables in nested blocks. Functions are called like in C: <cf>name();
448
with_parameters(5);</cf>. Function may return value using the <cf>return <m/[expr]/</cf>
447
with_parameters(5);</cf>. Function may return values using the <cf>return <m/[expr]/</cf>
449 448
command. Returning a value exits from current function (this is similar to C).
450 449

  
451 450
<p>Filters are declared in a way similar to functions except they can't have explicit
452
parameters. They get route table entry as an implicit parameter, it is also passed automatically 
451
parameters. They get a route table entry as an implicit parameter, it is also passed automatically 
453 452
to any functions called. The filter must terminate with either
454
<cf/accept/ or <cf/reject/ statement. If there's runtime error in filter, the route
453
<cf/accept/ or <cf/reject/ statement. If there's a runtime error in filter, the route
455 454
is rejected. 
456 455

  
457 456
<p>A nice trick to debug filters is to use <cf>show route filter
......
466 465
195.113.30.2/32    dev tunl1 [direct1 23:21] (240)
467 466
127.0.0.0/8        dev lo [direct1 23:21] (240)
468 467
bird> show route ?
469
show route [<prefix>] [table <t>] [filter <f>] [all] [primary] [(import|protocol) <p>]...
468
show route [<prefix>] [table <t>] [filter <f>] [all] [primary]...
470 469
bird> show route filter { if 127.0.0.5 ~ net then accept; }
471 470
127.0.0.0/8        dev lo [direct1 23:21] (240)
472 471
bird>
......
479 478

  
480 479
<descrip>
481 480
	<tag/bool/ This is a boolean type, it can have only two values, <cf/true/ and
482
	  <cf/false/. Boolean is not compatible with integer and is the only type you can use in if
481
	  <cf/false/. Boolean is the only type you can use in <cf/if/
483 482
	  statements.
484 483

  
485 484
	<tag/int/ This is a general integer type, you can expect it to store signed values from -2000000000
......
495 494

  
496 495
	<tag/ip/ This type can hold a single IP address. Depending on the compile-time configuration of BIRD you are using, it
497 496
	  is either an IPv4 or IPv6 address. IP addresses are written in the standard notation (<cf/10.20.30.40/ or <cf/fec0:3:4::1/). You can apply special operator <cf>.mask(<M>num</M>)</cf>
498
	  on values of type ip. It masks out all but first <cf><M>num</M></cf> bits from ip
497
	  on values of type ip. It masks out all but first <cf><M>num</M></cf> bits from the IP
499 498
	  address. So <cf/1.2.3.4.mask(8) = 1.0.0.0/ is true.
500 499

  
501 500
	<tag/prefix/ This type can hold a network prefix consisting of IP address and prefix length. Prefix literals are written as
502 501
	  <cf><M>ipaddress</M>/<M>pxlen</M></cf>, or
503
	  <cf><m>ipaddress</m>/<m>netmask</m></cf> There are two special
504
	  operators on prefix:
505
	  <cf/.ip/, which separates ip address from the pair, and <cf/.len/, which separates prefix
506
	  len from the pair. So <cf>1.2.0.0/16.pxlen = 16</cf> is true.
502
	  <cf><m>ipaddress</m>/<m>netmask</m></cf>. There are two special
503
	  operators on prefixes:
504
	  <cf/.ip/ which extracts the IP address from the pair, and <cf/.len/, which separates prefix
505
	  length from the pair. So <cf>1.2.0.0/16.pxlen = 16</cf> is true.
507 506

  
508 507
	<tag/int|ip|prefix|pair|enum set/
509 508
	  Filters recognize four types of sets. Sets are similar to strings: you can pass them around
......
511 510
	  [ 1, 2, 5..7 ]</cf>. As you can see, both simple values and ranges are permitted in
512 511
	  sets. Sets of prefixes are special: you can specify which prefix lengths should match them by
513 512
	  using <cf>[ 1.0.0.0/8+, 2.0.0.0/8-, 3.0.0.0/8{5,6} ]</cf>. <cf>3.0.0.0/8{5,6}</cf> matches
514
	  prefixes <cf/3.X.X.X/, whose prefix length is 5 to 6. <cf><m>address</m>/<m>num</m>+</cf> is shorthand for <cf><m>address</m>/{0,<m/num/}</cf>,
515
	  <cf><m>address</m>/<m/num/-</cf> is shorthand for <cf><m>address</m>/{0,<m/num-1/}</cf>. For example,
516
	  <cf>1.2.0.0/16 ~ [ 1.0.0.0/8{ 15 , 17 } ]</cf> is true, but
517
	  <cf>1.0.0.0/8 ~ [ 1.0.0.0/8- ]</cf> is false.
513
	  prefixes <cf/3.X.X.X/ whose prefix length is 5 to 6. <cf><m>address</m>/<m>num</m>+</cf> is a shorthand for <cf><m>address</m>/{0,<m/num/}</cf>,
514
	  <cf><m>address</m>/<m/num/-</cf> is a shorthand for <cf><m>address</m>/{0,<m/num-1/}</cf>. For example,
515
	  <cf>1.2.0.0/16 &tilde; [ 1.0.0.0/8{ 15 , 17 } ]</cf> is true, but
516
	  <cf>1.0.0.0/8 &tilde; [ 1.0.0.0/8- ]</cf> is false.
518 517

  
519 518
	<tag/enum/
520 519
	  Enumeration types are fixed in BIRD -- you can't define your own
521
	  variables of enumeration type, but some route attributes are of enumeration
520
	  variables of such type, but some route attributes are of enumeration
522 521
	  type. Enumeration types are incompatible with each other.
523 522

  
524 523
	<tag/bgppath/
......
542 541

  
543 542
<sect>Operators
544 543

  
545
<!-- Sorry, birddoc does not support tables. -->
546

  
547 544
<p>The filter language supports common integer operators <cf>(+,-,*,/)</cf>, parentheses <cf/(a*(b+c))/, comparison
548 545
<cf/(a=b, a!=b, a&lt;b, a&gt;=b)/. Logical operations include unary not (<cf/!/), and (<cf/&&/) and or (<cf/||/). 
549
Special operators include <cf/&tilde;/ for "in" operation. In operation can be
550
used on element and set of that elements (returning true if element is within given set), or on IP and prefix (returning true if IP is within range defined by that prefix), or on
551
prefix and prefix (returning true if first prefix is more specific than second) or on bgppath and bgpmask (returning true if path matches given path mask) or on pair and clist (returning true if given community is element of community list).
546
Special operators include <cf/&tilde;/ for "is element of a set" operation - it can be
547
used on element and set of elements of the same type (returning true if element is contained in the given set), or on IP and prefix (returning true if IP is within the range defined by that prefix), or on
548
prefix and prefix (returning true if first prefix is more specific than second one) or on bgppath and bgpmask (returning true if the path matches the mask) or on pair and clist (returning true if the community is element of the community list).
552 549

  
553 550

  
554 551
<sect>Control structures
555 552

  
556 553
<p>Filters support two control structures: conditions and case switches. 
557 554

  
558
<p>Syntax of condition is <cf>if
555
<p>Syntax of a condition is: <cf>if
559 556
<M>boolean expression</M> then <M>command1</M>; else <M>command2</M>;</cf> and you can use <cf>{
560
<M>command_1</M>; <M>command_2</M>; <M>...</M> }</cf> instead of one or both commands. <cf>else</cf>
561
clause may be omitted. If <cf><m>boolean expression</m></cf> is true, <cf><m>command1</m></cf> is executed, otherwise <cf><m>command2</m></cf> is executed.
557
<M>command_1</M>; <M>command_2</M>; <M>...</M> }</cf> instead of either command. The <cf>else</cf>
558
clause may be omitted. If the <cf><m>boolean expression</m></cf> is true, <cf><m>command1</m></cf> is executed, otherwise <cf><m>command2</m></cf> is executed.
562 559

  
563
<p><cf>case</cf> is similar to case from Pascal. Syntax is <cf>case <m/expr/ { else |
564
<m/num_or_prefix [ .. num_or_prefix]/: <m/statement/ ; [ ... ] }</cf>. Expression after
565
<cf>case</cf> can be of any type that can be on the left side of the &tilde; operator, and anything that could
566
be a member of a set is allowed before <cf/:/. Multiple commands are allowed without <cf/{}/ grouping
567
and break is implicit before each case. If <cf><m/expr/</cf> matches one of <cf/:/ clauses, statements between it and next <cf/:/ statement are executed. If <cf><m/expr/</cf> matches neither of <cf/:/ clauses, <cf/else:/ statements after <cf/else:/ are executed.
560
<p>The <cf>case</cf> is similar to case from Pascal. Syntax is <cf>case <m/expr/ { else |
561
<m/num_or_prefix [ .. num_or_prefix]/: <m/statement/ ; [ ... ] }</cf>. The expression after
562
<cf>case</cf> can be of any type which can be on the left side of the &tilde; operator and anything that could
563
be a member of a set is allowed before <cf/:/. Multiple commands are allowed without <cf/{}/ grouping.
564
If <cf><m/expr/</cf> matches one of the <cf/:/ clauses, statements between it and next <cf/:/ statement are executed. If <cf><m/expr/</cf> matches neither of the <cf/:/ clauses, the statements after <cf/else:/ are executed.
568 565

  
569 566
<p>Here is example that uses <cf/if/ and <cf/case/ structures:
570 567

  
......
583 580

  
584 581
<sect>Route attributes
585 582

  
586
<p>An filter is implicitly passed route, and it can access its
587
attributes just like it accesses variables. Attempt to access undefined
583
<p>A filter is implicitly passed a route, and it can access its
584
attributes just like it accesses variables. Attempts to access undefined
588 585
attribute result in a runtime error; you can check if an attribute is
589
defined using the <cf>defined( <m>attribute</m> )</cf> operator.
586
defined by using the <cf>defined( <m>attribute</m> )</cf> operator.
590 587

  
591 588
<descrip>
592 589
	<tag><m/prefix/ net</tag>
593
	Network the route is talking about. Read-only. (See the section about routing tables.)
590
	Network the route is talking about. Read-only. (See the chapter about routing tables.)
594 591

  
595 592
	<tag><m/enum/ scope</tag>
596 593
	Address scope of the network (<cf/SCOPE_HOST/ for addresses local to this host, <cf/SCOPE_LINK/ for those specific for a physical link, <cf/SCOPE_SITE/ and <cf/SCOPE_ORGANIZATION/ for private addresses, <cf/SCOPE_UNIVERSE/ for globally visible addresses).
597 594

  
598 595
	<tag><m/int/ preference</tag>
599
	Preference of the route. (See section about routing tables.)
596
	Preference of the route. (See the chapter about routing tables.)
600 597

  
601 598
	<tag><m/ip/ from</tag>
602 599
	The router which the route has originated from. Read-only.
......
614 611
	Type of destination the packets should be sent to (<cf/RTD_ROUTER/ for forwarding to a neighboring router, <cf/RTD_NETWORK/ for routing to a directly-connected network, <cf/RTD_BLACKHOLE/ for packets to be silently discarded, <cf/RTD_UNREACHABLE/, <cf/RTD_PROHIBIT/ for packets that should be returned with ICMP host unreachable / ICMP administratively prohibited messages). Read-only.
615 612
</descrip>
616 613

  
617
<p>There also exist some protocol-specific attributes, which are described in protocol sections.
614
<p>There also exist some protocol-specific attributes which are described in the corresponding protocol sections.
618 615

  
619
<sect>Statements
616
<sect>Other statements
620 617

  
621 618
<p>The following statements are available:
622 619

  
......
625 622

  
626 623
	<tag>accept|reject [ <m/expr/ ]</tag> Accept or reject the route, possibly printing <cf><m>expr</m></cf>.
627 624

  
628
	<tag>return <m/expr/</tag> Return <cf><m>expr</m></cf> from function, the function ends at this point.
625
	<tag>return <m/expr/</tag> Return <cf><m>expr</m></cf> from the current function, the function ends at this point.
629 626

  
630 627
	<tag>print|printn <m/expr/ [<m/, expr.../]</tag>
631 628
	Prints given expressions; useful mainly while debugging
632 629
	filters. The <cf/printn/ variant does not terminate the line.
633 630

  
634 631
	<tag>quitbird</tag>
635
	Terminates BIRD. Useful when debugging filter interpreter.
632
	Terminates BIRD. Useful when debugging the filter interpreter.
636 633
</descrip>
637 634

  
638 635
<chapt>Protocols
......
971 968

  
972 969
<p>Open Shortest Path First (OSPF) is a quite complex interior gateway
973 970
protocol. The current IPv4 version (OSPFv2) is defined in RFC 2328<htmlurl url="ftp://ftp.rfc-editor.org/in-notes/rfc2328.txt">. It's a link
974
state (a.k.a. shortest path first) protocol -- Each router maintains a database
971
state (a.k.a. shortest path first) protocol -- each router maintains a database
975 972
describing the autonomous system's topology. Each participating router
976 973
has an identical copy of the database and all routers run the same algorithm
977 974
calculating a shortest path tree with themselves as a root.
......
981 978
to reduce the amount of resources consumed for exchanging the routing
982 979
information and to protect the other areas from incorrect routing data.
983 980
Topology of the area is hidden to the rest of the autonomous system.
984
Unfortunately multiple OSPF areas are not yet fully supported
981
Unfortunately, multiple OSPF areas are not yet fully supported
985 982
by this version of BIRD and neither is the IPv6 version (OSPFv3).
986 983

  
987 984
<p>Another very important feature of OSPF is that
988 985
it can keep routing information from other protocols (like Static or BGP)
989 986
in its link state database as external routes. Each external route can
990
be tagged by the advertising router, making possible to pass additional
987
be tagged by the advertising router, making it possible to pass additional
991 988
information between routers on the boundary of the autonomous system.
992 989

  
993 990
<p>OSPF quickly detects topological changes in the autonomous system (such
994
as router interface failures) and calculates new loop-free routes after a
995
period of convergence. This period is short and involves only minimal
996
routing traffic.
991
as router interface failures) and calculates new loop-free routes after a short
992
period of convergence. Only a minimal ammount of 
993
routing traffic is involved.
997 994

  
998 995
<p>Each router participating in OSPF routing periodically sends Hello messages
999 996
to all its interfaces. This allows neighbors to be discovered dynamically.
......
1011 1008

  
1012 1009
<code>
1013 1010
protocol ospf &lt;name&gt; {
1014
	rfc1583compat &lt;bool&gt;;
1011
	rfc1583compat &lt;switch&gt;;
1015 1012
	area &lt;id&gt; {
1016
		stub &lt;bool&gt;;
1013
		stub &lt;switch&gt;;
1017 1014
		tick &lt;num&gt;;
1018 1015
		interface &lt;interface pattern&gt;
1019 1016
		{
......
1035 1032
</code>
1036 1033

  
1037 1034
<descrip>
1038
	<tag>rfc1583compat <M>bool</M></tag>
1035
	<tag>rfc1583compat <M>switch</M></tag>
1039 1036
	 This option controls compatibility of routing table
1040 1037
	 calculation with RFC 1583<htmlurl
1041 1038
	 url="ftp://ftp.rfc-editor.org/in-notes/rfc1583.txt">. Default
......
1047 1044
	 The most important area is
1048 1045
	 the backbone (ID 0) to which every other area must be connected.
1049 1046

  
1050
	<tag>stub <M>bool</M></tag>
1047
	<tag>stub <M>switch</M></tag>
1051 1048
	 No external routes are flooded into stub areas. Default value is no.
1052 1049

  
1053 1050
	<tag>tick <M>num</M></tag>
doc/sbase/dist/birddoc/latex2e/mapping
1 1

  
2 2
% birddoc to LaTeX replacement file
3 3

  
4
<book>		+ "\\documentclass\[a4paper,10pt,openany\]{book}\n"
4
% The \relax is there to avoid sgml2latex rewriting the class
5
<book>		+ "\\relax\\documentclass\[a4paper,10pt,openany\]{book}\n"
5 6
			"\\usepackage{birddoc}\n"
6 7
			"\\usepackage{qwertz}\n"
7 8
			"\\usepackage{url}\n"

Also available in: Unified diff