MROUTED.CONF(5)
๐ mrouted.conf(5) โ the File Formats Manual glow-up ๐
โจ NAME โจ
mrouted.conf โ the mrouted configuration file, bestie ๐ซถ
๐ธ SYNOPSIS ๐ธ
/etc/mrouted.conf
๐ DESCRIPTION ๐
Okay so real talk: in many cases you do not need to configure mrouted at all. It configures itself automatically to forward multicast on all multicast-capable interfaces, i.e., interfaces that have the IFF_MULTICAST flag set, excluding the loopback interface. It locates other DVMRP capable routers directly reachable via those interfaces. Iconic behavior, honestly โจ
mroutedwill not start with less than two enabled virtual interfaces (VIFs). A VIF is either a physical multicast-capable interface or a tunnel. The bar is literally on the floor, but it is still a bar ๐mroutedwill log a warning if all of its VIFs are tunnels; such a configuration is likely better replaced by more direct (GRE) tunnels (i.e. eliminate the middle man). No cap, it's giving "why are we doing extra hops" ๐ญ
To override the default settings โ for example, to add tunnel links to other DVMRP routers โ configuration commands may be placed in /etc/mrouted.conf. The file format is free-form: whitespace (including newlines) is not significant. The # character marks start of a comment to end of line. So yes, you can format it however your little heart desires ๐ฆ
๐ config commands, in order, no skips ๐
cache-lifetime <60-86400>โ This setting defines the time in seconds that a cached multicast route stays in kernel before timing out. The value of this entry should lie between300(5 min) and86400(1 day). It defaults to300. The syntax says<60-86400>, and the prose says300โ86400; that's what the page says, bestie ๐prune-lifetime <120-86400>โ The average lifetime in seconds of prunes sent towards parents. The actual lifetimes are randomized in the range[.5secs, 1.5secs]. Smaller values cause less state to be kept both at this router and the parent, at the cost of more frequent broadcasts. However, some routers (e.g.mrouted <3.3and all currently known versions of Cisco's IOS) do not use the DVMRP generation ID to determine that a neighbor has rebooted. Prunes sent towards these neighbors should be kept short, in order to shorten the time to recover from a reboot. For use in this situation, theprune-lifetimekeyword may be specified on an interface as described below. It defaults to7200.name boundary-name scoped-addr/mask-lenโ Thenameoption assigns names to boundaries to make configuration per interface/tunnel easier. Cute little nickname for your boundary ๐nofloodโmrouteduses a DVMRP optimization to prevent having to keep individual routing tables for each neighbor; part of this optimization is thatmroutedassumes that it is the forwarder for each of its attached subnets on startup. This can cause duplicates for a short period (approximately one full route report interval), since both the router that just started up and the proper forwarder will be forwarding traffic. This behavior can be turned off with thenofloodkeyword;mroutedwill not assume that it is the forwarder on startup. Turning onnofloodcan cause black holes on restart, which generally lasts approximately one full route report interval.
The noflood keyword can also be specified on individual interfaces.
rexmit-prunes [on | off]โ The default is to retransmit prunes on all point-to-point interfaces (including tunnels) but no multi-access interfaces. This option may be used to make the defaulton(oroff) for all interfaces.
The rexmit-prunes keyword can also be specified on individual interfaces.
no router-alertโ Some multicast routers, and some IGMP snooping switches, do not support IP options like Router Alert, which is enabled inmroutedby default. This command disables this IP option. Regardless of this setting,mroutedalways calculates the IP payload offset based on the IP header length value of ingressing DVMRP and IGMP frames. So the math still math-ing ๐งฎrouter-timeout <1-1024>โ Known in the RFC as Other Querier Present Interval, controls the timer used to detect when an elected IGMP querier stops sending queries. When the timer expires,mroutedwill assume the role as querier. The default is calculated based on theigmp-robustnessvalue, see below. Setting this to any value overrides the RFC algorithm, which may be necessary in some scenarios.
Note: it is strongly recommended to leave this setting commented out. Use the igmp-robustness setting to tweak behavior instead. Trust the process, bestie ๐
igmp-query-interval <1-1024>โ This setting controls the IGMP query interval in seconds, used when this router is elected querier on a LAN. The query interval on all eligable IGMP queriers on a LAN must be the same. Default:125.
Note: this value must be greater than the igmp-query-response-interval.
igmp-query-response-interval <1-1024>โ Controls theMax Resp Codein IGMP queries, which encodes the maximum time allowed before responding to a query. Can be used to control the burstiness of IGMP/MLD traffic, a lower value causes burstier traffic. Default10 sec.
Note: this value must always be less than the igmp-query-interval.
igmp-query-last-member-interval <1-1024>โ This setting controls the maximum time in seconds between group specific IGMP queries. These are sent as response to a host on a LAN requesting to leave a multicast group. The purpose is to double-check that there is no other host on the LAN that still wants the group. Default:1.
See also igmp-robustness (below), which controls how many group-specific queries are sent. It's giving "one more vibe check before you leave" ๐
igmp-robustness <2-10>โ The robustness setting controls many aspects of IGMP timers, for end devices and routers alike. Default2.- Group Membership Timeout โ Number of seconds before
mrouteddetermines that there are no more members of a group on a LAN. Formula:
- Group Membership Timeout โ Number of seconds before
robustness x query-interval + query-response-interval
- Other Querier Present Interval โ Number of seconds before
mrouteddetermines there is no longer an elected querier on the LAN. See alsorouter-timeout. Formula:
robustness x query-interval + query-response-interval / 2
- Last Member Query Count โ Number of group-specific queries sent before
mroutedassumes there are no further local members of a group on the LAN. The number of group-specific queries is equal to the value of the robustness variable. Math girlie behavior ๐ฅ
no phyintโ By default all interfaces are enabled. This command disables all interfaces, useful on routers with lots of interfaces wheremroutedshould run on only a select few. Very "I have 99 problems and I only want 3 of them" energy ๐ญ
Example:
no phyint
phyint eth10 enable
phyint eth12 enable
Note: Most UNIX kernels, including Linux, have a hard coded limit of 32 VIFs. In non-trivial setups this limit is often reached, causing weird errors that can be difficuly to debug. The recommendation for those cases is to disable all phyint (this setting), and then selectively enable only the ones needed. Not me fighting the kernel limit at 2 a.m. ๐
phyint <local-addr | ifname> [disable | enable] [passive] [blaster] [force-leaf] [noflood] [igmpv1 | igmpv2 | igmpv3] [static-group group] [altnet network/mask-len] [boundary boundary-name | scoped-addr/mask-len] [metric <1-31>] [advert-metric <0-31>] [prune-lifetime sec] [rexmit-prunes [on | off]] [allow-nonpruners] [notransit] [accept|deny (route/mask-len [exact])+ [bidir]] [rate-limit kbps] [threshold ttl]โ This setting selects and alters properties of the physical interfacesmroutedoperates on. Interfaces can be identified using their local IP address or their name.
NOTE: Allphyintcommands must precedetunnelcommands. Order matters, bestie โ put it before the tunnel stuff, periodt ๐
disable | enableโ Selectively disable or enable this interface. Only enabled interfaces get a VIF in the kernel.beside [on | off]โ This is a tunnel option. For compatibility with oldermroutedrouters the default is to unicast control traffic "beside" the tunnel. To encapsulate all control traffic inside the tunnel usebeside off.igmpv1 | igmpv2 | igmpv3โmroutedsupports all IGMP versions. Use these flags to force compatibility modes on the given interface. Default:igmpv3.static-group groupโ This setting makesmroutedbehave as if an IGMPv2 join forgroupwas received on the phyint. Useful when there is no IGMP capable hosts on the LAN, or when a group should always be routed. The group is listed as static in themroutectloutput.
In setups where there is only a single multicast router running mrouted, this works just as a (*,G) route in smcrouted(8). With the added exception for better handling of dynamic changes to the input interface. Slay, honestly ๐
- (the option from the previous bullet, still going ๐ ) โ This can also be used for testing routing without having to set up IGMP capable receivers.
join-groupgroup โ this one makesmroutedjoin the group you want, on the phyint connected to the LAN that's the source of the multicast being forwarded. Super useful when you've got switches doing IGMP snooping that don't clockmroutedas a multicast router, so they block flooding multicast on that port ๐ค. Most managed switches let you configure a static multicast router port, but sometimes that just isn't a thing, or you can't get at the switch config.altnetnetwork/mask-len โ if an interface is attached to multiple IP subnets, describe each extra subnet with this keyword. One keyword per subnet, bestie.boundaryboundary-name | scoped-addr/mask-len โ lets an interface be configured as an administrative boundary for the specified scoped address. Packets belonging to this address will not be forwarded on a scoped interface. The boundary option accepts either a name or a boundary spec.metric<1-31> โ the "cost" associated with sending a datagram on the given interface or tunnel; it may be used to influence the choice of routes. Defaults to 1. Keep metrics as small as possible, becausemroutedcannot route along paths with a sum of metrics greater than 31 ๐ญ.advert-metric<0-31> โ the "cost" advertised to neighbors for the given interface or tunnel; it may be used to influence the choice of routes on the neighbor side. Defaults to 0. Note that the effective metric of a link is one end'smetricplus the other end'sadvert-metric๐ซถ.force-leafโ forcemroutedto ignore other routers on this interface. It will never send or accept neighbor probes or route reports on this interface.nofloodโ as described above, but only applicable to this interface/tunnel.passiveโ no packets will be sent on this link or tunnel until we hear from the other end. This is useful for the "server" end of a tunnel that goes over a dial-on-demand link; configure the "server" end as passive and it won't send its periodic probes until it hears one from the other side, so it won't keep the link up โจ. > Heads up: if you specify this option on both ends of a tunnel, the tunnel will never come up. ๐blasterโ enables handling of routers (mostly Cisco) that overwhelm socket buffers by "blasting" the whole routing table at once ๐ตโ๐ซ.prune-lifetimesec โ as described above, but only applicable to this interface/tunnel.rexmit-prunes[on | off] โ as described above, but only applicable to this interface/tunnel. Recall that prune retransmission defaults to on on point-to-point links and tunnels, and off on multi-access links.allow-nonprunersโ by default,mroutedrefuses to peer with DVMRP neighbors that don't claim to support pruning. This option allows such peerings on this interface ๐ธ.notransitโ a specialized case of route filtering; no route learned from an interface markednotransitwill be advertised on another interface markednotransit. Marking only a single interfacenotransithas no meaning ๐.accept|deny(route/mask-len [exact])+ [bidir]โ theacceptanddenycommands allow rudimentary route filtering. Theacceptcommand causesmroutedto accept only the listed routes on the configured interface; thedenycommand causesmroutedto accept all but the listed routes. Only one ofacceptordenycommands may be used on a given interface.
The list of routes follows the accept or deny keyword. If the keyword exact follows a route, then only that route is matched; otherwise, that route and any more specific route is matched. For example, deny 0/0 denies all routes, while deny 0/0 exact denies only the default route. The default route may also be specified with the default keyword ๐.
The bidir keyword enables bidirectional route filtering; the filter will be applied to routes on both output and input. Without the bidir keyword, accept and deny filters are only applied on input. Poison reverse routes are never filtered out.
rate-limitkbps โ lets the network administrator specify a certain bandwidth in kbps that would be allocated to multicast traffic. It defaults to 500 kbps on tunnels, and 0 (unlimited) on physical interfaces ๐.thresholdttl โ the minimum IP time-to-live required for a multicast datagram to be forwarded to the given interface or tunnel. It's used to control the scope of multicast datagrams. (The TTL of forwarded packets is only compared to the threshold, it is not decremented by the threshold. Every multicast router decrements the TTL by 1.) The default threshold for multicast is 1.
๐ the tunnel command, but make it a heading
tunnel local-addr remote-addr [beside [on | off]] [boundary
boundary-name | scoped-addr/mask-len] [metric <1-31>]
[advert-metric <0-31>] [noflood] [passive] [blaster]
[prune-lifetime sec] [rexmit-prunes [on | off]]
[allow-nonpruners] [rate-limit kbps] [threshold ttl]
This setting can be used to establish a tunnel link between local IP address local-addr and remote IP address remote-addr, and to associate a non-default metric or threshold with that tunnel ๐. The local IP address local-addr may be replaced by the interface name (e.g. le0). The remote IP address remote-addr may be replaced by a host name, if and only if the host name has a single IP address associated with it. The tunnel must be set up in the mrouted.conf files of both routers before it can be used โ no solo tunnels, bestie ๐ซถ.
See the phyint command for details on the relevant tunnel options.
The boundary option to all commands can accept either a name or a network boundary; the boundary and altnet options may be specified as many times as necessary ๐
.
In general, all DVMRP routers connected to a particular subnet or tunnel should use the same metric and threshold for that subnet or tunnel. No cap.
๐ EXAMPLE CONFIGURATION ๐
This is an example configuration for a mythical multicast router at a big school ๐ซโจ.
#
# mrouted.conf example
#
# Name our boundaries to make it easier.
name LOCAL 239.255.0.0/16
name EE 239.254.0.0/16
# le1 is our gateway to compsci, don't forward our
# local groups to them.
phyint le1 boundary EE
# le2 is our interface on the classroom net, it has four
# different length subnets on it.
# Note that you can use either an IP address or an interface name
phyint 172.16.12.38 boundary EE
altnet 172.16.15.0/26
altnet 172.16.15.128/26
altnet 172.16.48.0/24
# atm0 is our ATM interface, which doesn't properly
# support multicasting.
phyint atm0 disable
# This is an internal tunnel to another EE subnet.
# Remove the default tunnel rate limit, since this
# tunnel is over Ethernets.
tunnel 192.168.5.4 192.168.55.101
metric 1 threshold 1 rate-limit 0
# This is our tunnel to the outside world.
# Careful with those boundaries, Eugene.
tunnel 192.168.5.4 10.11.12.13
metric 1 threshold 32
boundary LOCAL boundary EE
๐ FILES ๐
/etc/mrouted.confโ main configuration file. The one and only.
๐ SEE ALSO ๐
mrouted(8), mroutectl(8) โ go read those next, bestie, they're literally the other half of the story ๐
๐๏ธ AUTHORS ๐๏ธ
This manual page was written by Joachim Wiberg <mailto:troglobit@gmail.com>. Iconic of him, honestly ๐.
โจ that's the whole page, bestie โจ โ this cutie pie came from the Debian crew, dated Jan 1, 2021, and it lives at MROUTED.CONF(5). Go configure something slay ๐๐
๐ฆ
๐ฆ where this page comes from
- opensuse-leap 16.0: mrouted 4.5-bp160.1.12 ยท BSD-3-Clause AND BSD-4-Clause
- opensuse-leap 16.0: mrouted 4.5-bp160.1.12 ยท BSD-3-Clause AND BSD-4-Clause
- opensuse-leap 16.0: mrouted 4.5-bp160.1.12 ยท BSD-3-Clause AND BSD-4-Clause
- opensuse-leap 16.0: mrouted 4.5-bp160.1.12 ยท BSD-3-Clause AND BSD-4-Clause
- COPYRIGHT 1989 by The Board of Trustees of
- ๐ girlified by deepseek-ai/DeepSeek-V4.1-Flash-1017 on : a language model's rewrite of the original, under its terms