IEEE 802.1ad is an amendment to the IEEE 802.1Q-1998 networking standard which adds support for provider bridges. It was incorporated into the base 802.1Q standard in 2011.[1] The technique specified by the standard is known informally as stacked VLANs or QinQ.
The original 802.1Q specification allows a single virtual local area network (VLAN) header to be inserted into an Ethernet frame. QinQ allows multiple VLAN tags to be inserted into a single frame, an essential capability for implementing metro Ethernet.
In a multiple-VLAN-header context, out of convenience, the term VLAN tag or just tag for short is often used in place of 802.1Q VLAN header. QinQ allows multiple VLAN tags in an Ethernet frame; together these tags constitute a tag stack. When used in the context of an Ethernet frame, a QinQ frame is a frame that has two VLAN 802.1Q headers (i.e. it is double-tagged).
802.1ad specifies architecture and bridge protocols to provide separate instances of the medium access control (MAC) services to multiple independent users of a bridged local area network in a manner that does not require cooperation among the users and requires a minimum amount of cooperation between the users and the provider of the MAC service.
The idea is to provide, for example, the possibility for customers to run their own VLANs inside a service provider's provided VLAN. This way the service provider can just configure one VLAN for the customer and the customer can then treat that VLAN as if it were a trunk.
IEEE 802.1ad was created for the following reasons:
The IEEE 802.1ad standard was approved December 8, 2005, and published May 26, 2006.
These examples are for an Ethernet II framing with EtherType field. The standard is also applicable to IEEE 802.3 frames with or without an LLC (i.e. Logical Link Control), LLC+SNAP header). The top frame is a simple Ethernet II frame. The middle frame has an 802.1Q tag added to it. The bottom frame has yet another 802.1Q added to it.
An 802.1Q header, which is four bytes long, is added to an untagged Ethernet II frame in the following manner:
Notice that after the insertion of an 802.1Q header to an untagged frame, the frame's original EtherType appears to have been changed to 0x8100. The untagged frame's original EtherType in the single-tag frame is now located adjacent to the payload. Its value is unchanged.
A second 802.1Q header is added to a single-tagged frame in the following manner:
Any third or subsequent tag imposition will insert the tag in front of the preceding tags, closest to the Ethernet header. The frame's original EtherType is always located after all the tags and adjacent to the payload. In the case of an 802.3 frame, this EtherType would be a length value instead, and would contain the length from there to the end of the frame. In the case of an 802.3 frame with an LLC header, the LLC header stays after the length field and adjacent to the payload.
The conventions for 802.1ad terminology typically are as follows:
In IEEE 802.1ad, the single-bit Canonical Format Indicator (CFI) is replaced by a Drop Eligibility Indicator (DEI), increasing the functionality of the PCP field.
In a tag stack, push and pop operations are done at the outer tag end of the stack, therefore the tag added by a tag push operation becomes a new outer tag and the tag to be removed by a tag pop operation is the current outer tag.
This simple example will illustrate the practical use of 802.1ad. The diagram shows switches as hexagons, and a service provider (SP) network encompassing all items within the dotted oval. The items on the periphery of the oval are networks belonging to SP customers. Different physical locations appear in the shaded rectangle and include both customer and SP network components.
A service provider (SP) offers L2 connectivity to customers in the cities of Seattle and Tacoma. Two corporations, Acme and XYZ, each have campuses in both Seattle and Tacoma. All campuses run Ethernet LANs, and the customers intend to connect through the SP's L2 VPN network so that their campuses are in the same LAN (L2 network). It is desirable for each company to have a single LAN available in both Seattle and Tacoma, obviating the alternative of having two LANs in which traffic must be routed between the LANs. The SP has two switches, one in Seattle (S-Switch #1), and one in Tacoma (S-Switch #2). The customers interface to the SP network in switches designated A and B. Each customer has its own pair of A and B switches. Acme switch A is connected to S-Switch #1 through link A1; the rest of the links are labeled. S-Switch #1 and #2 are connected by link S12.
Acme's LAN uses VLAN IDs 10, 11 and 12 in their network. The connections A1 and A2 are Ethernet trunks that have single-tagged VLAN traffic, the traffic using IDs 10, 11 and 12. Likewise XYZ uses IDs 11, 12 and 13 in their network, so X1 and X2 are also trunks with single tagged traffic of IDs 11, 12 and 13. The SP, having one network and one connection between S-Switch #1 and S-Switch #2, must segregate Acme's and XYZ's traffic. Since both Acme and XYZ share some VLAN IDs, traffic cannot be segregated by customer VLAN ID.
The solution is for the SP to use 802.1ad in their network. They assign a single, unique outer VLAN tag ID of 100 for Acme, and a unique outer VLAN ID of 101 for XYZ. All traffic sent from Acme A to the SP network (sent on A1, destined for Acme B) will have a tag of ID 100 pushed. The inner tag will be either 10, 11 or 12, the original Acme tag. The traffic will be sent through S12 in this format, and just before it exits S-Switch #2 bound for Acme B (link A2), all traffic will undergo a single pop operation, removing the outer VLAN tag with the ID 100. This pop operation is the inverse of the former push operation, with the net result of no change to the traffic. The traffic passes through the SP network as 802.1ad frames, but no 802.1ad frames are sent to or received from the customer.
An experienced network engineer will immediately recognize the shortcomings of the above example. This is the reason why 802.1ad is more of a definition for a method of adding multiple tags to a frame than it is an end-to-end self-contained solution. It is used in conjunction with other protocols and standards. The problems with the above example are:
Provider Bridges (802.1ad) and Provider Backbone Bridges (the IEEE 802.1ah-2008 standard) address the above problems by a further modified SAMAC learning method.