In association with heise online

Intelligent traffic signalling

The user-side solution is called traffic shaping. Traffic shapers direct network traffic in order to control latency. This involves categorising internet packets and varying the speed with which they are sent on their way depending on their priority.

image 3 [250 x 202 Pixel @ 34,9 KB]
Zoom Traffic shaping application cFosSpeed by default assigns high priority to all VoIP programs, thereby ensuring better telephone quality.
The simplest method is prioritisation of ACK packets. This alone increases download speed, as acknowledgements are sent without delay. This is just the start, however - in principle all data streams sent from a PC should be prioritised according to their importance to the user.

Traffic shaping applications are available for various operating systems, including FreeBSD, Mac OS X, Linux and Windows (cFos and cFosSpeed, and, NetLimiter). A freeware tool, Throttled, which provides a front end for functions already present in the firewall, is available for FreeBSD and Mac OS X. Linux has a packet scheduler in the kernel, which works in conjunction with the layer 7 packet classifier. The latter recognises packets from specific applications from their content and can thus prioritise them. Many routers can also forward ACK packets more quickly. Some, such as Fritz!Box Fon, prioritise sending of Voice over IP packets, and high end routers even prioritise all internet traffic which they are able to categorise.

Ideally traffic shaping should take place centrally, usually at the router. The traffic shaper can then prioritise outgoing internet-bound traffic for all LAN subscribers. To do so, it needs to be familiar with as many protocols as possible - which is not usually many in practice. Identifying packets from Skype, for example, can be difficult, as can encrypted communications from BitTorrent. Although both PC and router can analyse packets, the PC has the advantage that it can identify data streams from unknown protocols based on the program name.

Traffic shapers have a whole range of tricks up their sleeves to keep data traffic flowing in widely varying communication situations. Some work with a fixed or automatically generated set of parameters, others offer users extensive control. Users who are so inclined can prioritise individual connections by IP address, port number, layer 7 protocol, program name and various other criteria.

By default, cFos, for example, provides various priority queues. The program always preferentially forwards high priority data. The queue capacity is limited to three seconds - if it exceeds this, the traffic shaper discards data packets which would extend the length of the queue - otherwise they will take too long to send. The TCP stack concludes from this that the capacity of this stretch is currently fully utilised and tries again later using a lower bandwidth. In practice, the high priority queues never overflow. cFos warrants low priority queues a minimum throughput (25 per cent of upstream capacity), so that slow TCP connections are not hung out to dry completely.

To illustrate how traffic shapers can optimise TCP communication, it's helpful to look at examples with various downloads and uploads over an ADSL connection with and without traffic shaping. This shows that download throughput without traffic shaping – despite an adequate window size – is significantly less than the physical download rate of 2Mbit/s. The throughput throttles table lists the figures for a test PC, which achieves a speed of 230kB/s when downloading unimpeded, but only 130kB/s when data is being uploaded at the same time - thus leaving half of the downstream bandwidth idle.

Print Version | Permalink: http://h-online.com/-747378
  • Twitter
  • Facebook
  • submit to slashdot
  • StumbleUpon
  • submit to reddit
 


  • July's Community Calendar





The H Open

The H Security

The H Developer

The H Internet Toolkit