Switching

 View Only
last person joined: 3 days ago 

Ask questions and share experiences about EX and QFX portfolios and all switching solutions across your data center, campus, and branch locations.
Expand all | Collapse all

Rewrite and CoS (802.1p) setting on qfx5100

  • 1.  Rewrite and CoS (802.1p) setting on qfx5100

    Posted 02-08-2021 09:29
    Hello,

    I have to implement CoS (802.1p) on a "qfx5100-48s-6q" switch.

    Here is the deal: all the traffic coming on an ingress  interface (xe-0/0/30.1011) in my network has to be setted with the 802.1p tag "2" or "4" when it goes out of my network through the egress interface (ae.1011).

    If the traffic is not correctly tagged, it will be dropped by the operator's network.

    I try to use "rewrite-rules" but it doesn't seem to work.


    set class-of-service classifiers ieee-802.1 TestClass forwarding-class best-effort loss-priority low code-points 010
    set class-of-service classifiers ieee-802.1 TestClass forwarding-class network-control loss-priority low code-points 110

    set class-of-service interfaces ae31 unit 1011 rewrite-rules ieee-802.1 TestRw

    set class-of-service rewrite-rules ieee-802.1 TestRw import default
    set class-of-service rewrite-rules ieee-802.1 TestRw forwarding-class best-effort loss-priority high code-point 010
    set class-of-service rewrite-rules ieee-802.1 TestRw forwarding-class best-effort loss-priority medium-high code-point 010
    set class-of-service rewrite-rules ieee-802.1 TestRw forwarding-class best-effort loss-priority low code-point 010
    set class-of-service rewrite-rules ieee-802.1 TestRw forwarding-class network-control loss-priority high code-point 010
    set class-of-service rewrite-rules ieee-802.1 TestRw forwarding-class network-control loss-priority medium-high code-point 010
    set class-of-service rewrite-rules ieee-802.1 TestRw forwarding-class network-control loss-priority low code-point 010


    Can someone please explain me how to implement this mechanism on this device?

    How can I map the ingress trafic ? and when it is mapped, how can I tag this traffic as it is supposed to be tagged?

    Thank you in advance for your help!


  • 2.  RE: Rewrite and CoS (802.1p) setting on qfx5100

    Posted 02-09-2021 09:47
    Hello,

    I defined a classifier (TestClassifier) to be applied to the interface xe-0/0/30, but it seems that it has not been taking to account by the switch:

    set class-of-service classifiers ieee-802.1 TestClassifier forwarding-class best-effort loss-priority low code-points 000
    set class-of-service classifiers ieee-802.1 TestClassifier forwarding-class best-effort loss-priority low code-points 001
    set class-of-service classifiers ieee-802.1 TestClassifier forwarding-class best-effort loss-priority low code-points 010
    set class-of-service classifiers ieee-802.1 TestClassifier forwarding-class best-effort loss-priority low code-points 011
    set class-of-service classifiers ieee-802.1 TestClassifier forwarding-class best-effort loss-priority low code-points 100
    set class-of-service classifiers ieee-802.1 TestClassifier forwarding-class best-effort loss-priority low code-points 101
    set class-of-service classifiers ieee-802.1 TestClassifier forwarding-class best-effort loss-priority low code-points 110
    set class-of-service classifiers ieee-802.1 TestClassifier forwarding-class best-effort loss-priority low code-points 111

    set class-of-service interfaces xe-0/0/30 unit 0 classifiers ieee-802.1 TestClassifier


    show class-of-service interface xe-0/0/30
    Physical interface: xe-0/0/30, Index: 662
    Maximum usable queues: 12, Queues in use: 5
    Scheduler map: <default>, Index: 2
    Congestion-notification: Disabled

    Logical interface: xe-0/0/30.1000, Index: 566
    Object Name Type Index
    Classifier ieee8021p-untrust untrust 16

    Logical interface: xe-0/0/30.1005, Index: 567
    Object Name Type Index
    Classifier ieee8021p-untrust untrust 16

    Logical interface: xe-0/0/30.1011, Index: 623
    Object Name Type Index
    Classifier ieee8021p-untrust untrust 16

    It seems it's the default classifier that is used.

    How can I force the switch to use the Classifier I just defined?

    Thank you!


  • 3.  RE: Rewrite and CoS (802.1p) setting on qfx5100

    Posted 02-09-2021 10:18
    Your unit value is incorrect in the set class-of-service interface statement for the classifier, shouldn't it be unit 1011 per the explanation above??

    "set class-of-service interfaces xe-0/0/30 unit 0 classifiers ieee-802.1 TestClassifier"  


  • 4.  RE: Rewrite and CoS (802.1p) setting on qfx5100

    Posted 02-09-2021 10:33
    Hello,

    In fact, I also tried to apply the classifier to that specific unit 1011, but I got the following error when trying to commit:

    [edit class-of-service interfaces xe-0/0/30 unit 1011 classifiers]
    'ieee-802.1'
    BA or Fixed Classifier Supported only on physical interface or interface unit 0: xe-0/0/30.1011


    => So I applied the classifier on the unit 0: I read that when you appky it to the unit 0, it will apply to all the interface and units.


  • 5.  RE: Rewrite and CoS (802.1p) setting on qfx5100

    Posted 02-09-2021 10:43
    did you remove(delete) the unit 0 statement?  Also, you can use a regex to apply to the unit using "unit *" which will apply it to all the units on that physical interface.


  • 6.  RE: Rewrite and CoS (802.1p) setting on qfx5100

    Posted 02-09-2021 11:07
    Great!

    The classifier is now applied on the unit!

    show class-of-service interface xe-0/0/30

    Physical interface: xe-0/0/30, Index: 662
    Maximum usable queues: 12, Queues in use: 5
    Scheduler map: <default>, Index: 2
    Congestion-notification: Disabled

    Logical interface: xe-0/0/30.1000, Index: 566
    Object Name Type Index
    Classifier TestClassifier ieee8021p 19388

    Logical interface: xe-0/0/30.1005, Index: 567
    Object Name Type Index
    Classifier TestClassifier ieee8021p 19388

    Logical interface: xe-0/0/30.1011, Index: 623
    Object Name Type Index
    Classifier TestClassifier ieee8021p 19388


    Thank you so much!

    Now, I have to make the "rewrite-rules" work!



  • 7.  RE: Rewrite and CoS (802.1p) setting on qfx5100

    Posted 02-09-2021 11:12
    do the same thing as the classifier...


  • 8.  RE: Rewrite and CoS (802.1p) setting on qfx5100

    Posted 02-09-2021 11:24
    The 'Rewrite-Output' (named "TestRw")  is already applied to the egress interface (in my case it's the ae31 interface):

    show class-of-service interface ae31
    Physical interface: ae31, Index: 719
    Maximum usable queues: 12, Queues in use: 5
    Scheduler map: <default>, Index: 2
    Congestion-notification: Disabled
    Object Name Type Index
    Rewrite TestRw ieee8021p (outer) 20862

    Logical interface: ae31.1011, Index: 620
    Object Name Type Index
    Rewrite-Output TestRw ieee8021p (outer) 20862
    Classifier ieee8021p-untrust untrust 16

    But I don't know if it's really working: I must set the 802.1P-bit to "2" so that my traffic will not be dropped by my provider's Router, but it seems that it's still been dropped...and I don't understand why...

    How can I know that my traffic has the correct tag?





  • 9.  RE: Rewrite and CoS (802.1p) setting on qfx5100

     
    Posted 02-09-2021 16:15
    Hi RyRy,

    The only way for you to confirm that the rewrite-rules are working properly, will be to capture the traffic on the ingress of next hop.

    Regards,
    Jeff


  • 10.  RE: Rewrite and CoS (802.1p) setting on qfx5100

    Posted 02-10-2021 03:06
    Hello Jeff,

    The problem is that the next hop's device is the provide switch...and I have no access to that device.
    Moreover, the service should be up if my Cos tag would have been applied, and it's still not the case.

    I was thinking of doing a port mirroring of the egress port of my device on the ae31.

    A bit complicated to implement on a backbone switch...but I can't see any other option.

    Thank you for your help though!


  • 11.  RE: Rewrite and CoS (802.1p) setting on qfx5100

    Posted 02-10-2021 05:54
    Hello,

    I think my "rewrite-rule" was ok, maybe the thing that I applied it on an interface where I use SVLAN (in this case I pop my SVLAN on my egress interface ae31) causes trouble.

    I set this interface in a trunk mode and the service is now up!

    So the rewrite-rule seems to be well applied.

    Does anyone know if we can't use a rewrite-rule with a SVLAN which is popped?

    Thanks!


  • 12.  RE: Rewrite and CoS (802.1p) setting on qfx5100

    Posted 02-10-2021 08:54
    FYI