README
1README
2======
3[![Build Status](https://travis-ci.org/troglobit/mrouted.png?branch=master)](https://travis-ci.org/troglobit/mrouted)[![Coverity Scan Status](https://scan.coverity.com/projects/3320/badge.svg)](https://scan.coverity.com/projects/3320)
4
5mrouted is a [3-clause BSD](http://en.wikipedia.org/wiki/BSD_licenses)
6licensed implementation of the DVMRP multicast routing protocol. It can
7run on any UNIX based system, from embedded Linux systems to
8workstations, turning them into multicast routers with tunnel support,
9which can be used to cross non-multicast-aware routers.
10
11DVMRP is a distance vector based protocol, derived from RIP, suitable
12for closely located multicast users in smaller networks. It simply
13floods all multicast streams to all routers, i.e. implicit join. This
14is also known as "flood and prune" since you can opt out from groups you
15do not want. For a detailed explanation of the protocol, consult
16[RFC 1075](http://tools.ietf.org/html/rfc1075).
17
18
19History
20-------
21
22The mrouted routing daemon was developed by David Waitzman, Craig
23Partridge, Steve Deering, Ajit Thyagarajan, Bill Fenner, David Thaler
24and Daniel Zappala. With contributions by many others.
25
26The last release by Mr. Fenner was 3.9-beta3 on April 26 1999 and
27mrouted has been in "beta" status since then. Several prominent UNIX
28operating systems, such as AIX, Solaris, HP-UX, BSD/OS, NetBSD, FreeBSD,
29OpenBSD as well as most GNU/Linux based distributions have used that
30beta as a de facto stable release, with (mostly) minor patches for
31system adaptations. Over time however many dropped support, but Debian
32and OpenBSD kept it under their wings.
33
34In March 2003 [OpenBSD](http://www.openbsd.org/), led by the fearless
35Theo de Raadt, managed to convince Stanford to release mrouted under a
36[fully free license](http://www.openbsd.org/cgi-bin/cvsweb/src/usr.sbin/mrouted/LICENSE),
37the [3-clause BSD license](http://en.wikipedia.org/wiki/BSD_licenses).
38Unfortunately, and despite the license issue being corrected by OpenBSD,
39in February 2005
40[Debian dropped mrouted](http://bugs.debian.org/cgi-bin/bugreport.cgi?bug=288112)
41as an "obsolete protocol".
42
43For a long time the OpenBSD team remained the sole guardian of this
44project. In 2010 [Joachim Nilsson](http://troglobit.com) revived
45mrouted on [GitHub](https://github.com/troglobit/mrouted). The 3.9.x
46stable series represent the first releases in over a decade. Patches
47from all over the Internet, including OpenBSD, have been merged.
48
49mrouted is primarily developed on Linux and should work as-is out of the
50box on all major distributions. Other UNIX variants should also work,
51but are not as thoroughly tested. For some tips and details, see the
52`configure` script.
53
54
55Building
56--------
57
58When building mrouted from source you first need to run the `configure`
59script to generate the file `config.mk`. The script relies on Bourne
60shell standard features as well as expr and uname. Any optional mrouted
61features, such as `--enable-rsrr` are activated here as well.
62
63**Example:**
64
65 ./configure --enable-rsrr
66 make
67
68 sudo make install
69
70The Makefile supports de facto standard environment variables such as
71`prefix` and `DESTDIR` for the install process. E.g., to install mrouted
72to `/usr` instead of the default `/usr/local`, but redirect to a binary
73package directory in `/tmp`:
74
75 VERSION=3.9.7-1 prefix=/usr DESTDIR=/tmp/mrouted-3.9.7-1 make clean install
76
77
78Running
79-------
80
81mrouted must run as root.
82
83For the native mrouted tunnel to work in Linux based systems, you need
84to have the "ipip" kernel module loaded or as built-in:
85
86 modprobe ipip
87
88
89Configuration
90-------------
91
92mrouted reads its configuration file from `/etc/mrouted.conf`. You can
93override the default by specifying an alternate file when invoking
94mrouted:
95
96 mrouted -f /path/file.conf
97
98mrouted can be reconfigured at runtime like any regular UNIX daemon,
99simply send it a `SIGHUP` to activate changes to the configuration file.
100The PID is saved automatically to the file `/var/run/mrouted.pid` for
101your scripting needs.
102
103By default, mrouted configures itself to act as a multicast router on
104all multicast capable interfaces, excluding loopback. Therefore, you do
105not need to explicitly configure mrouted, unless you need to setup
106tunnel links, change the default operating parameters, disable multicast
107routing over a specific physical interfaces, or have dynamic interfaces.
108
109For more help, see the man page.
110
111
112Bugs
113----
114
115The basic functionality has been tested thoroughly over the years, but
116that does not mean mrouted is bug free. Please report bugs, feature
117requests, patches and pull requests in the
118[GitHub issue tracker](http://github.com/troglobit/mrouted/issues)
119
120
121RSRR
122----
123
124Routing Support for Resource Reservations (RSRR) is required for running
125RSVP and was contributed by Daniel Zappala <daniel@isi.edu>.
126
127RSRR allows RSVP to query mrouted for its routing entry for a particular
128source-group pair. Using the routing entry and the `IP_MULTICAST_VIF`
129socket call, RSVP can forward distinct control messages out each
130outgoing interface. This version of mrouted supports RSRR messages
131using a Unix datagram socket.
132
133RSRR currently includes two pairs of query-reply messages. RSVP sends
134an Initial Query when it starts. Mrouted responds with an Initial Reply
135that includes the set of vifs it is using, flagging those that are
136administratively disabled. When RSVP needs the routing entry for a
137source-group pair, it sends a Route Query. Mrouted responds with a
138Route Reply that includes the incoming vif and outgoing vifs for the
139source-group pair.
140
141RSVP may request route change notification by setting the notification
142bit in the Route Query. If mrouted can provide route change
143notification for the source-group pair, it sets the notification bit in
144its Route Reply. When the routing entry for the source-group pair
145changes, mrouted sends an unsolicited Route Reply containing the new
146routing information.
147
README.md
1README
2======
3[![Build Status](https://travis-ci.org/troglobit/mrouted.png?branch=master)](https://travis-ci.org/troglobit/mrouted)[![Coverity Scan Status](https://scan.coverity.com/projects/3320/badge.svg)](https://scan.coverity.com/projects/3320)
4
5mrouted is a [3-clause BSD](http://en.wikipedia.org/wiki/BSD_licenses)
6licensed implementation of the DVMRP multicast routing protocol. It can
7run on any UNIX based system, from embedded Linux systems to
8workstations, turning them into multicast routers with tunnel support,
9which can be used to cross non-multicast-aware routers.
10
11DVMRP is a distance vector based protocol, derived from RIP, suitable
12for closely located multicast users in smaller networks. It simply
13floods all multicast streams to all routers, i.e. implicit join. This
14is also known as "flood and prune" since you can opt out from groups you
15do not want. For a detailed explanation of the protocol, consult
16[RFC 1075](http://tools.ietf.org/html/rfc1075).
17
18
19History
20-------
21
22The mrouted routing daemon was developed by David Waitzman, Craig
23Partridge, Steve Deering, Ajit Thyagarajan, Bill Fenner, David Thaler
24and Daniel Zappala. With contributions by many others.
25
26The last release by Mr. Fenner was 3.9-beta3 on April 26 1999 and
27mrouted has been in "beta" status since then. Several prominent UNIX
28operating systems, such as AIX, Solaris, HP-UX, BSD/OS, NetBSD, FreeBSD,
29OpenBSD as well as most GNU/Linux based distributions have used that
30beta as a de facto stable release, with (mostly) minor patches for
31system adaptations. Over time however many dropped support, but Debian
32and OpenBSD kept it under their wings.
33
34In March 2003 [OpenBSD](http://www.openbsd.org/), led by the fearless
35Theo de Raadt, managed to convince Stanford to release mrouted under a
36[fully free license](http://www.openbsd.org/cgi-bin/cvsweb/src/usr.sbin/mrouted/LICENSE),
37the [3-clause BSD license](http://en.wikipedia.org/wiki/BSD_licenses).
38Unfortunately, and despite the license issue being corrected by OpenBSD,
39in February 2005
40[Debian dropped mrouted](http://bugs.debian.org/cgi-bin/bugreport.cgi?bug=288112)
41as an "obsolete protocol".
42
43For a long time the OpenBSD team remained the sole guardian of this
44project. In 2010 [Joachim Nilsson](http://troglobit.com) revived
45mrouted on [GitHub](https://github.com/troglobit/mrouted). The 3.9.x
46stable series represent the first releases in over a decade. Patches
47from all over the Internet, including OpenBSD, have been merged.
48
49mrouted is primarily developed on Linux and should work as-is out of the
50box on all major distributions. Other UNIX variants should also work,
51but are not as thoroughly tested. For some tips and details, see the
52`configure` script.
53
54
55Building
56--------
57
58When building mrouted from source you first need to run the `configure`
59script to generate the file `config.mk`. The script relies on Bourne
60shell standard features as well as expr and uname. Any optional mrouted
61features, such as `--enable-rsrr` are activated here as well.
62
63**Example:**
64
65 ./configure --enable-rsrr
66 make
67
68 sudo make install
69
70The Makefile supports de facto standard environment variables such as
71`prefix` and `DESTDIR` for the install process. E.g., to install mrouted
72to `/usr` instead of the default `/usr/local`, but redirect to a binary
73package directory in `/tmp`:
74
75 VERSION=3.9.7-1 prefix=/usr DESTDIR=/tmp/mrouted-3.9.7-1 make clean install
76
77
78Running
79-------
80
81mrouted must run as root.
82
83For the native mrouted tunnel to work in Linux based systems, you need
84to have the "ipip" kernel module loaded or as built-in:
85
86 modprobe ipip
87
88
89Configuration
90-------------
91
92mrouted reads its configuration file from `/etc/mrouted.conf`. You can
93override the default by specifying an alternate file when invoking
94mrouted:
95
96 mrouted -f /path/file.conf
97
98mrouted can be reconfigured at runtime like any regular UNIX daemon,
99simply send it a `SIGHUP` to activate changes to the configuration file.
100The PID is saved automatically to the file `/var/run/mrouted.pid` for
101your scripting needs.
102
103By default, mrouted configures itself to act as a multicast router on
104all multicast capable interfaces, excluding loopback. Therefore, you do
105not need to explicitly configure mrouted, unless you need to setup
106tunnel links, change the default operating parameters, disable multicast
107routing over a specific physical interfaces, or have dynamic interfaces.
108
109For more help, see the man page.
110
111
112Bugs
113----
114
115The basic functionality has been tested thoroughly over the years, but
116that does not mean mrouted is bug free. Please report bugs, feature
117requests, patches and pull requests in the
118[GitHub issue tracker](http://github.com/troglobit/mrouted/issues)
119
120
121RSRR
122----
123
124Routing Support for Resource Reservations (RSRR) is required for running
125RSVP and was contributed by Daniel Zappala <daniel@isi.edu>.
126
127RSRR allows RSVP to query mrouted for its routing entry for a particular
128source-group pair. Using the routing entry and the `IP_MULTICAST_VIF`
129socket call, RSVP can forward distinct control messages out each
130outgoing interface. This version of mrouted supports RSRR messages
131using a Unix datagram socket.
132
133RSRR currently includes two pairs of query-reply messages. RSVP sends
134an Initial Query when it starts. Mrouted responds with an Initial Reply
135that includes the set of vifs it is using, flagging those that are
136administratively disabled. When RSVP needs the routing entry for a
137source-group pair, it sends a Route Query. Mrouted responds with a
138Route Reply that includes the incoming vif and outgoing vifs for the
139source-group pair.
140
141RSVP may request route change notification by setting the notification
142bit in the Route Query. If mrouted can provide route change
143notification for the source-group pair, it sets the notification bit in
144its Route Reply. When the routing entry for the source-group pair
145changes, mrouted sends an unsolicited Route Reply containing the new
146routing information.
147