[ Contents] [ Prev] [ Next] [ Index] [ Report an Error]

Defining Classifiers and Forwarding Classes

By defining classifiers you associate incoming packets with a forwarding class and loss priority. Based on the associated forwarding class, you assign packets to output queues. To configure classifiers, you specify the bit pattern for the different types of traffic. The classifier takes this bit pattern and attempts to match it to the type of packet arriving on the interface. If the information in the packet’s header matches the specified pattern, the packet is sent to the appropriate queue, defined by the forwarding class associated with the classifier.

In this example, an IP precedence classifier, classify_input, is assigned to all incoming traffic. The precedence bit value in the type of service (ToS) field is assumed to be 000 for all incoming data traffic and 010 for all incoming voice traffic. This classifier assigns all data traffic to Q0 and all voice traffic to Q2. On a Services Router, when LFI is enabled, all traffic assigned to Q2 is treated as LFI (voice) traffic. You do not need to assign network control traffic to a queue explicitly, because it is assigned to Q3 by default.

For more information about configuring CoS components, see the J-series Services Router Advanced WAN Access Configuration Guide.

To define classifiers and forwarding classes:

  1. Navigate to the top of the interfaces configuration hierarchy in either the J-Web or CLI configuration editor.
  2. Perform the configuration tasks described in Table 94 on Router R0 and Router R1.
  3. Go on to Defining and Applying Scheduler Maps.

Table 94: Defining Classifiers and Forwarding Classes

Task

J-Web Configuration Editor

CLI Configuration Editor

Navigate to the Class of service level in the configuration hierarchy.

  1. In the J-Web interface, select Configuration>View and Edit>Edit Configuration.
  2. Next to Class of service, click Configure or Edit.

From the [edit] hierarchy level, enter

edit class-of-service

Configure a behavior aggregate (BA) classifier for classifying packets.

In this example, you specify the default IP precedence classifier, which maps IP precedence bits to forwarding classes and loss priorities.

  1. Next to Classifiers, click Configure.
  2. Next to Inet precedence, click Add new entry.
  3. In the Name box, type classify_input.

Enter

edit classifiers inet-precedence classify_input

For the classifier to assign an output queue to each packet, it must associate the packet with a forwarding class.

Assign packets with IP precedence bits 000 to the DATA forwarding class, and specify a low loss priority.

  1. On the Inet precedence page, next to Forwarding class, click Add new entry.
  2. In the Class name box, type DATA.
  3. Next to Loss priority, click Add new entry.
  4. From the Loss val list, select low.
  5. Next to Code points, click Add new entry.
  6. In the Value box, type 000.
  7. Click OK until you return to the Class of service page.

Enter

set forwarding-class DATA loss-priority low code-points 000

Assign packets with IP precedence bits 010 to the VOICE forwarding class, and specify a low loss priority.

  1. Next to Forwarding class, click Add new entry.
  2. In the Class name box, type VOICE.
  3. Next to Loss priority, click Add new entry.
  4. From the Loss val list, select low.
  5. Next to Code points, click Add new entry.
  6. In the Value box, type 010.
  7. Click OK until you return to the Inet precedence page.

Enter

set forwarding-class VOICE loss-priority low code-points 010

Assign each forwarding class one-to-one with the output queues.

  • DATA—Assign to Queue 0.
  • VOICE—Assign to Queue 2.
  • NC (Network Control)—Assign to Queue 3. NC is assigned to Queue 3 by default.
  1. On the Class of service page, next to Forwarding classes, click Configure.
  2. Next to Queue, click Add new entry.
  3. In the Queue num box, type 0.
  4. In the Class name box, type DATA.
  5. Click OK.
  6. Next to Queue, click Add new entry.
  7. In the Queue num box, type 2.
  8. In the Class name box, type VOICE.
  9. Click OK.
  10. Next to Queue, click Add new entry.
  11. In the Queue num box, type 3.
  12. In the Class name box, type NC.
  13. Click OK until you return to the Class of service page.

From the [edit class-of-service] hierarchy level, enter

set forwarding-classes queue 0 DATA

set forwarding-classes queue 2 VOICE

set forwarding-classes queue 3 NC

Apply the behavior aggregate classifier to the incoming interface.

  1. On the Class of service page, next to Interfaces, click Add new entry.
  2. In the Interface name box, type ge-0/0/1.
  3. Next to Unit, click Add new entry.
  4. In the Unit number box, type 0.
  5. Next to Classifiers, click Configure.
  6. Under Inet precedence, in the Classifier name box, type classify_input.
  7. Click OK.
  1. From the [edit class-of-service] hierarchy level, enter

    edit interfaces ge-0/0/1

  2. Enter

    set unit 0 classifiers inet-precedence classify_input


[ Contents] [ Prev] [ Next] [ Index] [ Report an Error]