ISP Traffic Shaping and Policing

Sun, Sep 7, 2008, by TechDoc

Services

How Internet Service Providers (ISPs) implement and conduct such activities as network traffic policing, shaping and quotas along with bandwidth capacity, throttling and availability in conjunction with download capping and Quality of Service (QoS) issues are all covered.

How Internet Service Providers (ISPs) implement and conduct such activities as network traffic policing, shaping and quotas along with bandwidth capacity, throttling and availability in conjunction with download capping and Quality of Service (QoS) issues are all covered.

ATM Distinguished Service Record

To do this I will present a short summary style review of ATM as a protocol and then discuss the implications of this technology as it applies to the end-user (consumer).

The reason I have elected to use ATM to demonstrate and illustrate these contentious issues is that most consumer ADSL2+ implementations offer PPPoE or PPPoA as their transport protocols (at least here in Australia). PPPoA stands for Point-to-Point Protocol over Asynchronous Transfer Mode while PPPoE means Point-to-Point Protocol over Ethernet.

ATM has a long and distinguished service record for voice communications, is ideally suited to multiplexing environments and can be readily configured to carry VoIP traffic streams. Now for a little background about ATM and all will become clear.

Introducing Asynchronous Transfer Mode (ATM)

Originally intended to be a unified networking strategy Asynchronous Transfer Mode (ATM) is a connection-oriented, circuit-switched, cell relay “Jack-of-all-trades” transport protocol that uses small uniform fixed-sized cells to redress Quality of Service (QoS) issues so important to voice/video communications and the multitude of streaming applications upon which we are all so dependant.

ATM Origins and Development

During development of the standards for the Asynchronous Transfer Mode (ATM), in the mid 1980s, the goals were to create a unified networking strategy that could act as an all-round transport system for real-time video and audio as well as for image, text and email. ATM is pretty much a “Jack-of-all-trades” transport system.

The two groups primarily responsible for the development of the ATM standards were the International Telecommunications Union [ITU 2004] and the ATM Forum [ATM 2004].

Over time we have seen that the majority of implementations and uses that ATM has fulfilled have been primary concerned with telephony and IP networks. Ethernet and the Internet Protocol (IP) are packet-switched network technologies that use packets of variable size referred to as frames.

Asynchronous Transfer Mode (ATM) Protocol Basics

In marked contrast to packet-switched networking technologies; ATM is a connection-oriented, Data Link Layer (OSI Reference Model Layer 2), circuit-switched, cell relay protocol that runs over Synchronous Optical Network (SONET) Physical Layer links (OSI Reference Model Layer 1) using cells of identical and never varying size. Consistent predictability is the underlying ethos here.

Being a connection-oriented channel-based technology means that ATM must always establish a “logical” connection between the two endpoints prior to commencement of data exchange. Significantly, ATM encodes data traffic into small uniform fixed-sized cells. ATM cells are always 53 bytes in size and are comprised of 48 bytes of data and 5 bytes of header information.

ATM Cell Structure

Regardless of the original size of the packets to be transmitted ATM breaks all packets, data, and voice streams into 48-byte chunks and then adds a 5-byte routing header to each one thereby making a total of 53-bytes for each and every cell. The 5-byte header is essential for later reassembly. During development of ATM it was considered that 10% (5 bytes) of each cell (payload) being dedicated to the header for routing information was more than sufficient.

ATM multiplexes these 53-byte cells instead of the larger packets and in so doing reduces the worst-case queuing jitter by a factor of almost 30, thereby removing the need for echo cancellers.

ATM defines two different cell formats: the Network-Network Interface (NNI) and the User-Network Interface (UNI). Most ATM links use the UNI cell format.

ATM Adaption Layers (AAL)

ATM Adaptation Layers (AAL) are the rules for segmenting and reassembling packets and streams into cells. It is the AALs that provide the support for the various services delivered by ATM. AALs may provide constant bit rate services, circuit emulation, variable bit rate services or general data transport services.

Currently, there are five different AALs and the information concerning which one is being used for each cell on a cell-by-cell basis is not contained within the cell or in the cell header. Rather, this information is negotiated by or configured at the endpoints on a per-virtual-connection basis.

ATM Connectivity

Because ATM is a connection-oriented channel-based technology it must establish a “logical” connection between the two endpoints prior to commencement of data exchange. ATM does this by implementing Virtual Circuits, Channels, Paths and Identifiers as follows:

  • Virtual Circuits (VC) – Virtual Circuits (VC) are admirably suited to multiplexing scenarios. Simply by including an 8-bit or 12-bit Virtual Path Identifier (VPI) and a 16-bit Virtual Channel Identifier (VCI) pair in every ATM frame’s header each Virtual Circuit (VC) is uniquely identifiable.
  • Virtual Channel – An ATM Virtual Channel represents the basic means of communication between two end-points. Cells are given a unique identifier called the Virtual Channel Identifier (VCI) which is placed into the ATM cells’ header. All ATM cells containing identical VCIs are transported in the same Virtual Channel.
  • Virtual Path (VP) – A Virtual Path (VP) denotes the transport of ATM cells belonging to virtual channels which share a common identifier called a Virtual Path Identifier (VPI). The VPI is included in the header of every ATM frame. In other words a Virtual Path (VP) is a bunch of Virtual Channels (VC) connecting the same end-points. These will also have a common traffic allocation.
  • Virtual Path Identifier (VPI) – The Virtual Path Identifier’s (VPI) length varies depending on the interface it is sent on (inside the network or on the edge of the network).

ATM Traffic Contracts

When an ATM circuit is set up each ATM switch is informed of the traffic class of the connection. These ATM contracts constitute part of ATM’s Quality of Service (QoS) mechanisms. There are four basic types of contracts: constant bit rate, variable bit rate, available bit rate and unspecified bit rate.

ATM Traffic Shaping and Policing

Now we get to a couple of the basic underpinning capabilities of ATM that ISPs can use at their “godly” discretion to put the brakes on your Internet Surfing and downloading pleasures.

Firstly however; I must point out that when ATM was being developed the developers may have been viewing the world through rose-colored glasses as their primary reasons for incorporating these particular aspects in the ATM protocol were all about network service, performance and quality of service. High ideals indeed but none-the-less crucial for real-time voice and video communications along with many of today’s streaming media applications.

Unfortunately, as is so often the case, many a good intention/idea has been later subverted. Let us have a quick look at them here:

Traffic Shaping – The intended objective of traffic shaping is to ensure that cell flow will meet its traffic contract and is usually done at the entry point to an ATM network.

Traffic Policing – To maintain network performance it is possible to “police” virtual circuits against their traffic contracts. Basic policing works on a cell by cell basis, but this is sub-optimal for encapsulated packet traffic.

Remember traffic contracts are negotiated between customer and service provider on a service-by-service basis. The customer requires a certain amount of bandwidth and pays the service provider accordingly. The service provider for their part agrees to make available and deliver that agreed minimum bandwidth.

For example if a customer required a certain minimum data bandwidth the service provider could ensure that this was met by electing to implement a set specific constant bit rate traffic contract. The ATM switches at either end are configured appropriately and the automatic traffic policing should ensure that this is the way things are.

Service level delivery guarantees are thus monitored automatically and any undesired anomalies or variations can be dealt with by the ATM switches logic. No prizes for guessing that this is not a labor-intensive activity and hence is a favorite with ISPs.

If a circuit is exceeding its traffic contract, the network can either drop the cells or mark the Cell Loss Priority (CLP) bit (to identify a cell as being discardable farther down the line). In instances where that part of the ISP’s network carrying the traffic contract bandwidth exceeding traffic is not very busy the ISP can elect not to drop those cells with the CLP bit marked on. Similarly if network traffic is high the ISP can elect to drop said cells.

The problem here is that basic policing works on a cell-by-cell basis. When transferring most data packets ATM will as discussed above chop the frames into 48 byte size chunks, add its 5 byte header and then multiplex them all as a stream. This means that large frames will be carried as a very large number of uniformly-sized 53 byte cells.

Failure of any one of these cells to arrive at the destination will be interpreted as a corrupt frame upon analysis or reassembly at the recipient end and hence the entire frame will be automatically dropped. Simple CRC checking mechanism at the Data Link layer will pick up these errors and automatically drop the frame, even before the entire frame has been received by the Layer 2 device (switches for example).

Thus discarding a single cell will invalidate the whole packet of which the single cell is but one component. The implications are enormous. Traffic policing of the bandwidth constricting type can be effectively and efficiently enforced with a minimum of processing and filtering overheads on the part of those performing the traffic policing (ISP). It also means that cells can be marked as droppable by many different organizations at various points as it travels the Internet.

If you are into conspiracy theories then there is considerable food for thought here.

Another point worthy of consideration here is that ATM uses ATM switches and once the virtual circuits and traffic contracts have been established and configured by the service provider it is pretty much auto-pilot from there on. This means that network traffic policing; from the ISP’s point of view, occurs automatically as part of the normal functional processes of the hardware (the ATM switch). This is most definitely a cost-effective minimal labor required solution.

Your problems start when errors occur in the administrative functionalities particularly between ISP peers. For example, you may decide to upgrade your service traffic contract or are experiencing data transfer corruption problems. Some of these data transfer issues can be the result of a Denial-of-Service attack (DoS) that is not necessarily directed against you specifically. You are just being caught in the backwash.

Unfortunately, another scenario that may adversely be affecting you is if an ATM switch on another network is marking some of the cells comprising your packets as droppable by turning on the CLP bit as they pass through that carrier’s network.

This could arise from one of their customers exceeding their specific traffic contracts and since you are trying to upload or download from that customer traffic intended for you that was initiated by you is adversely affected. Keep in mind that it only takes one cell to be dropped to invalidate the entire frame.

Final Thoughts

One final word is that if you are in the situation of implementing a VoIP solution using a broadband modem router with inbuilt LAN switch via an ADSL2+ service that offers both PPPoE and PPPoA you may be best advised to implement a traffic segmentation solution by using PPPoE for standard data traffic and PPPoA for voice.

My home D-Link DSL-504 ADSL modem/router has been doing precisely this without any troubles for neigh on six months now. I guess just sometimes the world was meant to be easy. I will present another article shortly showing precisely how this is done. Screen shots will be included as I have just decided that I will make it a walk-through style presentation.

8
Liked it

Leave a Reply