IP Multicast

From Teknologisk videncenter
Revision as of 07:49, 27 February 2009 by Heth (talk | contribs) (Architecture)
Jump to: navigation, search

Architecture

A network designed to deliver a multicast service (like video) using IGMP might use this basic architecture:

Multicast Architecture showing PIM and IGMP

IGMP is used both by the client computer and the adjacent network switches to connect the client to a local multicast router. Protocol Independent Multicast (PIM) is then used between the local and remote multicast routers, to direct multicast traffic from the video server to many multicast clients.

Multicast Applications

One-to-Many

where one sender sends data to many receivers.

  • This type of application may be used for audio or video distribution, push media, announcements, monitoring, and so on.
  • If a one-to-many application needs feedback from receivers, it becomes a many-to-many application

Many-to-Many

where a host can be a sender and a receiver simultaneously or where two or more receivers also act as senders.

  • Receiving data from several sources increases the complexity of applications and creates different management challenges.
  • Using a many-to-many multicast concept as a foundation, a whole new range of applications may be built (for example, collaboration, concurrent processing, and distributed interactive simulations).

Many-to-One

where many receivers are sending data back to one sender.

  • Used by financial applications and networks. Other uses include resource discovery, data collection, auctions, and polling.

IP multicast Addresses

IP Multicast addresses ranging from from 224.0.0.0 to 239.255.255.255 are divided into three multicast address groups.

IPv4 Multicast Address groups
From to Range
224.0.0.0 224.0.0.255 Reserved link, Local addresses
224.0.1.0 238.255.255.255 Globally scoped addresses
239.0.0.0 239.255.255.255 Limited Scope addresses

Locally scoped (reserved link local) addresses

  • Reserved by the Internet Assigned Numbers Authority (IANA) for network protocol use.
  • Address range is from 224.0.0.0 through 224.0.0.255.
  • Multicasts in this range are never forwarded off the local network, regardless of Time to Live (TTL). Usually, the TTL is set to 1.
Some local Scope Multicast addresses
Address Meaning
224.0.0.1 All multicast Systems on a subnet
224.0.0.2 All multicast Routers on a subnet
224.0.0.4 All Distant vector multicast routing protocol routers
224.0.0.5 All OSPF Routers
224.0.0.6 All OSPF designated Routers
224.0.0.9 All RIPv2 Routers
224.0.0.10 All EIGRP Routers
224.0.0.13 All PIMv2 Routers

Globally scoped addresses

  • Allocated dynamically throughout the Internet.
  • Address range is from 224.0.1.0 through 238.255.255.255.
  • The 224.2.X.X range is used in Multicast Backbone (Mbone) applications. Established by the Internet Engineering Task Force (IETF) to multicast audio and video meetings, Mbone is a collection of Internet routers that support IP multicasting on which various public and private audio and video programs are sent.

Limited (administratively) scoped addresses

  • Reserved for use inside private domains. Similar to the private IP address space that is used within the boundaries of a single organization, limited or administratively scoped addresses are constrained to a local group or organization.
  • Address range is from 239.0.0.0 through 239.255.255.255.
  • Organizations can use limited scope addresses to have local multicast applications that will not be forwarded over the Internet.
  • Within an autonomous system or domain, the limited scope address range can be further subdivided so that local multicast boundaries can be defined. This subdivision is called address scoping and allows for address reuse between smaller domains. The administratively scoped multicast address space is divided into the following scopes:
  • Organization-local scope (239.192.0.0 to 239.251.255.255)
  • Site-local scope (239.255.0.0/16, with 239.252.0.0/16, 239.253.0.0/16, and 239.254.0.0/16 also reserved)

Layer 2 Multicast addressing

IP Multicast MAC address mapping on Ethernet

On Ethernet the IP multicast address is converted to a Ethernet Multicast address.

  • IPv4 addresses are 32 bits wide.
  • Ethernet MAC Addresses are 48 bits wide.

Because the IP address are shorter than the MAC address a direct conversion is not possible.

Multicast to Macaddress.png

How does a router or a switch relate a multicast IP address with a MAC address? Normally, network interface cards (NICs) on a LAN segment only receive packets destined for their burned-in MAC address. However, there is no Address Resolution Protocol (ARP) equivalent for multicast address mapping.

Instead, IANA has set aside the vendor code portion of the reserved Organizationally Unique Identifier (OUI) value to identify multicast MAC addresses. Multicast MAC addresses always begin with the low-order bit (0x01) in the first octet. Specifically, the 0x01005e prefix (plus the next lower bit, which is zero) has been reserved for mapping Layer 3 IP multicast addresses into Layer 2 MAC addresses. The complete multicast MAC address range is from 0100.5e00.0000 through 0100.5e7f.ffff.

This makes the first 25 bits of the MAC address fixed (24 bits plus the zero bit) and allows for the last 23 bits of the MAC address to correspond to the last 23 bits in the IP multicast group address. The translation between IP multicast and MAC address is achieved by the mapping of the low-order 23 bits of the IP (Layer 3) multicast address into the low-order 23 bits of the IEEE (Layer 2) MAC address.

There are 28 bits of unique address space for an IP multicast address (32 minus the first four bits containing the 1110 Class D prefix), and there are only 23 bits mapped into the IEEE MAC address. Therefore, five bits of the IP address are unused and not transferred into the MAC address, which means that there are five bits of overlap.

The result is that two (or more) different IP multicast addresses may map to the same MAC multicast address. For example, 224.1.1.1 and 225.1.1.1 map to the same multicast MAC address. If one user subscribed to Group A (as designated by 224.1.1.1) and the other user subscribed to Group B (as designated by 225.1.1.1), they would both receive both A and B streams at Layer 2. At Layer 3, however, only the packets associated with the IP address of the selected multicast group would be viewable, because the port ranges used within the address is different between aliased streams.

This gives the possibility that 32 different multicast IP addresses could all correspond to a single multicast MAC address. For example, all the IP multicast addresses in Figure map to the same Layer 2 multicast of 01-00-5e-0a-00-01.

Network administrators should consider this when assigning IP multicast addresses.

IGMP

Internet Group Management Protocol (IGMP)
IGMP is a host-to-router protocol used when hosts want to join a multicast group. With IGMPv1, routers send periodic membership queries to the multicast address 224.0.0.1. Hosts send membership reports to the group multicast address they want to join. Hosts silently leave the multicast group.

  • IGMP has evolved through three versions (1, 2, and 3).
  • Understanding this protocol is fundamental in defining the multicast group membership join and leave process, which is a required function of multicasting.