netvirt.git
6 years agoBug 9100 : tx leak in DhcpExternalTunnelManager 56/62856/2
Kency Kurian [Wed, 6 Sep 2017 11:43:17 +0000 (17:13 +0530)]
Bug 9100 : tx leak in DhcpExternalTunnelManager

Change-Id: I14a6ff3310214362fcd51cb36a0ceb509b386ee1
Signed-off-by: Kency Kurian <kency.kurian@ericsson.com>
6 years agoBUG9095 Capture SFC tunnel traffic for path egress 84/62784/2
Jaime Caamaño Ruiz [Fri, 1 Sep 2017 17:33:55 +0000 (19:33 +0200)]
BUG9095 Capture SFC tunnel traffic for path egress

On scenarios where origin and destination of traffic are on the same
node, but last SF is on a different node, SFc on last hop will not
de-encapsulate the traffic, instead it will the encpsulated traffic
to the node indicated via IP address on NSH C1 metadata.

There an egress classifier function will handle the traffic. In order
to do this, since port binding in tunnel ports is still not being used
and there is no dispatch service on tunnel ports, this egress
classification function needs to take SFC traffic (VNI=0) with priority
to handle the possible chain egress. If chain egress function is not
applied, it will resubmit this SFC traffic to the SFC pipeline.

The egress classifier function is aslo updated to match SFC traffic on
on the specific ending index of each possible path.

Change-Id: I2c6131b727c17e4a36d2b5fb931c84719f4a077b
Signed-off-by: Jaime Caamaño Ruiz <jaime.caamano.ruiz@ericsson.com>
(cherry picked from commit 64160b249a54deb31cac3021a8343b9b03006a83)

6 years agoBUG9094 Bind to last SF interface if origin node 82/62782/2
Jaime Caamaño Ruiz [Fri, 1 Sep 2017 15:11:48 +0000 (17:11 +0200)]
BUG9094 Bind to last SF interface if origin node

If the last SF is in one of the possible origin nodes for the
classified traffic, bind the classifier on it's port. This is to be
to handle the possible scenario where origin, last SF and destination
of traffic are on the same node. On this scenario, SFC on last hop will
not de-encapsulate the traffic, instead it will be handed off to the
dispatcher table for the egress classifier function to handle it. To be
able to do this, it needs to be bound to the last SF port.

Change-Id: I97f60e8cc409ea42c830e408b4df91051b50689c
Signed-off-by: Jaime Caamaño Ruiz <jaime.caamano.ruiz@ericsson.com>
(cherry picked from commit 9509d783b6c9fe5a348e0f39e86b8ae72cc53c3f)

6 years agoRemove stateless mode from AclService. 59/61259/6
Aswin Suryanarayanan [Mon, 7 Aug 2017 09:24:36 +0000 (14:54 +0530)]
Remove stateless mode from AclService.

Change-Id: I6307007ef23c4f58e8c543a22550109d8c778ce4
Signed-off-by: Aswin Suryanarayanan <asuryana@redhat.com>
6 years agoAdd LogCaptureRule to AclServiceTestBase & ElanServiceTest 55/62655/5
Michael Vorburger [Mon, 4 Sep 2017 21:46:59 +0000 (23:46 +0200)]
Add LogCaptureRule to AclServiceTestBase & ElanServiceTest

which is useful as is already to see test failure causes more clearly,
but will provide even more useful full information together with
https://git.opendaylight.org/gerrit/#/c/62654/

Change-Id: I278f38a38389eccea4317d52e8035f6e464400e1
Signed-off-by: Michael Vorburger <vorburger@redhat.com>
Signed-off-by: Aswin Suryanarayanan <asuryana@redhat.com>
6 years agoBug9016:Using Single Transaction during NAPT SwitchOver 91/62391/4
karthikeyan [Tue, 29 Aug 2017 08:24:45 +0000 (13:54 +0530)]
Bug9016:Using Single Transaction during NAPT SwitchOver

Problem Description:
====================
When NAPT Switch over happens, multiple transactions were made to remove
SNAT related flows from Primary NAPT switch and reinstalling flow on new
NAPT elected switch.

Optimization needs to be done to make use of single transaction taking
care of removing all SNAT related flows from old NAPT and another single
transaction for installing SNAT flows on new NAPT switch.

Solution:
==========
Used one write transaction object for used to remove all NAPT related
flows from old NAPT switch during NAPT switch over happened. Used other
write transaction object for installing all NAPT related flows on newly
elected NAPT switch. This will reduce the number of transaction object
were used during NAPT switch over happens as well as installing SNAT
related flows during first time as well.

Note:
=====
Have removed ExternalNetworkListener.java class. Since this class was
taken care for installing NAT default flow L3_FIB_TABLE(21)
PSNAT_TABLE(26) on all NAT switches. This same logic was already
implemented in ExternalRoutersListener class. Just to avoid the conflict
modification error, removed ExternalNetworkListener.java class from NAT
Module.

Change-Id: Ic2b54e7acbb01805b9a25fea28017c7353ee59d2
Signed-off-by: karthikeyan <karthikeyan.k@altencalsoftlabs.com>
6 years agoCluster support for netvirt QoS 92/62392/9
Arun Sharma [Tue, 29 Aug 2017 08:41:49 +0000 (14:11 +0530)]
Cluster support for netvirt QoS

-Changed QoS policy configuration change listeners from
 AsyncDataTreeChangeListenerBase to
 AsyncClusteredDataTreeChangeListenerBase so that all nodes receive
 QoS configuration change notifications.

-Rate limit and DSCP marking is done only by QoS entity owner. Other
 nodes just update the cache. This ensures that cache is always in
 sync between all the nodes.

Change-Id: Id2215e4b98cfcb238c437402a02ece640db11413
Signed-off-by: Arun Sharma <arun.e.sharma@ericsson.com>
6 years agoBug 9035: - NPE at org.opendaylight.netvirt.elan.arp.responder.ArpResponderUtil.getMa... 42/62742/1
vinothb [Thu, 31 Aug 2017 22:55:58 +0000 (18:55 -0400)]
Bug 9035: - NPE at org.opendaylight.netvirt.elan.arp.responder.ArpResponderUtil.getMatchCriteria

Problem Description:
=======================
The following exception was observed from ArpResponderUtil

Error while installing ARP responder flow
java.lang.NullPointerException
at org.opendaylight.netvirt.elan.arp.responder.ArpResponderUtil.getMatchCriteria(ArpResponderUtil.java:178)[307:org.opendaylight.netvirt.natservice-impl:0.5.0.SNAPSHOT]

Solution:
=========
We need to enhance the pre-condition check in ArpResponderUtil before
installing the flow.

Change-Id: I9558080dc41df15164d2b189168c56c83b63c6ac
Signed-off-by: vinothb <vinothb@hcl.com>
(cherry picked from commit 683ceee8c33e8bc38f5abee75a966a139ab6aaba)

6 years agoBug:9013 ElanUtils: RPC Call to Get egress actions for interface, OptimisticLockFaile... 99/62399/8
epgoraj [Tue, 29 Aug 2017 10:51:17 +0000 (16:21 +0530)]
Bug:9013 ElanUtils: RPC Call to Get egress actions for interface, OptimisticLockFailedException

Change-Id: Ib9607a217ff51eeedd92ca9c9c7759d352916aa7
Signed-off-by: epgoraj <p.govinda.rajulu@ericsson.com>
6 years agoBug 9085 - CSIT Sporadic failures - 73/62673/1
Aswin Suryanarayanan [Tue, 5 Sep 2017 08:58:41 +0000 (14:28 +0530)]
Bug 9085 - CSIT Sporadic failures -
test_security_groups_basic_ops.TestSecurityGroupsBasicOps.test_cross_tenant_traffic

Fixing the cause for exception.

Change-Id: I54f9812226be346dee771a0722618edbb9558190
Signed-off-by: Aswin Suryanarayanan <asuryana@redhat.com>
6 years agoReplace size()==0 by isEmpty() 31/61431/4
David Suarez [Wed, 9 Aug 2017 15:08:06 +0000 (17:08 +0200)]
Replace size()==0 by isEmpty()

Replace size()==0 by isEmpty(). It improves readability and avoid "=0".

Change-Id: I4bba45bea95a234734079376c7439395ae38e981
Signed-off-by: David Suarez <david.suarez.fuentes@gmail.com>
6 years agoReplace <? extends Object> by <?> 00/61900/5
David Suarez [Thu, 17 Aug 2017 07:50:18 +0000 (09:50 +0200)]
Replace <? extends Object> by <?>

Replace <? extends Object> by <?> since they are equivalent.

Change-Id: I548338da4bbc1da2c7b7401f456d08d74cec5111
Signed-off-by: David Suarez <david.suarez.fuentes@gmail.com>
6 years agoBug 6349: try connecting to qthrift only when configured. 16/62416/7
Siva Kumar Perumalla [Tue, 29 Aug 2017 21:22:55 +0000 (02:52 +0530)]
Bug 6349: try connecting to qthrift only when configured.
 - default values are set to invalid host/port.
 - verify whether port/host configured before connecting

Change-Id: I4cd19ad1e9844435f75f08f45962c67d555a7e39
Signed-off-by: Siva Kumar Perumalla <sivakumar.perumalla@ericsson.com>
6 years agoBug 8882 - With conntrack SNAT communication with PNF fails 97/62497/4
Aswin Suryanarayanan [Thu, 31 Aug 2017 14:25:22 +0000 (19:55 +0530)]
Bug 8882 - With conntrack SNAT communication with PNF fails

Traffic from Non NAPT to PNF was failing, Since from non NAPT switch the
packet came through a tunnel port to NAPT Switch. There it was failing
since the vpn interface does not exist for tunnel port. Hence it fails
to identify the router id.

Now for the tunnel port the external ip associated with router used to
identify the vpnid.

Change-Id: I60081c050ca117c99ba1809efde49d71d0909bdb
Signed-off-by: Aswin Suryanarayanan <asuryana@redhat.com>
6 years agoBug 9102 Fix ReadOnlyTransaction leak in NeutronvpnUtils 46/62646/1
Michael Vorburger [Mon, 4 Sep 2017 17:25:48 +0000 (19:25 +0200)]
Bug 9102 Fix ReadOnlyTransaction leak in NeutronvpnUtils

by delegating to my SingleTransactionDataBroker, which correctly closed
the transaction.  Also, the exception handling here is really wrong, but
that's not really related to the bug being fixed here, so separately,
later, someone, sometime... ;)

Change-Id: Id3ef558623b69bf155796200db397a4da11c8500
Signed-off-by: Michael Vorburger <vorburger@redhat.com>
6 years agoCleanup 90/62590/2
David Suarez [Sun, 3 Sep 2017 14:51:16 +0000 (16:51 +0200)]
Cleanup

- Remove dead code
- Final class & private constructor for utility classes
- Return variables directly
- Add method qualifiers
- Join some if statements

Change-Id: I2ca3cc08cbe10e4885510f9fc6bcb7f684e48922
Signed-off-by: David Suarez <david.suarez.fuentes@gmail.com>
6 years agoBug 8953 - IllegalArgumentException: vrfEntry is missing mandatory 32/62532/3
eupakir [Fri, 1 Sep 2017 08:44:21 +0000 (14:14 +0530)]
Bug 8953 - IllegalArgumentException: vrfEntry is missing mandatory
descendant origin

Change-Id: I74d6e503268414b0635a84007b36a1f9c0c0a8cc
Signed-off-by: eupakir <kiran.n.upadhyaya@ericsson.com>
6 years agoBug 9030 - port and port security groups cannot be null 52/62452/2
Aswin Suryanarayanan [Wed, 30 Aug 2017 14:30:47 +0000 (20:00 +0530)]
Bug 9030 - port and port security groups cannot be null

Fixing an issue caused due to the removal of null check bindAcl in [1].
Which could cause bind service being called for port which has SG
disabled.

[1]https://git.opendaylight.org/gerrit/#/c/62346

Change-Id: Icd9e75f7b0bbfa448e49aa9109c8ea562a48be27
Signed-off-by: Aswin Suryanarayanan <asuryana@redhat.com>
6 years agoBug 9060: Package mdsal trace utility in netvirt Karaf distribution 03/62403/3
Michael Vorburger [Tue, 29 Aug 2017 12:34:00 +0000 (14:34 +0200)]
Bug 9060: Package mdsal trace utility in netvirt Karaf distribution

This will make it easier to detect OOM issues such as Bug 9034 on scale
test environments, based on using the mdsal-trace DataBroker wrapper.

Change-Id: I3198bffac2a7fa434b0ab2a74d257ad42f064f51
Signed-off-by: Michael Vorburger <vorburger@redhat.com>
6 years agoBug 8801 - EVPN remote routes are not pushed to ovs flow table 74/59974/5
eupakir [Wed, 5 Jul 2017 13:03:39 +0000 (18:33 +0530)]
Bug 8801 - EVPN remote routes are not pushed to ovs flow table

Change-Id: I332f9cde34e1f716b3cb9e02585101055be6624b
Signed-off-by: eupakir <kiran.n.upadhyaya@ericsson.com>
6 years agoBug 8953 - IllegalArgumentException: vrfEntry is missing mandatory 86/62186/5
eupakir [Wed, 23 Aug 2017 08:20:05 +0000 (13:50 +0530)]
Bug 8953 - IllegalArgumentException: vrfEntry is missing mandatory
descendant origin

The PNF deletion use cases were missing a few fixes in VPN and FIB
Engines.
1) Even though FIB was created using the external subnetId as the rd, the
external network id was being used to delete the FIB entries.
2) There was a fix in the PNF FIB add cycle to get vpn operational data
using the external network id instead of external subnet id. This was
missing in the deletion cycle.

Change-Id: Ida3125bf45beed1470ab699241988bd56a791a80
Signed-off-by: eupakir <kiran.n.upadhyaya@ericsson.com>
Signed-off-by: Vivekanandan Narasimhan <n.vivekanandan@ericsson.com>
6 years agobgpmanager BgpUtil code clean-up: Make private what can, and rm unused 11/62211/3
Michael Vorburger [Wed, 23 Aug 2017 15:03:49 +0000 (17:03 +0200)]
bgpmanager BgpUtil code clean-up: Make private what can, and rm unused

Change-Id: I484c456e44d2414ef4f03f86b4b1e79d6fcd52bc
Signed-off-by: Michael Vorburger <vorburger@redhat.com>
6 years agoRevert "Add git commit coala bear" 21/62421/2
Sam Hague [Tue, 29 Aug 2017 16:46:28 +0000 (16:46 +0000)]
Revert "Add git commit coala bear"

This reverts commit 12d10f57789a5a63cf1ae6133f64205f247ff0fd.

Change-Id: I23574392ac3e152585043839c38dd749aee7ed77
Signed-off-by: Sam Hague <shague@redhat.com>
6 years agoBug 9034: bgpmanager BgpUtil rm unused pendingWrTransaction 17/62217/3
Michael Vorburger [Wed, 23 Aug 2017 15:25:07 +0000 (17:25 +0200)]
Bug 9034: bgpmanager BgpUtil rm unused pendingWrTransaction

There's no set() for the pendingWrTransaction, so it's.. completely
pointless - and that retry loop in BgpConfigurationManager's
createStaleFibMap() could never have worked anyway, as
BgpUtil.getGetPendingWrTransaction() == 0, always.

Change-Id: I8644a3a9d63c5eff4106c58865cad9969d3990a2
Signed-off-by: Michael Vorburger <vorburger@redhat.com>
6 years agoL2 Support for Pods 64/62364/2
Faseela K [Mon, 28 Aug 2017 13:46:18 +0000 (19:16 +0530)]
L2 Support for Pods

Whenever the first pod under a namespace is created, an elan-instance
is created. Also for each pod interface an l2vlan trunk interface as
well as an elan-interface is created.

Change-Id: Ib32b987c8c86467ead8e0b4e38d3586d4fb93f70
Signed-off-by: Faseela K <faseela.k@ericsson.com>
6 years agoBug 8860: NPE in getElanTag from SubnetmapChangeListener 69/62369/4
Vivekanandan Narasimhan [Mon, 28 Aug 2017 15:05:22 +0000 (20:35 +0530)]
Bug 8860: NPE in getElanTag from SubnetmapChangeListener

The exception is genuine, but in order to enable tightening
of exception throws in netvirt, we are logging this
exception gracefully via this fix.

The real reason why this exception occurs can be ascertained
only the context information available when this issue happens
again in any upstream job.

The bug itself does not have link to logs that have this
exception thrown, for any postmortem/analysis.

Change-Id: I1c29efad5de85bfd340ea54a3600db9997c12a4b
Signed-off-by: Vivekanandan Narasimhan <n.vivekanandan@ericsson.com>
6 years agoAdd git commit coala bear 26/62326/8
Sam Hague [Fri, 25 Aug 2017 16:14:21 +0000 (12:14 -0400)]
Add git commit coala bear

Depends-on: https://git.opendaylight.org/gerrit/62325

Change-Id: I8523b865d60afa16c1ceac1261ee01ce6e70378c
Signed-off-by: Sam Hague <shague@redhat.com>
6 years agoBug 9030 - port and port security groups cannot be null 79/62179/6
Aswin Suryanarayanan [Wed, 23 Aug 2017 05:34:14 +0000 (11:04 +0530)]
Bug 9030  - port and port security groups cannot be null

The error logs are written when the port has no security groups. It is
perfectly fine for a port to not have security groups and hence lowering
the log level to info.

Removed the uneccsary null check of security groups while bind service
is called.

Change-Id: Ic386938e3ef14501798499abe5d82f3c63f329af
Signed-off-by: Aswin Suryanarayanan <asuryana@redhat.com>
6 years agoBug 9051 - Failed to handle router GW flow in GW-MAC table. DPN id is missing for... 93/62293/2
Andre Fredette [Thu, 24 Aug 2017 20:05:46 +0000 (16:05 -0400)]
Bug 9051 - Failed to handle router GW flow in GW-MAC table. DPN id is missing for router-id

Change log level and message.

Change-Id: I94406443eb67c6fecfc8ecaaf349ed6cb2168b80
Signed-off-by: Andre Fredette <afredette@redhat.com>
6 years agoCoe renderer merge build failed due to groupId not present in aggregator 46/62246/4
Faseela K [Thu, 24 Aug 2017 06:06:11 +0000 (11:36 +0530)]
Coe renderer merge build failed due to groupId not present in aggregator
pom

Change-Id: Ia39b2d40efe6a1521631a8a6cd13cdc3a80ed78e
Signed-off-by: Faseela K <faseela.k@ericsson.com>
6 years agoBug 9034: bgpmanager BgpUtil rm unused BindingTransactionChain & Co. 15/62215/2
Michael Vorburger [Wed, 23 Aug 2017 15:07:30 +0000 (17:07 +0200)]
Bug 9034: bgpmanager BgpUtil rm unused BindingTransactionChain & Co.

Not sure if this fixed Bug 9034, but let us please remove this clearly
un-used Transcation Chain here - it's one less to worry about when
analyzing this OOM.

Change-Id: Ide872b7d439d5b25f6cd759c129cc29190b483cc
Signed-off-by: Michael Vorburger <vorburger@redhat.com>
6 years agoBug 9039 - In Conntrack SNAT, when a router g/w is cleared traffic is 20/62220/2
Aswin Suryanarayanan [Wed, 23 Aug 2017 16:24:52 +0000 (21:54 +0530)]
Bug 9039 - In Conntrack SNAT, when a router g/w is cleared traffic is
dropped for other routers

Pfib flow is made per router for inbound and outbound traffic. The
metadata rewrite from internal to external for outbound traffic  happens
in the PFIB table.

Change-Id: I17bc024e66c424459d8fe8b1ddf02a1d7a96d2bb
Signed-off-by: Aswin Suryanarayanan <asuryana@redhat.com>
6 years agoInitial Bundle setup for coe renderer 59/61559/11
Faseela K [Fri, 11 Aug 2017 20:46:58 +0000 (02:16 +0530)]
Initial Bundle setup for coe renderer

This patch adds the following :

1. coe-renderer-api and coe-renderer-impl bundles
2. Add them to respective features
3. COE Pod and Service Listener skeleton

Change-Id: Ibe692953d40c781a843cb8c4632a1aedd07ab087
Signed-off-by: Faseela K <faseela.k@ericsson.com>
6 years agoBug 9022: ACL: Broadcast traffic is dropped in ACL tables 51/62151/1
Shashidhar Raja [Mon, 21 Aug 2017 14:20:21 +0000 (19:50 +0530)]
Bug 9022: ACL: Broadcast traffic is dropped in ACL tables

This fix enables ACL to permit Broadcast Traffic (Both IP and Non IP).

Related to IP Broadcast, Subnet-Directed Broadcast and All-Subnet
Broadcast traffic on the same network is being allowed subject to one of
the conditions specified below is met:
  (a) The ports that want to communicate share the same
      remote-secuirty-group
  (b) The ports that want to communicate allow the other port's IP Address
      in remote-ip-prefix
  (c) The ports that want to communicate have securiyt0group with
      remote-ip-prefix of 0.0.0.0/0.

IP Broadcast flows configured in VM Ingress ACL table (table 241) is as
below:

all-subnet flow:
cookie=0x6900000, duration=1463.293s, table=241, n_packets=0, n_bytes=0,
       priority=61010,ip,dl_dst=ff:ff:ff:ff:ff:ff,nw_dst=255.255.255.255
       actions=goto_table:242

subnet-directed flow:
cookie=0x6900000, duration=975.798s, table=241, n_packets=0, n_bytes=0,
       priority=61010,ip,metadata=0x10000000000/0x1fffff0000000000,
       dl_dst=ff:ff:ff:ff:ff:ff,nw_dst=10.1.1.255 actions=goto_table:242

Non IP Broadcast flows (with lower priority than other flows - 61005)
configured in VM Egress(211) and Ingress(241) tables is as below:

cookie=0x6900000, duration=30.298s, table=211, n_packets=0, n_bytes=0,
       priority=61005,metadata=0x10000000000/0x1fffff0000000000,
       dl_src=fa:16:3e:a9:4d:81 actions=resubmit(,17)

cookie=0x6900000, duration=901.855s, table=241, n_packets=0, n_bytes=0,
       priority=61005,dl_dst=ff:ff:ff:ff:ff:ff actions=resubmit(,220)

Below are change details:
 - Updated to add a flow to allow broadcast traffic with destination
   adddress 255.255.255.255. Changes related to this are in
   AclNodeListener.java
 - Updated to add flows at port level for subnetwork's broadcast addresses
 - Updated to add flows in 211/241 for Non-IP broadcast traffic
 - Updated to add ARP/IP/IPv6 default drop flows with lower priority than
   respective flows and higher priority than non-ip broadcast flow
 - New yang definition introduced in ACL for higher modules (Neutron VPN
   in our case) to pass broadcast CIDRs when ACL Interface is created
 - NeutronVpn is updated to pass subnet CIDRs when ACL Interface is
   created

Change-Id: I71c5040454b3c00af43dcef4f47b5979cd7cf3a5
Signed-off-by: Shashidhar Raja <shashidharr@altencalsoftlabs.com>
6 years agoBUG 9014 : Remove unnecessary log statements in VPN Engine 21/62121/2
eupakir [Tue, 22 Aug 2017 05:47:52 +0000 (11:17 +0530)]
BUG 9014 : Remove unnecessary log statements in VPN Engine

Change-Id: I501beac66cc8f9ffc44d5f12b22514d7d3b03d22
Signed-off-by: eupakir <kiran.n.upadhyaya@ericsson.com>
6 years agobug 9018 l2gw designated dhcp fix 78/62078/3
K.V Suneelu Verma [Mon, 21 Aug 2017 11:21:27 +0000 (16:51 +0530)]
bug 9018 l2gw designated dhcp fix

Instead of listening for logical switch creation, listen for
mcast mac creation and update the mcast mac to avoid race of updating the
mcast mac.
while updating mcast mac read the existing mac and add designated dhcp tep
ip to the existing locators.

Change-Id: Id4d99471ae0b3be306a5511ee7cea975606deaa3
Signed-off-by: K.V Suneelu Verma <k.v.suneelu.verma@ericsson.com>
6 years agolower BGPconnect logs to debug level 49/62149/1
Sam Hague [Tue, 22 Aug 2017 11:57:06 +0000 (07:57 -0400)]
lower BGPconnect logs to debug level

Change-Id: Ied9756d8ea082d52bc6719a0fe42a6dcf52c25ce
Signed-off-by: Sam Hague <shague@redhat.com>
6 years agoRemove unused NatNodeEventListener 17/62017/3
Faseela K [Sat, 19 Aug 2017 06:29:34 +0000 (11:59 +0530)]
Remove unused NatNodeEventListener

This listener does not have anything else other than debug statements.
This was seen while analyzing the delay in programming default flows
when switches are connected in scaled scenario. While trying to optimize
the number of listeners and heavy operations being done in listener
thread, this came to notice. There is no heavy operation here, but if
the listener is of no use, let us avoid one unnecessary registration.

Change-Id: I87f80b851472dba7364fe16c5d39d8ed775b2d67
Signed-off-by: Faseela K <faseela.k@ericsson.com>
6 years agoBug 9012 : BGP reconnect and retry logic to QBGP 74/61974/5
Vyshakh Krishnan CH [Fri, 18 Aug 2017 09:05:15 +0000 (14:35 +0530)]
Bug 9012 : BGP reconnect and retry logic to QBGP

During the internal testing we have observed that for many configs, thrift is not reliable enough and QBGP is not receiving the configs ODL is sending. So as a safer way, introducing retries while sending the configs to QBGP. Also reconnect mechanism in case of any thrift transport exception

Change-Id: I9862d3db093f85399e81207c787528da25445999
Signed-off-by: Vyshakh Krishnan CH <vyshakh.krishnan.c.h@ericsson.com>
6 years agoBug 9014 - ElanUtils: buildRemoteDmacFlowEntry 39/62039/4
Sam Hague [Sun, 20 Aug 2017 11:35:33 +0000 (07:35 -0400)]
Bug 9014 - ElanUtils: buildRemoteDmacFlowEntry

Bug 9014 - ElanUtils: buildRemoteDmacFlowEntry: Could not find interfaceName

These logs are not errors as the tests pass. The data eventually is available in the datastore.

Change-Id: Id09647a642dc6023b4d34f37fa12839d6a077407
Signed-off-by: Sam Hague <shague@redhat.com>
6 years agoBUG 9014: Remove unnecessary Log statements for evpn/subnetroute 56/62056/6
Vivekanandan Narasimhan [Mon, 21 Aug 2017 05:33:20 +0000 (11:03 +0530)]
BUG 9014: Remove unnecessary Log statements for evpn/subnetroute

1.Modified error logs to debug logs in necessary places
from evpn rt2 code, especially which hits for non-evpn scenarios.

2. This cannot find portOp Error was earlier relevant
where race conditions existed between interface-state
event southbound and subnet-port openstack configuraiton from
northbound.   Later we divided handling the subnetroute
creation into two batches to address the race condition
properly in [1].

As a result with [1] being merged, the error statement for
portOp is not required anymore and so this fix removes that
error statement.

[1] https://git.opendaylight.org/gerrit/#/c/61823/

Change-Id: Ic61f7ec5e3b9733f3e2f9a6bfc56af15c8af6d73
Signed-off-by: Vivekanandan Narasimhan <n.vivekanandan@ericsson.com>
6 years agoBug 8960: port information for 1 dpn is missing in subnet-op-data and 23/61823/6
ehvkand [Wed, 16 Aug 2017 09:42:03 +0000 (15:12 +0530)]
Bug 8960: port information for 1 dpn is missing in subnet-op-data and
port-op-data

Upon PL reboot , if southbound event (PortUP) event is received first and
northbound event(OnSubnetAddedToVpn) is received later ,DPN will not be
updated in PortOpData.

Fix :
(1) When northbound event is received , SubnetOpDataEntry is created
first by using clustered wide lock based on subnetId. Then PortOpDataEntry
and subnetToDpn is created.

(2)Incase southbound event is received first,PortOpData entry may not be
available.In such case subnetId is retrieved from Neutron cache and
PortOpData entry will be created by the SubnetInterfaceStateChangeListener
thread.

Change-Id: I3a0d9c814909e6031bd1e25dd32564415fb912d8
Signed-off-by: ehvkand <hanamantagoud.v.kandagal@ericsson.com>
6 years agoBug 8981: ACL: ARP/DHCP anti-spoofing flows does not include VM/AAP ip/mac 69/61569/9
Shashidhar Raja [Sun, 13 Aug 2017 03:22:49 +0000 (08:52 +0530)]
Bug 8981: ACL: ARP/DHCP anti-spoofing flows does not include VM/AAP ip/mac
matches in VM egress direction

ACL updated to include IP+MAC matches for ARP and MAC only matches for DHCP
with anti-spoofing flows in VM egress direction

Change-Id: If3e3de5a4ea66dc23c6bec5ba66881abb6cdbc0a
Signed-off-by: Shashidhar Raja <shashidharr@altencalsoftlabs.com>
Signed-off-by: Vivekanandan Narasimhan <n.vivekanandan@ericsson.com>
6 years agocleanup for erros that should be info 55/62055/2
Sam Hague [Mon, 21 Aug 2017 00:49:56 +0000 (20:49 -0400)]
cleanup for erros that should be info

Change-Id: Ic81243d4fa03f173cfa6f140e7fc3c925e3533bf
Signed-off-by: Sam Hague <shague@redhat.com>
6 years agoUse INFO for logging GW search misses 31/62031/2
Sam Hague [Sun, 20 Aug 2017 01:33:55 +0000 (21:33 -0400)]
Use INFO for logging GW search misses

Change-Id: Ib240dfe59804b3f101ae3fe305c6960da3046624
Signed-off-by: Sam Hague <shague@redhat.com>
6 years agoBug 8996 : BGP EOR and some minor fixes 07/61807/6
Vyshakh Krishnan CH [Wed, 16 Aug 2017 08:23:09 +0000 (13:53 +0530)]
Bug 8996 : BGP EOR and some minor fixes

Today ODL is sending the neigbour config to QBGP at the end of config replay. ie after VRFS and Netwroks. SO after a cluster reboot, neighborship establishment is taking time. A new EOR mechanishm is introducd, so that ODL can send the neighbor first. QBGP will wait for EOR from ODL to send the EOR to neighbor

Also some minor BGP fixes

Change-Id: Ib00827919aa227650ca9d7f345f40a0aed55124d
Signed-off-by: Vyshakh Krishnan CH <vyshakh.krishnan.c.h@ericsson.com>
6 years agoBug 9015 - Unable to install group 33/62033/3
Sam Hague [Sun, 20 Aug 2017 02:49:28 +0000 (22:49 -0400)]
Bug 9015 - Unable to install group

The code checking the response for the RPC was incorrectly assuming the future would return and Rpcresult.result

This job had extra debugging to show the result is coming back as null:

https://logs.opendaylight.org/releng/jenkins092/netvirt-csit-1node-openstack-ocata-gate-stateful-nitrogen/123/odl1_karaf.log.gz

2017-08-20 04:24:59,096 | INFO  | nPool-1-worker-0 | NexthopManager                   | 302 - org.opendaylight.netvirt.fibmanager-impl - 0.5.0.SNAPSHOT | Group 150000 with key nexthop.10000050.0.0.2/32 has been successfully installed directly on dpn 273623493589781. rpcResult: RpcResult [successful=true, result=null, errors=[]], isSuccessful: RpcResult [successful=true, result=null, errors=[]], getResult: true

Change-Id: Ie1717102b19aca85043ff7ddbba6bce6fbd6799d
Signed-off-by: Sam Hague <shague@redhat.com>
6 years agoBug 8974: Fix subnet-directed-broadcast-addr ARP issue 30/61530/3
HANAMANTAGOUD V Kandagal [Fri, 11 Aug 2017 06:22:26 +0000 (11:52 +0530)]
Bug 8974: Fix subnet-directed-broadcast-addr ARP issue

Currently subnet-directed-broadcast-addr packets are punted to controller.
Controller sends a ARP request for the same IP address.

To avoid the same, FIB entry is added with subnet-directed-broadcast-addr
match and action to drop the packet instead of punting to controller.

Change-Id: I335a040d99e91d30fb75ad84cf18045eb21524e2
Signed-off-by: HANAMANTAGOUD V Kandagal <hanamantagoud.v.kandagal@ericsson.com>
6 years agoBug 8976 - Upstreaming fixes to master 45/61545/11
eupakir [Fri, 11 Aug 2017 12:37:42 +0000 (18:07 +0530)]
Bug 8976 - Upstreaming fixes to master

This patch includes logging enhancements in the VPN Engine

Change-Id: I83c13f221cbf0299758e2e17580681c71aa7a80f
Signed-off-by: eupakir <kiran.n.upadhyaya@ericsson.com>
6 years agoBug 8976 - Upstreaming fixes to master 42/61542/8
eupakir [Fri, 11 Aug 2017 10:28:10 +0000 (15:58 +0530)]
Bug 8976 - Upstreaming fixes to master

This patch contains fixes:
1) To capture the last advertised state for a subnet route
2) Fixes for iRT/eRT deletion use-cases
3) Some Logging enhancements for subnet route

Change-Id: If9290d41bd5851079ecf482a4eb33f1ba3991981
Signed-off-by: eupakir <kiran.n.upadhyaya@ericsson.com>
6 years agoBug 8998 - L2GW:Vlan bindings missing on reboot 40/61840/9
eaksahu [Wed, 16 Aug 2017 12:33:48 +0000 (18:03 +0530)]
Bug 8998 - L2GW:Vlan bindings missing on reboot

Vlan bindings are missing upon cluster reboot.
While processing physical switch node add event , its global node
is not available yet.
Enqueued this job to global node add pending job wait list so that
eventually after the global node is added this gets processed.

Handled the tunnel ip change of the physical switch.
When the tunnel ip changes delete old itm tunnels
create new tunnels with new tunnel ip
retrigger the l2gw connection processing to take affect of the
new tunnel ip.

Handled the local ucast macs that are added to the southbound device
while odl is down.
When odl comes up as part of processing its l2gw connections
it pulls the added local ucast macs from the southbound device.

Change-Id: Id6fdbbfe852a6fc0d89f360eb498fece8f00bdb5
Signed-off-by: eaksahu <a.k.sahu@ericsson.com>
6 years agoBug 8978 - Network deletion issue. 40/61540/9
eaksahu [Fri, 11 Aug 2017 09:47:18 +0000 (15:17 +0530)]
Bug 8978 - Network deletion issue.

Elaninstance after deletion was clearing l2gateway connection
configuration , but was not deleting l2gatewayConnection object itself
from neutron config tree. This leads to reconfiguration of
l2gatewayconnection upon reboot / device reconnect also.
Fixed the above case.
Added way to cancel logical switch deletion , so that if the same
network is reconfgured while deletion is going on , it can be cancelled.
Calling logical switch delete cancel when associating the same network
to l2gw.

Change-Id: I530c4b87becf3043eb8c4ba03226447731b2db0b
Signed-off-by: eaksahu <a.k.sahu@ericsson.com>
6 years agoBug 8965 - L2gw update is not suported 26/61426/4
eaksahu [Wed, 9 Aug 2017 14:22:09 +0000 (19:52 +0530)]
Bug 8965 - L2gw update is not suported

Currently l2gw once created , no update are on that are supported.
With this patch following use case has been supported.
Update existing l2gw vlanbindings
Update existing l2gw with new ports / device .

It takes care of configuring w.r.t associated l2gwconnection .

Change-Id: I37dda9cf366b1fe59ccf95f64f0574448f156d47
Signed-off-by: eaksahu <a.k.sahu@ericsson.com>
6 years agoRemove last remaining federation-plugin 38/62038/2
Sam Hague [Sun, 20 Aug 2017 10:56:41 +0000 (06:56 -0400)]
Remove last remaining federation-plugin

Change-Id: I6e1698395a00365ed16eda518a36ed41e11cc758
Signed-off-by: Sam Hague <shague@redhat.com>
6 years agoset BGP connect problem to be info 32/62032/2
Sam Hague [Sun, 20 Aug 2017 01:45:33 +0000 (21:45 -0400)]
set BGP connect problem to be info

Change-Id: I828d273eab454fa48f01309fe10b8c54423216f7
Signed-off-by: Sam Hague <shague@redhat.com>
6 years agoBug 8774 DHCP Service to use DHCP Port MAC Address 05/59805/5
Achuth Maniyedath [Fri, 30 Jun 2017 19:12:09 +0000 (00:42 +0530)]
Bug 8774 DHCP Service to use DHCP Port MAC Address

Use DHCP Port MAC Address for responding to DHCP
discover/renew requests.

Change-Id: I00ab448fb2894fc1ae38084033294ab9acd69ab6
Signed-off-by: Achuth Maniyedath <achuth.m@altencalsoftlabs.com>
6 years agoBug8861 : Data validation failed for path /snatint-ip-port-map 49/61949/4
cgowdru [Thu, 17 Aug 2017 18:02:25 +0000 (23:32 +0530)]
Bug8861 : Data validation failed for path /snatint-ip-port-map

Description : When interface entry is deleted from interface-state OS,
in NAT InterfaceStateListener, as part of clean-up, we try to delete all
the SNAT sessions data assocaiated with that interface. But, an attempt was
done to delete an entry from snatint-ip-port-map even there doesn't exists any
SNAT translation resulting in this exception. Changes done to delete
snatint-ip-port-map ony if an valid entry exists.

Change-Id: Ic0d4fa08b91700c2b4a63ab6e613d7554741d413
Signed-off-by: cgowdru <chetan.arakere@altencalsoftlabs.com>
6 years agoFix Junit failures in master in ACL & SFC 18/62018/3
Faseela K [Sat, 19 Aug 2017 10:04:57 +0000 (15:34 +0530)]
Fix Junit failures in master in ACL & SFC

The junits were broken after the recent commit in yangtools
https://git.opendaylight.org/gerrit/#/c/48672/

Change-Id: Ib37cb57de2c59d558f89b9723f685071fee9ff3b
Signed-off-by: Faseela K <faseela.k@ericsson.com>
6 years agoBug 8926: Fix instance doesn't get an IP after deployment 15/62015/1
Sridhar Gaddam [Fri, 18 Aug 2017 16:59:09 +0000 (22:29 +0530)]
Bug 8926: Fix instance doesn't get an IP after deployment

In a fresh multinode deployment with Controller node running
ODL + dhcp-agent and a Compute node, when we spawn a first VM
on the compute node, it was seen that VM does not acquire the
IPAddress.

On debugging, it turns out that the remote broadcast group
entries were not programmed on the Compute node. This is a
timing/sync issue between Netvirt (Elan) and GENIUS. The
bug description explains the issue in detail and this patch
addresses the issue.

Change-Id: Ifee63e13cf330dd3056468eba95e6451e173e30b
Signed-off-by: Sridhar Gaddam <sgaddam@redhat.com>
6 years agoBug 8973 : DHCP fixes 90/61490/3
Kency Kurian [Thu, 10 Aug 2017 11:45:23 +0000 (17:15 +0530)]
Bug 8973 : DHCP fixes

1. For SR-IOV vm dhcp request:
After controller restart it was found that the DHCP flows were being installed
as drop on the designated DPN.

Added a check to see if the DPN being added is already a designated DPN
then, drop flows need not be installed.

2. Added a null check for gateway ipaddress and also whenver getIpv4Address
is called.

3. Added a null check for l2gwdevice in installRemoteMCastMac.

Change-Id: I2fae322af07b582fa4e5a03522513976dd2c55e5
Signed-off-by: Kency Kurian <kency.kurian@ericsson.com>
6 years agoBug 8982: avoid .transform() NPEs 75/59875/10
Stephen Kitt [Mon, 3 Jul 2017 13:12:25 +0000 (15:12 +0200)]
Bug 8982: avoid .transform() NPEs

Guava’s Optional::transform doesn’t support null values returned by
the mapping function — it throws a NPE if that happens. java.util’s
Optional::map does support null values and returns an empty Optional.
Combined with the current YANG-based code’s ability to return null,
this means it’s better to use java.util’s method; this patch switches
all YANG-based Optional transforms to java.util.

Change-Id: I304762b8eed03480760d36ae6903cdb495bd7b05
Signed-off-by: Stephen Kitt <skitt@redhat.com>
6 years agoBug 8979: Logging enhancements for VPNService 81/61581/6
Abhinav Gupta [Fri, 11 Aug 2017 12:01:42 +0000 (17:31 +0530)]
Bug 8979: Logging enhancements for VPNService

This fixes logging issues related to non-parametrization of logs, printing
of exceptions, changing log levels for a few logs.
These changes have been made across NeutronVPN primarily, and also a bit
for VPNManager and FIBManager

Change-Id: Ice4b206ada6cc591f96ef75eccd820683b21a647
Signed-off-by: Abhinav Gupta <abhinav.gupta@ericsson.com>
6 years agorm it module 44/61944/2
Sam Hague [Thu, 17 Aug 2017 15:39:29 +0000 (11:39 -0400)]
rm it module

Change-Id: I0865195683a45adcef787365c4e91e217eb7e514
Signed-off-by: Sam Hague <shague@redhat.com>
6 years agorm federation plugin 46/61946/2
Sam Hague [Thu, 17 Aug 2017 15:43:32 +0000 (11:43 -0400)]
rm federation plugin

Change-Id: I2972254584cce0ed42213590683f2b2aab5ea678
Signed-off-by: Sam Hague <shague@redhat.com>
6 years agoUse correct namespace for lockmanager 39/61939/1
Vishal Thapar [Thu, 17 Aug 2017 14:46:28 +0000 (20:16 +0530)]
Use correct namespace for lockmanager

Requires: https://git.opendaylight.org/gerrit/#/c/61934/

Change-Id: I554f53945e4e3f7a6a28809bbb5d79cd6f483f5e
Signed-off-by: Vishal Thapar <vishal.thapar@ericsson.com>
6 years agoBUG: Adapt SFC translator to SFC code in Nitrogen 04/61504/8
Manuel Buil [Thu, 10 Aug 2017 14:47:31 +0000 (16:47 +0200)]
BUG: Adapt SFC translator to SFC code in Nitrogen

BUG: 8966

SFC Translator must start using logical SFF otherwise it will not work

Change-Id: Iec8dd6ae757d230464162dd1612bcda3a8fd0f26
Signed-off-by: Manuel Buil <mbuil@suse.com>
Signed-off-by: Jaime Caamaño Ruiz <jaime.caamano.ruiz@ericsson.com>
6 years agoBUG 9003: Support source-logical-port acl match 15/61615/9
Jaime Caamaño Ruiz [Mon, 14 Aug 2017 14:21:28 +0000 (16:21 +0200)]
BUG 9003: Support source-logical-port acl match

Neutron flow classifier includes acl matches for source and destination
neutron ports. Added support for source port, and updated the model to
also include destination port although not supported yet.

Change-Id: I83f8cc362869d046cdce756b5cbe4b13215b75f0
Signed-off-by: Jaime Caamaño Ruiz <jaime.caamano.ruiz@ericsson.com>
6 years agoBUG 9003: Fix port chain event triggered two times 11/61711/4
Jaime Caamaño Ruiz [Mon, 14 Aug 2017 17:46:29 +0000 (19:46 +0200)]
BUG 9003: Fix port chain event triggered two times

Change-Id: I4dd83824808d3faa2f515901d9171bb8e812d681
Signed-off-by: Jaime Caamaño Ruiz <jaime.caamano.ruiz@ericsson.com>
6 years agoBUG 9003: Fix classifier entry processing order 10/61710/3
Jaime Caamaño Ruiz [Mon, 14 Aug 2017 17:45:56 +0000 (19:45 +0200)]
BUG 9003: Fix classifier entry processing order

Change-Id: Icfafe3ef3a77bd48e3ddcf249f6c1e41b3e57aa5
Signed-off-by: Jaime Caamaño Ruiz <jaime.caamano.ruiz@ericsson.com>
6 years agoBug 8945 - Missing key is getVrfId. Supplied key is VpnInstanceOpDataEntryKey 80/61580/2
eupakir [Mon, 14 Aug 2017 07:02:31 +0000 (12:32 +0530)]
Bug 8945 - Missing key is getVrfId. Supplied key is VpnInstanceOpDataEntryKey

On a router delete, the internal VPN for that router was being removed
before handling external networks associated to that router.
Releasing router based lport tags, which is part of L3VPN Over VxLAN,
depends on vpn operational data, but the vpn data was being deleted much
before handling external networks for that router.

Change-Id: I72c0ff142b3929808afcfa7e49589b5420f48510
Signed-off-by: eupakir <kiran.n.upadhyaya@ericsson.com>
6 years agovpnmanager DJC enqueueJob without using AbstractDataStoreJob API 64/60264/4
Michael Vorburger [Wed, 12 Jul 2017 21:34:36 +0000 (03:04 +0530)]
vpnmanager DJC enqueueJob without using AbstractDataStoreJob API

because when we moved genius.DJC to infrautils.JC we had concluded that
this method does not need to be exposed publicly, and (at the time) was
only used in 1 place (here).

In order to be able to eventually remove genius.DJC and switch to
infrautils.JC, adjusting this use to be compatible with the new API is a
first step.

Change-Id: Ia025cc542096ce417b35f57cdc723ebc9528ab14
Signed-off-by: Michael Vorburger <vorburger@redhat.com>
6 years agoBump versions by x.(y+1).z for next dev cycle 92/61692/1
Thanh Ha [Mon, 14 Aug 2017 17:32:25 +0000 (13:32 -0400)]
Bump versions by x.(y+1).z for next dev cycle

Change-Id: Ibacad85a349937fa2a27554577419fdc8ceb4349
Signed-off-by: Thanh Ha <thanh.ha@linuxfoundation.org>
6 years agoRevert "Bug 8960: port information for 1 dpn is missing in subnet-op-data and port... 63/61563/2
Sam Hague [Fri, 11 Aug 2017 23:29:13 +0000 (23:29 +0000)]
Revert "Bug 8960: port information for 1 dpn is missing in subnet-op-data and port-op-data"

This reverts commit 679f82391862995bfea11011c217ba7a1a91cb5c.

Change-Id: I62bb7890803d5e5b51cf6f1d1bc359eeac75eb13
Signed-off-by: Sam Hague <shague@redhat.com>
6 years agoDo not catch Throwable 61/61461/3
Robert Varga [Wed, 9 Aug 2017 21:41:26 +0000 (23:41 +0200)]
Do not catch Throwable

Java code should never catch Errors, which catching Throwable does.
Catching Exceptions is more than adequate.

Change-Id: Iee3ae475438b7f872cb8f4a07dcd0187dc73657c
Signed-off-by: Robert Varga <robert.varga@pantheon.tech>
6 years agoBug 8972: dhcp-show does not display the defaults 91/61491/4
Kency Kurian [Thu, 10 Aug 2017 10:17:08 +0000 (15:47 +0530)]
Bug 8972: dhcp-show does not display the defaults

dhcp-show was not printing the default config values for lease time and
domain.

Also earlier the default value was hardcoded in this CLI instead of
fetching from thr constants file defined.

Change-Id: Ie5c3542bad7fd73bbe9aec5ab438ec46a1c3f87e
Signed-off-by: Kency Kurian <kency.kurian@ericsson.com>
Signed-off-by: Sam Hague <shague@redhat.com>
6 years agoBUG-8894 : display VPN interface count number for each VPN instance. 62/60762/2
Philippe Guibert [Wed, 26 Jul 2017 09:08:24 +0000 (10:08 +0100)]
BUG-8894 : display VPN interface count number for each VPN instance.

This value is displayed correctly in shell function.
vpn-instance-op-show --detail.

Change-Id: I9817aef44bc4b56889132aea3f17791b239bb7fd
Signed-off-by: Philippe Guibert <philippe.guibert@6wind.com>
6 years agoBug 8821 : BGP Manager / BGP counter incorrect with VPNv6 prefixes 07/60607/2
Philippe Guibert [Fri, 7 Jul 2017 12:08:30 +0000 (13:08 +0100)]
Bug 8821 : BGP Manager / BGP counter incorrect with VPNv6 prefixes

The commit consists in not only counting separately the prefixes for
VPNv4, VPNv6, and EVPN; but also sums all previous values to get the
total numver of prefixes. That counter obtained wast taking into account
only VPNv4. Now it includes VPNv6.

Change-Id: I1c6b4acb98870ae919ef06c229537abbd966697b
Signed-off-by: Philippe Guibert <philippe.guibert@6wind.com>
6 years agoNeutron Port allocation for DHCP Service 69/61469/2
Achuth Maniyedath [Thu, 11 May 2017 18:32:50 +0000 (00:02 +0530)]
Neutron Port allocation for DHCP Service

The feature enables DHCP service to make use of the
newly created Neutron ports provisioned by Openstack
networking-odl driver at the time of Subnet creation.
Additionaly an ARPResponder flow is also introduced to
service the ARP requests for these ports during VM
DHCP renewal.

All ArpResponder handling for Router interface gateway,
floating IP and DHCP ports will be moved to ElanService,
introducing a pipeline change for ARP handling.

LPort Dispatcher Table(17) -> ARP Check Table(43) -> ARPResponder Group
-> ELAN Base Table(48), ARP Responder Table(81), Controller
-> Egress Dispatcher Tabel (220)

Change-Id: If1c787c50bd3054766caaa6b11e6c8023402cce4
Depends-On: I2dce5e253d3c94180dd18e51125c5c18170b5c69
Signed-off-by: Achuth Maniyedath <achuth.m@altencalsoftlabs.com>
Signed-off-by: Vijayalakshmi Chickkamenahalli Nagaraju <vijayalakshmi.c@altencalsoftlabs.com>
Signed-off-by: karthik.p <karthik.p@altencalsoftlabs.com>
6 years agoBug 8960: port information for 1 dpn is missing in subnet-op-data and 12/61412/5
HANAMANTAGOUD V Kandagal [Wed, 9 Aug 2017 09:20:35 +0000 (14:50 +0530)]
Bug 8960: port information for 1 dpn is missing in subnet-op-data and
port-op-data

Upon PL reboot , if southbound event (PortUP) event is received first and
northbound event(OnSubnetAddedToVpn) is received later ,DPN will not be
updated in PortOpData.

Fix :
(1) When northbound event is received , SubnetOpDataEntry is created first
by using clustered wide lock based on subnetId.
Then PortOpDataEntry and subnetToDpn is created.

(2)Incase southbound event is received first,PortOpData entry may not be
available.In such case subnetId is retrieved from Neutron cache and
PortOpData entry will be created by the SubnetInterfaceStateChangeListener
thread.

Change-Id: I92ed4aa801cfcbc2da37366149b7c5f2fba2ed4c
Signed-off-by: HANAMANTAGOUD V Kandagal <hanamantagoud.v.kandagal@ericsson.com>
Signed-off-by: ehvkand <hanamantagoud.v.kandagal@ericsson.com>
6 years agoBump odlparent 2.0.2 to 2.0.4 46/61346/4
Stephen Kitt [Tue, 8 Aug 2017 16:14:07 +0000 (18:14 +0200)]
Bump odlparent 2.0.2 to 2.0.4

Change-Id: I5e1f577b3aea966b2340a89eb4010707e27f2628
Signed-off-by: Stephen Kitt <skitt@redhat.com>
6 years agoBug 8863: NPE at VpnFloatingIpHandler 54/60554/3
karthikeyan [Wed, 19 Jul 2017 09:12:03 +0000 (14:42 +0530)]
Bug 8863: NPE at VpnFloatingIpHandler

Problem Description:
=======================
The following exception was observed from VpnFloatingIpHandler in CSIT

Error in generate label or fib install process
java.lang.NullPointerException: Supplied value may not be null
org.opendaylight.netvirt.natservice.internal.VpnFloatingIpHandler.lambda$onAddFloatingIp$0(VpnFloatingIpHandler.java:194)[307:org.opendaylight.netvirt.natservice-impl:0.5.0.SNAPSHOT]

Solution:
=========
We need to enhance the pre-condition check in VpnFloatingIpHandler before
proceeding with any DNAT flow installation.

Have added the required null check for floatingIp ADD/REMOVE methods.

Change-Id: Ic516f8afc325a1e6eb515481abb2d0fef411336a
Signed-off-by: karthikeyan <karthikeyan.k@altencalsoftlabs.com>
6 years agoBug 8962: Fix non-parameterized LOG statements as per guidelines 25/61425/2
HANAMANTAGOUD V Kandagal [Wed, 9 Aug 2017 13:08:16 +0000 (18:38 +0530)]
Bug 8962: Fix non-parameterized LOG statements as per guidelines

Non parameterized LOG statement are suspected to take more CPU cycles than
parameterized one. Hence all non-parameterized logs are enhanced.

Also some more log enhancement for better debuggability.

Change-Id: I60d258aeb30ecd4c8442e7a2e6316b21844bb3e5
Signed-off-by: HANAMANTAGOUD V Kandagal <hanamantagoud.v.kandagal@ericsson.com>
6 years agoDocs: add supported combinations 39/60839/5
Sam Hague [Thu, 27 Jul 2017 21:13:05 +0000 (17:13 -0400)]
Docs: add supported combinations

Change-Id: I74bb7ec19059d44238c6449180c745cba11e149c
Signed-off-by: Sam Hague <shague@redhat.com>
6 years agoBug 8958: Java Null pointer exception for display vpn-config after 02/61402/2
HANAMANTAGOUD V Kandagal [Wed, 9 Aug 2017 07:56:01 +0000 (13:26 +0530)]
Bug 8958: Java Null pointer exception for display vpn-config after
deleting a vpn from CLI

When no VPN configuration is present in CONFIG datastore , success was
being returned in GetL3VPNOutput RPC. This lead to null ptr exception.

Now error message is being returned in RPC which is handled appropriately
and null ptr exception is avoided.

Change-Id: I04bce7a07cd933decf11de11e86ea958d26b7b86
Signed-off-by: HANAMANTAGOUD V Kandagal <hanamantagoud.v.kandagal@ericsson.com>
6 years agoBug 8882 - With conntrack SNAT communication with PNF fails 81/61381/4
Aswin Suryanarayanan [Tue, 8 Aug 2017 17:38:49 +0000 (23:08 +0530)]
Bug 8882 - With conntrack SNAT communication with PNF fails
Changed set_field to load action and set only the relevent bits and
other bits are preserved.

Depends on https://git.opendaylight.org/gerrit/#/c/61378/

Change-Id: I119b4daf214be796bfbc8a23fe3b09c81377a8c2
Signed-off-by: Aswin Suryanarayanan <asuryana@redhat.com>
6 years agoBug 8937 : High CPU utilization of Java process due to SNAT packet looping 52/61252/4
cgowdru [Mon, 7 Aug 2017 07:26:19 +0000 (12:56 +0530)]
Bug 8937 : High CPU utilization of Java process due to SNAT packet looping

Description:
If we have 2 VMs with same IP belong to two different network and the
subnet associated with different routers having same external network and
external bgpvpn. In such as case, when traffic initiated using same
internal port some both the VMs, one of the VMs doesn't undergo SNAT
translation and the packet gets continously looped between Controller and OVS.

When the packet is punted to controller, check is only done if the packet
is already recevied for an given internal-ip and internal-port. As a
result, VM1 packet is processed properly and SNAT translation happens. But
when VM2 packet arrives, we see with internal-ip and internal-port already
processed and hence we sent back to OVS without SNAT translation which
resulted in looping.

Change done to have a check of router-id along with internal-ip and
internal-port to uniquely differentiate VM1 and VM2 traffic seperatly and
perform SNAT translation properly for both.

Change-Id: I29b6aef96f353bef711f3fb2c1f0b9f6d75507a6
Signed-off-by: cgowdru <chetan.arakere@altencalsoftlabs.com>
6 years agoELAN service is not unbound when nova delete followed by neutron port delete 47/60447/2
Periyasamy Palanisamy [Mon, 17 Jul 2017 07:03:27 +0000 (12:33 +0530)]
ELAN service is not unbound when nova delete followed by neutron port delete

* Fix added to listen on interface config remove and invoke unbind service
* Changed elan interface job key while submitting to jc

Change-Id: I0cf8e29fa4afdc1dcf050198e8296071bd90efac
Signed-off-by: Periyasamy Palanisamy <periyasamy.palanisamy@ericsson.com>
6 years agoBUG 8883 : LOG enhancement for NAT service module 60/60760/9
cgowdru [Wed, 26 Jul 2017 07:00:11 +0000 (12:30 +0530)]
BUG 8883 : LOG enhancement for NAT service module

1) In most of the logs, "NAT Service" is used as a prefix. Since logs
already has the package Name, it would be better to print method name
instead of prefix.

2) Many logs have have string concatenated instead of passing as
parameters in these statement.

Change-Id: Ie41b7e113d4a7d291255dbc81148e21a6156f8c2
Signed-off-by: cgowdru <chetan.arakere@altencalsoftlabs.com>
6 years agoBug 7545 - FIP-FIP traffic 91/60991/7
Aswin Suryanarayanan [Tue, 1 Aug 2017 13:28:08 +0000 (18:58 +0530)]
Bug 7545 - FIP-FIP traffic
between vm in same n/w in same compute is not working in stateful SG
mode.

The patch fixes the FIP-FIP use case.
Add a dummy table to do a ct_lookup if the packet was already send to
the netfilter from the pipeline.

Change-Id: Ibc0d30aa1315d67938ebcbaddcfa2593113f9686
Signed-off-by: Aswin Suryanarayanan <asuryana@redhat.com>
6 years agoBUG 8876 - Fix to remove ELAN interface flows when external network deleted 83/61383/1
Vinh Nguyen [Thu, 3 Aug 2017 19:14:37 +0000 (12:14 -0700)]
BUG 8876 - Fix to remove ELAN interface flows when external network deleted

    - Problem: when deleting external network, the underlying ietf
      Interface might have been removed from the config DS prior
      to the call to delete the ELAN interface. As a result, the call
      interfaceManager.getInterfaceInfo returns null and the
      subsequent call to delete the ELAN interface fails to delete the
      flow entries for external network's ELAN interface.

    - Fix: invoke interfaceManager.getInterfaceInfoFromOperationalDataStore
      when delete External Network's ELAN interface

Change-Id: I764f3516d34a6d79aacff8dbedabb55219799ac9
Signed-off-by: Vinh Nguyen <vinh.nguyen@hcl.com>
6 years agoBug 8936: Fix IPv6 IPAM issues when an IPv6 subnet is added to IPv4 network 51/61251/3
Sridhar Gaddam [Mon, 7 Aug 2017 06:55:35 +0000 (12:25 +0530)]
Bug 8936: Fix IPv6 IPAM issues when an IPv6 subnet is added to IPv4 network

This patch addresses the following issues in ipv6service.

1. In an existing IPv4 network (which has a DHCP Port and some VMs)
   when you add an IPv6 subnet, the VMs/DHCP Port is not configured
   with the IPv6 address.
2. Similarly, in a multi-node setup when an IPv6 subnet is added to
   an existing IPv4 network and associated to the router, sometimes
   the necessary punt flows in Table_45 are not configured.

Change-Id: I0c91d40ae692f32567bc77f778d77af278e0b663
Signed-off-by: Sridhar Gaddam <sgaddam@redhat.com>
6 years agoRevert "Bug 8882 - With conntrack SNAT communication with PNF fails " 88/61288/2
Sam Hague [Mon, 7 Aug 2017 17:08:23 +0000 (17:08 +0000)]
Revert "Bug 8882 - With conntrack SNAT communication with PNF fails "

This reverts commit 0a1048ddc55621b2b675b7cef3e1b6c808693af1.

Change-Id: Ia0522b4c5f30dc11995bbe5e043d66f41f490cb7
Signed-off-by: Sam Hague <shague@redhat.com>
6 years agoBug 8789 - Designated DHCP DPN is missing. 69/59869/7
eaksahu [Mon, 3 Jul 2017 12:15:38 +0000 (17:45 +0530)]
Bug 8789 - Designated DHCP DPN is missing.

When l2gw connection is creaated and first dpn interface creation
happens at about same time there is a race in dhcp designated listener
which thinks that it has to update mcast only if there are no dpns in
elan.

when an elan dpn is removed, the dpns tep ip should not be removed from
mcast mac if that tep ip is the designated dpn tep ip.

when l2gw is deleted clear its connections also.

Change-Id: I6a216cecc609ba75f10ebfc750e492348e447122
Signed-off-by: eaksahu <a.k.sahu@ericsson.com>
6 years agoAdd chain egress classifier support 64/60764/5
Jaime Caamaño Ruiz [Fri, 14 Jul 2017 17:10:51 +0000 (19:10 +0200)]
Add chain egress classifier support

On scenarios where origin and destination of traffic are on the same
node, there is no tunnel id metadata to help steer the traffic back
to the destination on chain egress, thus SFC cannot take care of
this by itself. In a general case, the classifier is in a better
position to steer traffic to destination as it is aware on how it
was intercepted on the first place.

For netvirt classifier and the scenario mentioned above, the
classifier will copy the REG6 to NSH C4 on interception. On chain
egress, SFC will send the encapsulated packet back to the origin node
(only when C2 is 0, which will only happen when origin and destination
node are the same). There, the classifier will restore the
de-encapsulated packet to the egress dispatcher table with the proper
REG6 value taken from NSH C4. REG6 contains the the egress ifindex plus
the nex egress service in sequence from the classifier egress service
to handle the packet. This effectively restore the packet processing
where it left off on interception.

Change-Id: I1c494f24c5af530849faabcbfa8efcaa9cd4344a
Signed-off-by: Jaime Caamaño Ruiz <jaime.caamano.ruiz@ericsson.com>
6 years agoFix some logs 67/61067/3
David Suarez [Wed, 2 Aug 2017 18:38:31 +0000 (20:38 +0200)]
Fix some logs

Fix some logs.

Change-Id: I9a72aa7ec1563305596370528f70653eae2ff9ae
Signed-off-by: David Suarez <david.suarez.fuentes@gmail.com>
6 years agoReplace size()==0 by isEmpty() 98/61198/2
David Suarez [Fri, 4 Aug 2017 18:46:48 +0000 (20:46 +0200)]
Replace size()==0 by isEmpty()

Replace size()==0 by isEmpty(). It improves readability and avoid "=0".

Change-Id: I60f975639d32ba7f2c317779b7af5beb2f92ed1a
Signed-off-by: David Suarez <david.suarez.fuentes@gmail.com>
6 years agoBug 8882 - With conntrack SNAT communication with PNF fails 71/60871/4
Aswin Suryanarayanan [Fri, 28 Jul 2017 12:19:23 +0000 (17:49 +0530)]
Bug 8882 - With conntrack SNAT communication with PNF fails

Change set_field to load action and set only the relevent bits. Thus the
lport tag is preserved.

Depends on [1] https://git.opendaylight.org/gerrit/#/c/60870

Change-Id: I769254de971deed02cf510ee62db08c3d887070e
Signed-off-by: Aswin Suryanarayanan <asuryana@redhat.com>
6 years agoBUG 8914: Fix NPE in sfc.classifier-impl 58/61158/2
Jaime Caamaño Ruiz [Mon, 31 Jul 2017 14:56:09 +0000 (16:56 +0200)]
BUG 8914: Fix NPE in sfc.classifier-impl

NPE was due ACLs with no RedirectToSfc action. Such ACLs should be
ignored.

Change-Id: If4eb944308db5432919da1c5df8b00469a5df561
Signed-off-by: Jaime Caamaño Ruiz <jaime.caamano.ruiz@ericsson.com>
6 years agoBug 8346 - Conflicting modification for vpnNextHops. 29/59229/22
eupakir [Wed, 2 Aug 2017 13:47:58 +0000 (19:17 +0530)]
Bug 8346 - Conflicting modification for vpnNextHops.

The VpnInstanceListener used to wait for the vpn Interface Operational
data to clean up, before cleaning up data stores related to it.
There was a max wait time calculate, but some time interface op cleanup is
exceeding this wait time. As a result, the vpn instance related cleanup is
done before or at the same time as the vpn interface op cleanup,
resulting in these exceptions.
This fix remove the timed wait for the vpn instance, and cleans up the vpn
data based on notifications fired when both a vpn instance delete is
orchestrated and its footprint is cleared

Change-Id: I54d6369f30aa6d2a0e98df56b80cfcd6b4295978
Signed-off-by: eupakir <kiran.n.upadhyaya@ericsson.com>
Signed-off-by: Sam Hague <shague@redhat.com>
6 years agoCleanup 45/61045/1
David Suarez [Wed, 2 Aug 2017 14:51:15 +0000 (16:51 +0200)]
Cleanup

- Replace ArraList by List
- Add override
- Declaration of constants
- Replace size() by isEmpty()

Change-Id: Iefc721ded2ef21e7da9fc59b36e1195e47d77f08
Signed-off-by: David Suarez <david.suarez.fuentes@gmail.com>