2 # OLSR.org routing daemon config file
3 # This file contains ALL available options and explanations about them
5 # Lines starting with a # are discarded
8 #### ATTENTION for IPv6 users ####
9 # Because of limitations in the parser IPv6 addresses must NOT
10 # begin with a ":", so please add a "0" as a prefix.
12 ###########################
13 ### Basic configuration ###
14 ###########################
15 # keep this settings at the beginning of your first configuration file
18 # If set to 0 the daemon runs in the background, unless "NoFork" is set to true
23 # IP version to use (4 or 6)
28 #################################
29 ### OLSRd agent configuration ###
30 #################################
31 # this parameters control the settings of the routing agent which are not
32 # related to the OLSR protocol and it's extensions
34 # Clear the screen each time the internal state changes
39 # Should olsrd keep on running even if there are
40 # no interfaces available? This is a good idea
41 # for a PCMCIA/USB hotswap environment.
47 # The lockfile is used to prevent multiple OLSR instances running at the same
49 # (Linux/BSD default is "/var/run/olsrd-ipv(4/6).lock")
50 # (Win32 default is "<configfile>-ipv(4/6).lock")
52 # LockFile "olsrd.lock"
54 # Polling rate for OLSR sockets in seconds (float).
59 # Interval to poll network interfaces for configuration changes (in seconds).
60 # Linux systems can detect interface statechange via netlink sockets.
65 # TOS(type of service) byte value for the IP header of control traffic.
66 # Must be multiple of 4, because OLSR doesn't use ECN
67 # (Default is 192, CS6 - Network Control)
71 # FIBMetric controls the metric value of the host-routes OLSRd sets.
72 # - "flat" means that the metric value is always 2 (or as configured
73 # with FIBMetricDefault). This is the preferred value because it helps
74 # the linux kernel routing to clean up older routes.
75 # - "correct" use the hopcount as the metric value.
76 # - "approx" use the hopcount as the metric value too, but does only update the
77 # hopcount if the nexthop changes too
83 #######################################
84 ### Linux specific OLSRd extensions ###
85 #######################################
86 # these parameters are only working on linux at the moment, but might become
87 # useful on BSD in the future
89 # SrcIpRoutes tells OLSRd to set the Src flag of host routes to the originator-ip
90 # of the node. In addition to this an additional localhost device is created
91 # to make sure the returning traffic can be received.
96 # Specify the proto tag to be used for routes olsr inserts into kernel
97 # currently only implemented for linux
98 # valid values under linux are 1 .. 254
99 # 1 gets remapped by olsrd to 0 UNSPECIFIED (1 is reserved for ICMP redirects)
100 # 2 KERNEL routes (not very wise to use)
101 # 3 BOOT (should in fact not be used by routing daemons)
103 # 8 .. 15 various routing daemons (gated, zebra, bird, & co)
104 # (defaults to 0 which gets replaced by an OS-specific default value
105 # under linux 3 (BOOT) (for backward compatibility)
109 # Specifies the routing Table olsr uses
110 # RtTable is for host routes, RtTableDefault for the route to the default
111 # internet gateway (2 in case of IPv6+NIIT) and RtTableTunnel is for
112 # routes to the ipip tunnels, valid values are 1 to 254
113 # There is a special parameter "auto" (choose default below)
114 # (with smartgw: default is 254/223/224)
115 # (without smartgw: default is 254/254/254, linux main table)
118 # RtTableDefault auto
121 # Specifies the policy rule priorities for the three routing tables and
122 # a special rule for smartgateway routing (see README-Olsr-Extensions)
123 # Priorities can only be set if three different routing tables are set.
124 # if set the values must obey to condition
125 # RtTablePriority < RtTableDefaultOlsrPriority
126 # < RtTableTunnelPriority < RtTableDefaultPriority.
127 # There are two special parameters, "auto" (choose fitting to SmartGW
128 # mode) and "none" (do not set policy rule)
129 # (with smartgw: default is none/32776/32776/32796)
130 # (without smartgw: default is none/none/none/none)
132 # RtTablePriority auto
133 # RtTableDefaultOlsrPriority auto
134 # RtTableTunnelPriority auto
135 # RtTableDefaultPriority auto
137 # Activates (in IPv6 mode) the automatic use of NIIT
138 # (see README-Olsr-Extensions)
143 # Activates the smartgateway ipip tunnel feature.
144 # See README-Olsr-Extensions for a description of smartgateways.
149 # Signals that the server tunnel must always be removed on shutdown,
150 # irrespective of the interface up/down state during startup.
153 # SmartGatewayAlwaysRemoveServerTunnel no
155 # Determines the maximum number of gateways that can be in use at any given
156 # time. This setting is used to mitigate the effects of breaking connections
157 # (due to the selection of a new gateway) on a dynamic network.
160 # SmartGatewayUseCount 1
162 # Determines the take-down percentage for a non-current smart gateway tunnel.
163 # If the cost of the current smart gateway tunnel is less than this percentage
164 # of the cost of the non-current smart gateway tunnel, then the non-current smart
165 # gateway tunnel is taken down because it is then presumed to be 'too expensive'.
166 # This setting is only relevant when SmartGatewayUseCount is larger than 1;
167 # a value of 0 will result in the tunnels not being taken down proactively.
170 # SmartGatewayTakeDownPercentage 0
172 # Determines the policy routing script that is executed during startup and
173 # shutdown of olsrd. The script is only executed when SmartGatewayUseCount
174 # is set to a value larger than 1. The script must setup policy routing
175 # rules such that multi-gateway mode works. A sample script is included.
176 # (default is not set)
178 # SmartGatewayPolicyRoutingScript ""
180 # Determines the egress interfaces that are part of the multi-gateway setup and
181 # therefore only relevant when SmartGatewayUseCount is larger than 1 (in which
182 # case it must be explicitly set).
183 # (default is not set)
185 # SmartGatewayEgressInterfaces ""
187 # Determines the routing tables offset for multi-gateway policy routing tables
188 # See the policy routing script for an explanation.
191 # SmartGatewayTablesOffset 90
193 # Determines the policy routing rules offset for multi-gateway policy routing
194 # rules. See the policy routing script for an explanation.
195 # (default is 0, which indicates that the rules and tables should be aligned and
196 # puts this value at SmartGatewayTablesOffset - # egress interfaces -
199 # SmartGatewayRulesOffset 87
201 # Allows the selection of a smartgateway with NAT (only for IPv4)
204 # SmartGatewayAllowNAT yes
206 # Determines the period (in milliseconds) on which a new smart gateway
207 # selection is performed.
208 # (default is 10000 milliseconds)
210 # SmartGatewayPeriod 10000
212 # Determines the number of times the link state database must be stable
213 # before a new smart gateway is selected.
216 # SmartGatewayStableCount 6
218 # When another gateway than the current one has a cost of less than the cost
219 # of the current gateway multiplied by SmartGatewayThreshold then the smart
220 # gateway is switched to the other gateway. The unit is percentage.
223 # SmartGatewayThreshold 0
225 # The weighing factor for the gateway uplink bandwidth (exit link, uplink).
226 # See README-Olsr-Extensions for a description of smart gateways.
229 # SmartGatewayWeightExitLinkUp 1
231 # The weighing factor for the gateway downlink bandwidth (exit link, downlink).
232 # See README-Olsr-Extensions for a description of smart gateways.
235 # SmartGatewayWeightExitLinkDown 1
237 # The weighing factor for the ETX costs.
238 # See README-Olsr-Extensions for a description of smart gateways.
241 # SmartGatewayWeightEtx 1
243 # The divider for the ETX costs.
244 # See README-Olsr-Extensions for a description of smart gateways.
247 # SmartGatewayDividerEtx 0
249 # Defines what kind of Uplink this node will publish as a
250 # smartgateway. The existence of the uplink is detected by
251 # a route to 0.0.0.0/0, ::ffff:0:0/96 and/or 2000::/3.
252 # possible values are "none", "ipv4", "ipv6", "both"
253 # (default is "both")
255 # SmartGatewayUplink "both"
257 # Specifies if the local ipv4 uplink use NAT
260 # SmartGatewayUplinkNAT yes
262 # Specifies the speed of the uplink in kilobit/s.
263 # First parameter is upstream, second parameter is downstream
264 # (default is 128/1024)
266 # SmartGatewaySpeed 128 1024
268 # Specifies the EXTERNAL ipv6 prefix of the uplink. A prefix
269 # length of more than 64 is not allowed.
272 # SmartGatewayPrefix 0::/0
274 # Set to yes will make OLSRd to set the file
275 # /proc/sys/net/ipv4/ip_forward to 1 during startup. It will be
276 # restored to the original value during shutdown
277 # Set this to no makes OLSRd check the value, if its not 1
278 # OLSRd will exit with an error.
283 ##############################
284 ### OLSR protocol settings ###
285 ##############################
287 # For testing purposes it may be nice to use another port for olsrd
288 # for using another port than the IANA assigned one
289 # for a production network, there should be a good reason!!
290 # valid values are integers >1, please be careful with using reserved
292 # (default is 698, the IANA assigned olsr-port)
296 # Sets the main IP (originator ip) of the router. This IP will NEVER
297 # change during the uptime of olsrd.
298 # (default is 0.0.0.0, which triggers usage of the IP of the first interface)
302 # The fixed willingness to use (0-7)
303 # If not set willingness will be calculated
304 # dynamically based on battery/power status
309 # HNA (Host network association) allows the OLSR to announce
310 # additional IPs or IP subnets to the net that are reachable
312 # Syntax for HNA4 is "network-address network-mask"
313 # Syntax for HNA6 is "network-address prefix-length"
314 # (default is no HNA)
319 # specific small networks reachable through this node
320 # 15.15.0.0 255.255.255.0
326 # specific small networks reachable through this node
327 # fec0:2200:106:0:0:0:0:0 48
331 # Hysteresis for link sensing (only for hopcount metric)
332 # Hysteresis adds more robustness to the link sensing
333 # but delays neighbor registration.
338 # Hysteresis parameters (only for hopcount metric)
339 # Do not alter these unless you know what you are doing!
340 # Set to auto by default. Allowed values are floating point
341 # values in the interval 0,1
342 # THR_LOW must always be lower than THR_HIGH!!
343 # (default is 0.5/0.8/0.3)
350 # Specifies how much neighbor info should be sent in
351 # TC messages. Because of a design problem in the 0.5.x
352 # dijkstra implementation this value must be set to 2.
353 # 2 - send all neighbors
358 # MPR coverage specifies how many MPRs a node should
359 # try select to reach every 2 hop neighbor. Because of
360 # a design problem in the 0.5.x lq mpr selection algorithm
361 # this value should be set to 7.
366 ################################
367 ### OLSR protocol extensions ###
368 ################################
370 # Link quality level switch between hopcount and
371 # cost-based (mostly ETX) routing. Because of
372 # a design problem in the 0.5.x dijkstra algorithm this
373 # value should not be set to 1.
374 # 0 = do not use link quality
375 # 2 = use link quality for MPR selection and routing
380 # Link quality algorithm (only for lq level 2)
381 # (see README-Olsr-Extensions)
382 # - "etx_float", a floating point ETX with exponential aging
383 # - "etx_fpm", same as ext_float, but with integer arithmetic
384 # - "etx_ff" (ETX freifunk), an etx variant which use all OLSR
385 # traffic (instead of only hellos) for ETX calculation
386 # - "etx_ffeth", an incompatible variant of etx_ff that allows
387 # ethernet links with ETX 0.1.
388 # (defaults to "etx_ff")
390 # LinkQualityAlgorithm "etx_ff"
392 # Link quality aging factor (only for lq level 2)
393 # Tuning parameter for etx_float and etx_fpm, smaller values
394 # mean slower changes of ETX value. (allowed values are
395 # between 0.01 and 1.0)
398 # LinkQualityAging 0.05
400 # Fisheye mechanism for TCs (0 meansoff, 1 means on)
403 # LinkQualityFishEye 1
408 # (currently this is only in the freifunk firmware)
409 # If the NAT-Endpoint (the preferred 0/0 HNA emitting node)
410 # is to be changed, the ETX value of the current 0/0 is
411 # multiplied with the NatThreshold value before being
412 # compared to the new one.
413 # The parameter can be a value between 0.1 and 1.0, but
414 # should be close to 1.0 if changed.
415 # WARNING: This parameter should not be used together with
416 # the etx_ffeth metric !!
421 #############################################################
422 ### Configuration of the IPC to the windows GUI interface ###
423 #############################################################
427 # Determines how many simultaneously
428 # IPC connections that will be allowed
429 # Setting this to 0 disables IPC
433 # By default only 127.0.0.1 is allowed
434 # to connect. Here allowed hosts and networks can
439 # Net 192.168.1.0 255.255.255.0
442 #####################################
443 ### Example plugin configurations ###
444 #####################################
445 # Olsrd plugins to load
446 # This must be the absolute path to the file
447 # or the loader will use the following scheme:
448 # - Try the paths in the LD_LIBRARY_PATH
449 # environment variable.
450 # - The list of libraries cached in /etc/ld.so.cache
451 # - /lib, followed by /usr/lib
453 # the examples in this list are for linux, so check if the plugin is
454 # available if you use windows/BSD.
455 # each plugin should have a README file in it's lib subfolder
457 # LoadPlugin "olsrd_httpinfo.dll"
458 LoadPlugin "olsrd_httpinfo.so.0.1"
460 # port number the httpinfo plugin will be listening, default 1978
461 # PlParam "port" "8000"
463 # ip address that can access the plugin, use "0.0.0.0"
465 PlParam "Host" "127.0.0.1"
466 # PlParam "Host" "80.23.53.22"
468 # networks that can access the plugin (ip/netmask)
469 # careful with 0.0.0.0/0, makes (ddos) attacks poss.
470 # PlParam "Net" "0.0.0.0 0.0.0.0"
471 PlParam "Net" "104.0.0.0 255.255.0.0"
472 PlParam "Net" "192.168.0.0 255.255.0.0"
475 # LoadPlugin "olsrd_txtinfo.dll"
476 LoadPlugin "olsrd_txtinfo.so.0.1"
478 # the default port is 2006 but you can change it like this:
479 #PlParam "port" "8080"
481 # You can set a "accept" single address to allow to connect to
482 # txtinfo. If no address is specified, then localhost (127.0.0.1)
483 # is allowed by default. txtinfo will only use the first "accept"
484 # parameter specified and will ignore the rest.
486 # to allow a specific host:
487 #PlParam "accept" "172.29.44.23"
488 # if you set it to 0.0.0.0, it will accept all connections
489 #PlParam "accept" "0.0.0.0"
492 # LoadPlugin "olsrd_jsoninfo.dll"
493 LoadPlugin "olsrd_jsoninfo.so.0.0"
495 # the default port is 2006 but you can change it like this:
496 #PlParam "port" "8080"
498 # You can set a "accept" single address to allow to connect to
499 # jsoninfo. If no address is specified, then localhost (127.0.0.1)
500 # is allowed by default. jsoninfo will only use the first "accept"
501 # parameter specified and will ignore the rest.
503 # to allow a specific host:
504 #PlParam "accept" "172.29.44.23"
505 # if you set it to 0.0.0.0, it will accept all connections
506 #PlParam "accept" "0.0.0.0"
508 # specify a UUID for this node to track it for debugging
509 #PlParam "UUIDFile" "/etc/olsrd/olsrd.uuid"
512 #LoadPlugin "olsrd_secure.so.0.3"
514 # define source of keyfile for secure plugin
515 # see lib/secure/README_SECURE for more information
517 # PlParam "Keyfile" "/etc/olsr-keyfile.txt"
520 #LoadPlugin "olsrd_dyn_gw.so.0.5"
522 # The plugin check interval can be set here in milliseconds.
523 # The default is 1000 ms (1 second).
524 # PlParam "CheckInterval" "5000"
526 # The ping check interval in case there is any pinged host specified.
527 # The default is 5 seconds.
528 # PlParam "PingInterval" "40"
530 # If one or more IPv4 addresses are given, do a ping on these in
531 # descending order to validate that there is not only an entry in
532 # routing table, but also a real network connection. If any of
533 # these addresses could be pinged successfully, the test was
534 # succesful, i.e. if the ping on the 1st address was successful,the
535 # 2nd won't be pinged.
537 # The Ping list applies to the group of HNAs specified above or to the
538 # default internet gateway when no HNA is specified.
540 # Running the plugin without parameters acts as the 'old' dyn_gw_plain.
542 # The following ping entries for the internet gateway
543 # PlParam "Ping" "141.1.1.1"
544 # PlParam "Ping" "194.25.2.129"
546 # First group of HNAs with related ping host
547 # PlParam "HNA" "192.168.80.0 255.255.255.0"
548 # PlParam "HNA" "192.168.81.0 255.255.255.0"
549 # PlParam "Ping" "192.168.81.12"
551 # Second HNA group with multiple related ping hosts.
552 # Specifying multiple ping hosts provides redundancy.
553 # PlParam "HNA" "192.168.100.0 255.255.255.0"
554 # PlParam "HNA" "192.168.101.0 255.255.255.0"
555 # PlParam "HNA" "192.168.102.0 255.255.255.0"
556 # PlParam "Ping" "192.168.100.10"
557 # PlParam "Ping" "192.168.101.10"
559 # Third HNA group without ping check
560 # PlParam "HNA" "192.168.200.0 255.255.255.0"
561 # PlParam "HNA" "192.168.201.0 255.255.255.0"
562 # PlParam "HNA" "192.168.202.0 255.255.255.0"
565 #LoadPlugin "olsrd_dyn_gw_plain.so.0.4"
569 #############################################
570 ### OLSRD default interface configuration ###
571 #############################################
572 # the default interface section can have the same values as the following
573 # interface configuration. It will allow you so set common options for all
577 # Ip4Broadcast 255.255.255.255
580 ######################################
581 ### OLSRd Interfaces configuration ###
582 ######################################
583 # multiple interfaces can be specified for a single configuration block
584 # multiple configuration blocks can be specified
586 # WARNING, don't forget to insert your interface names here !
587 Interface "<OLSRd-Interface1>" "<OLSRd-Interface2>"
589 # Interface Mode is used to prevent unnecessary
590 # packet forwarding on switched ethernet interfaces
591 # valid Modes are "mesh" and "ether"
592 # (default is "mesh")
596 # IPv4 broadcast address for outgoing OLSR packets.
597 # One useful example would be 255.255.255.255
598 # The second useful value would be to
599 # specify the peer address of an ptp-tunnel.
600 # another name of this parameter is "IPv4Multicast"
601 # (default is 0.0.0.0, which triggers the usage of the
602 # interface broadcast IP)
604 # Ip4Broadcast 0.0.0.0
606 # IPv6 multicast address
607 # (default is FF02::6D, the manet-router linklocal multicast)
609 # IPv6Multicast FF02::6D
611 # IPv4 src address for outgoing OLSR packages
612 # (default is 0.0.0.0, which triggers usage of the interface IP)
616 # IPv6 src prefix. OLSRd will choose one of the interface IPs
617 # which matches the prefix of this parameter.
618 # (default is 0::/0, which triggers the usage
619 # of a not-linklocal interface IP)
623 # Emission intervals in seconds.
624 # If not defined, Freifunk network defaults are used
625 # (default is 2.0/20.0 for Hello and 5.0/300.0 for Tc/Mid/Hna)
628 # HelloValidityTime 20.0
630 # TcValidityTime 300.0
632 # MidValidityTime 300.0
634 # HnaValidityTime 300.0
636 # When multiple links exist between hosts
637 # the weight of interface is used to determine
638 # the link to use. Normally the weight is
639 # automatically calculated by olsrd based
640 # on the characteristics of the interface,
641 # but here you can specify a fixed value.
642 # Olsrd will choose links with the lowest value.
644 # Interface weight is used only when LinkQualityLevel is set to 0.
645 # For any other value of LinkQualityLevel, the interface ETX
646 # value is used instead.
649 # If a certain route should be preferred
650 # or ignored by the mesh, the Link Quality
651 # value of a node can be multiplied with a factor
652 # entered here. In the example the route
653 # using 192.168.0.1 would rather be ignored.
654 # A multiplier of 0.5 will result in a small
655 # (bad) LinkQuality value and a high (bad)
658 # Link quality multiplier is used only when
659 # LinkQualityLevel is > 0.
661 # example 1: reduce LQ to 192.168.0.1 by half
662 # LinkQualityMult 192.168.0.1 0.5
664 # example 2: reduce LQ to all nodes on this interface by 20%
665 # LinkQualityMult default 0.8