troglobit/man
SMCROUTE.CONF(5) File Formats Manual SMCROUTE.CONF(5)

smcroute.conf —
smcrouted configuration file format

The file smcroute.conf is, strictly speaking, not critical to the operation of smcrouted. With no smcroute.conf present, the daemon starts up and waits for commands from smcroutectl(8), allocating a VIF for each interface as it is first referenced. Any non-trivial setup, however, requires an smcroute.conf.
On most systems the configuration file(s) are available in:
/etc/smcroute.conf
The traditional location, with all routes, group joins, and interfaces.
/etc/smcroute.d/*.conf
Recently an include directive was added to smcroute.conf, which allows for including other files. By convention /etc/smcroute.d/ has been selected as the default in the bundled example smcroute.conf. See more about the include directive below.
In debug mode, smcrouted logs the success of parsing each line and setting up a route. There is also a basic syntax validator built-in, see smcrouted(8) for more information.
Static routes and group memberships are set up with mroute and mgroup. Optionally, routes can also follow the group memberships hosts announce: the upstream and downstream flags on phyint enable IGMP/MLD proxying, RFC 4605, where smcrouted is the querier towards the hosts and forwards what they join. The querier timers are global settings. Static routes and proxying can be combined.

This section details the syntax of each of the available configuration file directives.
Comments start with “#” and run to the end of line. A line ending in a backslash continues on the next line. See the EXAMPLE below.
SEC
Seconds between the general queries sent as querier on a downstream interface, 1 to 1024, default 125. Values below 10 are not recommended. Can be overridden per interface with the phyint option query-interval.
SEC
Maximum response time hosts get for a general query, 1 to 1024, default 10. A longer time spreads the reports out. It is capped at the query interval of the interface.
SEC
Seconds between the group specific queries sent after a leave, 1 to 1024, default 1. The number of such queries is the robustness.
NUM
Tolerance to lost packets, 2 to 10, default 2. Also the number of queries in the startup burst.
SEC
Time to wait for a silent querier before taking over, the other querier present interval, 1 to 1024. When unset it is calculated per interface, RFC 3376 §8.5, from the interface's query interval:
robustness * query-interval + response-interval / 2
    
Set it only to interoperate with devices that do not follow the RFC.
|
IP option Router Alert on the queries sent, RFC 3376 §4.1.3 and RFC 3810 §5, on by default. Turn it off for hosts whose IP stack hard-codes the IP header length and drops packets with options, seen in industrial devices.
|
General query when a port of a bridge starts forwarding, on by default. Link up, STP settling and a port added to the bridge all count. Hosts behind the port are back in the bridge's multicast database within the response interval instead of at the next periodic query, RFC 4541 §2.1.1. Sent only while smcrouted is the querier, at most once a second per interface, followed by the startup burst. Applies to a downstream that is the bridge itself or a VLAN interface on top of it. Linux only.
IFNAME [
enable | disable
] [
mrdisc
] [
upstream | downstream
] [
proxy-querier
] [
ttl-threshold TTL
] [
query-interval SEC
]
smcrouted maps interfaces to virtual interfaces (VIFs), which the multicast routing stack actually employs. VIFs are allocated on demand, the first time an interface is referenced from smcroute.conf or smcroutectl(8), so this directive is only needed when you want to set per-interface options such as ttl-threshold or mrdisc, or to keep the interface allocated even though no mroute or mgroup line references it. VIFs are a limited resource — most operating systems support 32 in total — so on hosts with many interfaces only list the ones you actually need.
mrdisc is an IPv4 specific feature flag to enable Multicast Router Discovery protocol, RFC4286, announcement. This standard is supported by some switch (and router) manufacturers and may be used instead of having mgroup statements for all possible multicast groups you may want to forward.
upstream and downstream set up IGMP/MLD proxying, RFC 4605. smcrouted acts as querier towards the hosts on each downstream interface, and as a host towards the router on the upstream interface, subscribing to what the downstream hosts have joined. Multicast from the upstream is forwarded to every downstream with a member for the group, multicast from a downstream to the upstream and to the other downstreams with members. Memberships are tracked per group and, for IGMPv3 and MLDv2 INCLUDE mode reports, per source, so source-specific multicast (SSM) works through the proxy. Source lists of EXCLUDE mode reports are ignored, as in RFC 5790. One upstream interface is supported. Static mroute and mgroup directives can be combined freely with proxying, and smcroutectl(8) show members lists the current state.
A downstream interface without an address of the family sends its queries from the unspecified address, 0.0.0.0 or ::, RFC 4541 §2.1.1.1. Such proxy queries never win a querier election and stop as soon as a querier with an address is heard. Snooping switches accept them, which is what they are for. Hosts ignore MLD queries from ::. proxy-querier forces this even when the interface has an address, for a bridge that should only stand in until a real querier appears. Linux only.
ttl-threshold is a very useful setting to help implement "TTL scoping". I.e., the minimum TTL level a multicast stream must exceed for the kernel to consider it to be routed. The default value (1) means a TTL of 2 or higher is needed for a frame to be forwarded to the routing stack, otherwise it is considered link-local. See smcrouted(8) for more information on multicast scoping.
query-interval overrides global-query-interval on this interface, 1 to 1024 seconds.
Note: all phyint directives must be read by smcrouted before any mgroup or mroute that refer to them! Hence, either place all phyint directives in the main smcroute.conf or, if /etc/smcroute.d/*.conf is used, first in a file named, 00-phyint.conf, or similar.
IIF [
source SOURCE[/LEN]
] group GROUP[/LEN]
Join a multicast group, with optional prefix length, on a given inbound interface (IIF). The source address is optional, but if given a source specific (SSM) join is performed. Every /LEN is translated to as many sources and groups as specified. To attempt to overcome (configured) kernel limitations, smcrouted probes the amount of joins available per socket. When the socket has been exhausted, another one is opened. At most 2048 sockets are opened.
The purpose of joining groups is to use layer-2 signaling to inform switches, and other routers, to open up multicast traffic to your interfaces. Leaving a group is not supported from the configuration file, instead remove the mgroup, or trim its arguments, SIGHUP or smcroutectl reload your daemon.
Note: use of the mgroup command should be avoided if possible. Instead configure "router ports" or similar on the switches (bridges) on your LAN. This to have them direct all the multicast to your router, or direct select groups if they have such capabilities. Usually MAC multicast filters exist.
IIF [
source SOURCE[/LEN]
] group GROUP[/LEN] to OIF [
OIF ...
]
Add a multicast route for packets received on network interface IIF, originating from IP address SOURCE, and sent to the multicast group address GROUP, to the outbound network interface(s) OIF [
OIF ...
].
The interfaces provided as IIF and OIF can be any network interface name available in the system, as long as it has the MULTICAST flag set. Furthermore, the kernel usually only forwards traffic if the interface(s) have an IP address. These are limitations posed by the kernel, not smcrouted.
To add a (*,G) route, either leave SOURCE out completely or set it to 0.0.0.0, and if you want to specify a range, set GROUP/LEN, e.g. 225.0.0.0/24.
If IIF does not yet exist when the configuration is read, the directive is queued. On Linux it is activated automatically as soon as the interface arrives; on other systems on the next reload. Use ‘smcroutectl show pending’ to inspect what is waiting. The same applies to mgroup directives.
PATH
Include another smcroute.conf file, or set of files. Matching is performed using glob(3), and matches are sorted alphabetically. By convention, the example smcroute.conf bundled with smcrouted includes /etc/smcroute.d/*.conf.

smcrouted supports reading and setting up multicast routes from a config file. The default location is /etc/smcroute.conf, but this can be overridden using the -f FILE command line option.
The IIF and OIF arguments below are interface names, or interface wildcards of the form eth+, which matches eth0, eth10, etc. Wildcards are available for inbound interfaces.
# 
# smcroute.conf example 
# 
# Syntax: 
#   global-query-interval <1-1024> 
#   global-response-interval <1-1024> 
#   global-last-member-interval <1-1024> 
#   robustness <2-10> 
#   router-timeout <1-1024> 
#   topology-query <on|off> 
#   router-alert <on|off> 
#   phyint IFNAME <enable|disable> [mrdisc] [upstream|downstream] [proxy-querier] [ttl-threshold <1-255>] [query-interval <1-1024>] 
#   mgroup from IIF [source ADDR[/LEN]] group GROUP[/LEN] 
#   mroute from IIF [source ADDR[/LEN]] group GROUP[/LEN] to OIF [OIF ...] 
#   include /path/to/*.conf 
 
# Assuming smcrouted was started with the `-N` flag.  Enable interfaces 
# required for inbound and outbound traffic.  TTL scoping is enabled on 
# all interfaces, e.g., to use eth0 as n outbound interface (OIF), all 
# multicast frames must have a TTL of 12 or greater when ingressing. 
phyint eth0 enable ttl-threshold 11 
phyint eth1 enable ttl-threshold 3 
phyint eth2 enable ttl-threshold 5 
phyint virbr0 enable ttl-threshold 5 
 
# Instruct the kernel to join the multicast group 225.1.2.3 on interface 
# eth0.  Then add an mroute of the same multicast stream, from the host 
# 192.168.1.42 on interface eth0 and forward to eth1 and eth2. 
mgroup from eth0                     group 225.1.2.3 
mroute from eth0 source 192.168.1.42 group 225.1.2.3 to eth1 eth2 
 
# Similarly, but using source-specific group join 
mgroup from virbr0 source 192.168.123.110 group 225.1.2.4 
mroute from virbr0 source 192.168.123.110 group 225.1.2.4 to eth0 
 
# Allow multicast for group 225.3.2.1, from ANY source, ingressing on 
# interface eth0 to be forwarded to eth1 and eth2.  When the kernel 
# receives a frame from unknown multicast sender, it asks smcrouted who 
# use this "template" to match against, if the ingressing interface and 
# group matches, smcrouted installs an (S,G) route in the kernel MFC. 
mgroup from eth0 group 225.3.2.1 
mroute from eth0 group 225.3.2.1 to eth1 eth2 
 
# The previous is an example of the (*,G) support.  It is also possible 
# to specify a range of such rules. 
mgroup from eth0 group 225.0.0.0/24 
mroute from eth0 group 225.0.0.0/24 to eth1 eth2 
 
# IGMP/MLD proxy, RFC 4605.  Hosts on lan0 join groups, which are 
# then subscribed to on wan0 and forwarded to lan0. 
phyint wan0 enable upstream 
phyint lan0 enable downstream 
 
# Include any snippet in /etc/smcroute.d/, but please remember that 
# all phyint statements must be read first. 
include /etc/smcroute.d/*.conf

The source address is optional for both IPv4 and IPv6 multicast routes, this is called (*,G) routing. When omitted, smcrouted dynamically installs (S,G) routes, matching the group and inbound interface, to the kernel when it learns of new inbound multicast. This feature was inherited from mrouted(8), and may not work as intended in all use-cases. Also, depending on kernel and CPU load, account for the setup time to detect and install the route, expect at least one initial frame to be lost when using (*,G) rules.

/etc/smcroute.conf, /etc/smcroute.d/*.conf

smcrouted(8), smcroute.conf(5)

SMCRoute was originally created by Carsten Schill <carsten@cschill.de>. Initial IPv6 support by Todd Hayton <todd.hayton@gmail.com>. Initial FreeBSD support by Micha Lenk <micha@debian.org>.
SMCRoute is currently maintained by Joachim Wiberg <troglobit@gmail.com>, and Micha Lenk <micha@debian.org> at GitHub.
June 9, 2026 Debian

Maintained in troglobit/smcroute as man/smcroute.conf.5. Send corrections there, or read it on the mirror.