Bug 4472 - netvirt: IlligalArgumentException in NAT provider
authorIsaku Yamahata <isaku.yamahata@intel.com>
Wed, 14 Oct 2015 22:06:19 +0000 (15:06 -0700)
committerIsaku Yamahata <isaku.yamahata@intel.com>
Wed, 14 Oct 2015 23:49:27 +0000 (16:49 -0700)
commitce9d547836b2d134f84a714179410a0a4bdee9b9
tree3bc10f6ba3f408f97c75a2dedb74e9da3bf5053e
parent65437efe78b85d399d93228dd682a1c10bf5325f
Bug 4472 - netvirt: IlligalArgumentException in NAT provider

This patch adds work around code for ipv6 cidr notation is given.
Otherwise following exception occurs.

> 2015-10-14 13:38:55,125 | ERROR | ntDispatcherImpl | NeutronL3Adapter                 | 392 - org.opendaylight.ovsdb.openstack.net-virt - 1.2.1.SNAPSHOT | ProgramRouterInterface failed for mac:FA:16:3E:E0:A8:B5 addr:fd14:5ac7:ba3::1/64 node:ovsdb://uuid/8f75c49c-52b9-4303-8633-a80f0361429b/bridge/br-int srcTunId:external destTunId:1083 action:ADD status:Not Implemented: Not Implemented (0)
> 2015-10-14 13:38:55,126 | DEBUG | ntDispatcherImpl | ArpResponderService              | 393 - org.opendaylight.ovsdb.openstack.net-virt-providers - 1.2.1.SNAPSHOT | ipv6 address case is not implemented yet. dpid 209308480409166 segmentationId 1083 macAddressStr, ipAddress FA:16:3E:E0:A8:B5 action /fd14:5ac7:ba3:0:0:0:0:1
> 2015-10-14 13:38:55,126 | ERROR | ntDispatcherImpl | NeutronL3Adapter                 | 392 - org.opendaylight.ovsdb.openstack.net-virt - 1.2.1.SNAPSHOT | ProgramStaticArp failed for mac:FA:16:3E:E0:A8:B5 addr:fd14:5ac7:ba3::1 dpid:209308480409166 segOrOfPort:1083 action:ADD status:Not Implemented: Not Implemented (0)
> 2015-10-14 13:38:55,126 | ERROR | ntDispatcherImpl | EventDispatcher                  | 392 - org.opendaylight.ovsdb.openstack.net-virt - 1.2.1.SNAPSHOT | Exception in dispatching event NorthboundEvent [handler=NEUTRON_PORT, action=ADD, port=NeutronPort [portUUID=4b19acf4-d644-4fe7-8643-852c25cbf604, networkUUID=821f7a2b-b991-48b0-a39c-b0ef264bd321, name=, adminStateUp=true, status=ACTIVE, macAddress=FA:16:3E:E0:A8:B5, fixedIPs=[Neutron_IPs{ipAddress='fd14:5ac7:ba3::1', subnetUUID='54a7f233-1fdb-4d40-bd44-275f180e9a64'}], deviceID=738d6a7c-43bd-469d-bfed-6bcc6ffe5dca, deviceOwner=network:router_interface, tenantID=dc27e3a1cff64a1cb85c7f24899c3eee, securityGroups=[], bindinghostID=, bindingvnicType=normal, bindingvnicType=normal], subnet=null, router=null, routerInterface=null, floatingIP=null, network=null, loadBalancer=null, loadBalancerPool=null, loadBalancerPoolMember=null]
> java.lang.IllegalArgumentException: Supplied value "fd14:5ac7:ba3::/64" does not match required pattern "^(([0-9]|[1-9][0-9]|1[0-9][0-9]|2[0-4][0-9]|25[0-5])\.){3}([0-9]|[1-9][0-9]|1[0-9][0-9]|2[0-4][0-9]|25[0-5])/(([0-9])|([1-2][0-9])|(3[0-2]))$"
>         at com.google.common.base.Preconditions.checkArgument(Preconditions.java:145)[64:com.google.guava:18.0.0]
>         at org.opendaylight.yang.gen.v1.urn.ietf.params.xml.ns.yang.ietf.inet.types.rev100924.Ipv4Prefix.<init>(Ipv4Prefix.java:49)[216:org.opendaylight.mdsal.model.ietf-inet-types:2010.9.24.8-SNAPSHOT]
>         at org.opendaylight.ovsdb.openstack.netvirt.providers.openflow13.services.OutboundNatService.programIpRewriteExclusion(OutboundNatService.java:167)[393:org.opendaylight.ovsdb.openstack.net-virt-providers:1.2.1.SNAPSHOT]
>         at org.opendaylight.ovsdb.openstack.netvirt.impl.NeutronL3Adapter.programIpRewriteExclusionStage2(NeutronL3Adapter.java:1143)[392:org.opendaylight.ovsdb.openstack.net-virt:1.2.1.SNAPSHOT]
>         at org.opendaylight.ovsdb.openstack.netvirt.impl.NeutronL3Adapter.programIpRewriteExclusionStage1(NeutronL3Adapter.java:1128)[392:org.opendaylight.ovsdb.openstack.net-virt:1.2.1.SNAPSHOT]
>         at org.opendaylight.ovsdb.openstack.netvirt.impl.NeutronL3Adapter.programFlowsForNeutronRouterInterface(NeutronL3Adapter.java:807)[392:org.opendaylight.ovsdb.openstack.net-virt:1.2.1.SNAPSHOT]
>         at org.opendaylight.ovsdb.openstack.netvirt.impl.NeutronL3Adapter.handleNeutronRouterInterfaceEvent(NeutronL3Adapter.java:298)[392:org.opendaylight.ovsdb.openstack.net-virt:1.2.1.SNAPSHOT]
>         at org.opendaylight.ovsdb.openstack.netvirt.impl.NeutronL3Adapter.handleNeutronPortEvent(NeutronL3Adapter.java:245)[392:org.opendaylight.ovsdb.openstack.net-virt:1.2.1.SNAPSHOT]
>         at org.opendaylight.ovsdb.openstack.netvirt.PortHandler.doNeutronPortCreated(PortHandler.java:66)[392:org.opendaylight.ovsdb.openstack.net-virt:1.2.1.SNAPSHOT]
>         at org.opendaylight.ovsdb.openstack.netvirt.PortHandler.processEvent(PortHandler.java:161)[392:org.opendaylight.ovsdb.openstack.net-virt:1.2.1.SNAPSHOT]
>         at org.opendaylight.ovsdb.openstack.netvirt.impl.EventDispatcherImpl.dispatchEvent(EventDispatcherImpl.java:95)[392:org.opendaylight.ovsdb.openstack.net-virt:1.2.1.SNAPSHOT]
>         at org.opendaylight.ovsdb.openstack.netvirt.impl.EventDispatcherImpl.access$200(EventDispatcherImpl.java:28)[392:org.opendaylight.ovsdb.openstack.net-virt:1.2.1.SNAPSHOT]
>         at org.opendaylight.ovsdb.openstack.netvirt.impl.EventDispatcherImpl$1.run(EventDispatcherImpl.java:57)[392:org.opendaylight.ovsdb.openstack.net-virt:1.2.1.SNAPSHOT]
>         at java.util.concurrent.Executors$RunnableAdapter.call(Executors.java:511)[:1.8.0_60]
>         at java.util.concurrent.FutureTask.run(FutureTask.java:266)[:1.8.0_60]
>         at java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1142)[:1.8.0_60]
>         at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:617)[:1.8.0_60]
>         at java.lang.Thread.run(Thread.java:745)[:1.8.0_60]

Change-Id: I1559667adde1c14b5627df3b7212e404998ce897
Signed-off-by: Isaku Yamahata <isaku.yamahata@intel.com>
openstack/net-virt-providers/src/main/java/org/opendaylight/ovsdb/openstack/netvirt/providers/openflow13/services/InboundNatService.java
openstack/net-virt-providers/src/main/java/org/opendaylight/ovsdb/openstack/netvirt/providers/openflow13/services/OutboundNatService.java