5.0: Granular Routing policy. Multiple policy entries do not work

Bug #1756799 reported by Shashikiran H
6
This bug affects 1 person
Affects Status Importance Assigned to Milestone
Juniper Openstack
Status tracked in Trunk
R5.0
Fix Committed
Critical
Madhusudan Bhat
Trunk
Fix Committed
Critical
Madhusudan Bhat

Bug Description

Version: 5.0
Picked up the latest build.

Topo:
10.204.217.7 cfgm control ui openstack
10.204.216.68 cfgm control
10.204.216.72 cfgm control
10.204.217.16 vrouter
10.204.217.17 vrouter

left-vn --- right-vn

I have a routing policy with 2 from-then conditions in it. If the first match is hit, the second is not evaluated. But even if the first does not match, the second is not evaluated at all.

This is my policy
from prefix [8.1.1.3/32 exact] then add communities [64512:55555] action default
from protocol interface then add communities [64512:66666] action default

Does not work even if I have this

from prefix [8.1.1.3/32 exact] then action accept
from protocol interface then add communities [64512:66666] action default

<iq>
 <routing-policy-entries>
  <term>
   <term-match-condition>
    <protocol>interface</protocol>
    <community></community>
    <community-match-all>false</community-match-all>
   </term-match-condition>
   <term-action-list>
    <update>
     <as-path>
      <expand />
     </as-path>
     <community>
      <add>
       <community>64512:55555</community>
       <community>64512:44444</community>
       <community>64512:44445</community>
      </add>
      <remove />
      <set />
     </community>
     <local-pref>0</local-pref>
     <med>0</med>
    </update>
    <action></action>
   </term-action-list>
  </term>
  <term>
   <term-match-condition>
    <protocol>interface-static</protocol>
    <community></community>
    <community-match-all>false</community-match-all>
   </term-match-condition>
   <term-action-list>
    <update>
     <as-path>
      <expand />
     </as-path>
     <community>
      <add>
       <community>64512:23456</community>
      </add>
      <remove />
      <set />
     </community>
     <local-pref>0</local-pref>
     <med>0</med>
    </update>
    <action></action>
   </term-action-list>
  </term>
 </routing-policy-entries>
</iq>

Shashikiran H (skiranh)
description: updated
Vineet Gupta (vineetrf)
tags: removed: blocker
Shashikiran H (skiranh)
description: updated
Revision history for this message
Nikhil Bansal (nikhilb-u) wrote :

Multiple policies are working. We found out a bug in agent where we don't assign interface type correctly. Assigning it to Hari for now.

Revision history for this message
OpenContrail Admin (ci-admin-f) wrote : [Review update] master

Review in progress for https://review.opencontrail.org/41315
Submitter: Madhusudan Bhat (<email address hidden>)

Revision history for this message
OpenContrail Admin (ci-admin-f) wrote : A change has been merged

Reviewed: https://review.opencontrail.org/41315
Committed: http://github.com/Juniper/contrail-controller/commit/cf79691585085730ea60122da0b1f6048b128767
Submitter: Zuul v3 CI (<email address hidden>)
Branch: master

commit cf79691585085730ea60122da0b1f6048b128767
Author: bmadhu <email address hidden>
Date: Tue Apr 3 22:13:28 2018 +0530

Granular Routing Policy - failure of multiple policy

When interface is configured with static route, agent wrongly exports all the routes as
interface-static type, which causes failure of policy. This fix ensures only static route
is added interface-static type

intf_route_type_ in vm_interface class is removed which is no more required

Change-Id: I1accd2472df07a2ab2388ce6c932bf82b87821ef
Closes-Bug: 1756799

Revision history for this message
OpenContrail Admin (ci-admin-f) wrote : [Review update] R5.0

Review in progress for https://review.opencontrail.org/41554
Submitter: Madhusudan Bhat (<email address hidden>)

Revision history for this message
OpenContrail Admin (ci-admin-f) wrote : A change has been merged

Reviewed: https://review.opencontrail.org/41554
Committed: http://github.com/Juniper/contrail-controller/commit/5adfd7259deaf8ad7553d4b07675ca17c293b763
Submitter: Zuul v3 CI (<email address hidden>)
Branch: R5.0

commit 5adfd7259deaf8ad7553d4b07675ca17c293b763
Author: bmadhu <email address hidden>
Date: Tue Apr 3 22:13:28 2018 +0530

Granular Routing Policy - failure of multiple policy

When interface is configured with static route, agent wrongly exports all the routes as
interface-static type, which causes failure of policy. This fix ensures only static route
is added interface-static type

intf_route_type_ in vm_interface class is removed which is no more required

Change-Id: I1accd2472df07a2ab2388ce6c932bf82b87821ef
Closes-Bug: 1756799
(cherry picked from commit cf79691585085730ea60122da0b1f6048b128767)

To post a comment you must log in.
This report contains Public information  
Everyone can see this information.

Other bug subscribers

Remote bug watches

Bug watches keep track of this bug in other bug trackers.