Multicast: Difference between revisions
No edit summary |
|||
(3 intermediate revisions by the same user not shown) | |||
Line 1: | Line 1: | ||
=External= | |||
* http://www.tldp.org/HOWTO/text/Multicast-HOWTO | |||
* http://www.ibiblio.org/pub/Linux/docs/HOWTO/other-formats/html_single/Multicast-HOWTO.html | |||
* http://andrew.triumf.ca/pub/linux/multicast-FAQ | |||
* Good extensive article on multicast http://www.6test.edu.cn/~lujx/linux_networking/0131777203_ch17lev1sec2.html | |||
* Multicast data path in the Linux kernel http://www.6test.edu.cn/~lujx/linux_networking/0131777203_ch17lev1sec4.html#ch17lev2sec11 | |||
=Internal= | =Internal= | ||
* [[Linux Network Concepts#Subjects|Linux Network Concepts]] | * [[Linux Network Concepts#Subjects|Linux Network Concepts]] | ||
* [[Java Network Traffic Generator]] | |||
=Overview= | =Overview= | ||
Line 23: | Line 32: | ||
* 224.0.0.4 is the ''all DVMRP routers'', etc. | * 224.0.0.4 is the ''all DVMRP routers'', etc. | ||
=Sending Multicast Datagrams= | |||
In principle, an application just needs to open a UDP socket and fill with a class D multicast address the destination address where it wants to send data to. A Java test application that can be used to send multicast is described here [[Java Network Traffic Generator]]. | |||
=Configuration= | =Configuration= | ||
{{Internal|Linux 7 Multicast Configuration|Linux 7 Multicast Configuration}} | {{Internal|Linux 7 Multicast Configuration|Linux 7 Multicast Configuration}} |
Latest revision as of 22:18, 13 July 2017
External
- http://www.tldp.org/HOWTO/text/Multicast-HOWTO
- http://www.ibiblio.org/pub/Linux/docs/HOWTO/other-formats/html_single/Multicast-HOWTO.html
- http://andrew.triumf.ca/pub/linux/multicast-FAQ
- Good extensive article on multicast http://www.6test.edu.cn/~lujx/linux_networking/0131777203_ch17lev1sec2.html
- Multicast data path in the Linux kernel http://www.6test.edu.cn/~lujx/linux_networking/0131777203_ch17lev1sec4.html#ch17lev2sec11
Internal
Overview
Multicast is a network communication mode where packets are sent to a certain special (multicast) address and distributed to all hosts which have registered with that multicast address. A host that registered with a multicast address, it is said that the host has joined that group in the interface you specified. The packets are IP packets, and are routed at kernel level like any other IP packets, with the difference that the kernel routing algorithm is multicast-specific.
Multicast Addresses
The multicast addresses are "Class D Addresses", in the range 224.0.0.0 - 239.255.255.255. The first four bits are always "1110". The remaining 28 bits identify the multicast group.
The range 224.0.0.0 through 224.0.0.255 is reserved for local purposes (as administrative and maintenance tasks) and datagrams destined to them are never forwarded by multicast routers. Similarly, the range 239.0.0.0 to 239.255.255.255 has been reserved for "administrative scoping"
When configuring the multicast route, the netmask must be 11110000000000000000000000000000 Alternatively 240.0.0.0 and /4 can be used,
More about address classes is available here
Well-Known Multicast Groups
- 224.0.0.1 is the all-hosts group. If this group is pinged, all multicast capable host on the network should answer, as every multicast capable host must join that group at start-up on all its multicast capable interfaces.
- 224.0.0.2 is the all-routers group.
- 224.0.0.4 is the all DVMRP routers, etc.
Sending Multicast Datagrams
In principle, an application just needs to open a UDP socket and fill with a class D multicast address the destination address where it wants to send data to. A Java test application that can be used to send multicast is described here Java Network Traffic Generator.