NatUtil.waitForTransactionToComplete(writeFlowInvTx);
} else {
LOG.error("onAddFloatingIp : Error {} in rpc call to create custom Fib entries for Floating "
- + "IP Prefix {} on DPN {}, {}", result.getErrors(), externalIp, dpnId);
+ + "IP Prefix {} on DPN {}", result.getErrors(), externalIp, dpnId);
}
}
}, MoreExecutors.directExecutor());
NatUtil.waitForTransactionToComplete(removeFlowInvTx);
} else {
LOG.error("onRemoveFloatingIp : Error {} in rpc call to remove custom Fib entries for Floating "
- + "IP Prefix {} on DPN {}, {}", result.getErrors(), externalIp, dpnId);
+ + "IP Prefix {} on DPN {}", result.getErrors(), externalIp, dpnId);
}
}
}, MoreExecutors.directExecutor());
natPfibSubnetFlowRef);
mdsalManager.removeFlowToTx(natPfibFlowEntity, removeFlowInvTx);
LOG.debug("removeNaptFlowsFromActiveSwitch : Removed the flow in table {} with external subnet "
- + "Vpn Id {} as metadata on Napt Switch {} and vpnId {}", NwConstants.NAPT_PFIB_TABLE,
+ + "Vpn Id {} as metadata on Napt Switch {}", NwConstants.NAPT_PFIB_TABLE,
subnetVpnId, dpnId);
}
}
for (String ip : externalIps) {
String extIp = removeMaskFromIp(ip);
String naptFlowRef = getFlowRefNaptPreFib(dpnId, NwConstants.NAPT_PFIB_TABLE, extVpnId);
- LOG.info("removeNaptFlowsFromActiveSwitch : Remove the flow in the for the active switch"
+ LOG.info("removeNaptFlowsFromActiveSwitch : Remove the flow in table {} for the active switch"
+ " with the DPN ID {} and router ID {} and IP {} flowRef {}",
NwConstants.NAPT_PFIB_TABLE, dpnId, routerId, extIp, naptFlowRef);
FlowEntity natPfibVpnFlowEntity = NatUtil.buildFlowEntity(dpnId, NwConstants.NAPT_PFIB_TABLE, naptFlowRef);
long routerId, boolean isSnatCfgd, WriteTransaction writeFlowInvTx,
ProviderTypes extNwProvType) {
long changedVpnId = bgpVpnId;
- String logMsg = "installFlowsWithUpdatedVpnId : Update the BGP VPN ID {}";
+ String idType = "BGP VPN";
if (bgpVpnId == NatConstants.INVALID_ID) {
changedVpnId = routerId;
- logMsg = "installFlowsWithUpdatedVpnId : Update the router ID {}";
+ idType = "router";
}
List<BigInteger> switches = NatUtil.getDpnsForRouter(dataBroker, routerName);
groupId = installGroup(dpnId, routerName, bucketInfoForNonNaptSwitches);
}
- LOG.debug("{} in the SNAT miss entry pointing to group {} in the non NAPT switch {}",
- logMsg, changedVpnId, groupId, dpnId);
+ LOG.debug(
+ "installFlowsWithUpdatedVpnId : Update the {} ID {} in the SNAT miss entry pointing to group "
+ + "{} in the non NAPT switch {}", idType, changedVpnId, groupId, dpnId);
FlowEntity flowEntity = buildSnatFlowEntityWithUpdatedVpnId(dpnId, routerName, groupId, changedVpnId);
mdsalManager.addFlowToTx(flowEntity, writeFlowInvTx);
} else {
- LOG.debug("{} in the SNAT miss entry pointing to group in the primary switch {}",
- logMsg, changedVpnId, primarySwitchId);
+ LOG.debug(
+ "installFlowsWithUpdatedVpnId : Update the {} ID {} in the SNAT miss entry pointing to group "
+ + "in the primary switch {}", idType, changedVpnId, primarySwitchId);
FlowEntity flowEntity =
buildSnatFlowEntityWithUpdatedVpnIdForPrimrySwtch(primarySwitchId, routerName, changedVpnId);
mdsalManager.addFlowToTx(flowEntity, writeFlowInvTx);
- LOG.debug("{} in the Terminating Service table (table ID 36) which forwards the packet"
- + " to the table 46 in the Primary switch {}", logMsg, changedVpnId, primarySwitchId);
+ LOG.debug(
+ "installFlowsWithUpdatedVpnId : Update the {} ID {} in the Terminating Service table (table "
+ + "ID 36) which forwards the packet to the table 46 in the Primary switch {}",
+ idType, changedVpnId, primarySwitchId);
installTerminatingServiceTblEntryWithUpdatedVpnId(primarySwitchId, routerName, routerId,
changedVpnId, writeFlowInvTx, extNwProvType);
- LOG.debug("{} in the Outbound NAPT table (table ID 46) which punts the packet to the"
- + " controller in the Primary switch {}", logMsg, changedVpnId, primarySwitchId);
+ LOG.debug(
+ "installFlowsWithUpdatedVpnId : Update the {} ID {} in the Outbound NAPT table (table ID 46) "
+ + "which punts the packet to the controller in the Primary switch {}",
+ idType, changedVpnId, primarySwitchId);
createOutboundTblEntryWithBgpVpn(primarySwitchId, routerId, changedVpnId, writeFlowInvTx);
- LOG.debug("{} in the NAPT PFIB TABLE which forwards the outgoing packet to FIB Table in the"
- + "Primary switch {}", logMsg, changedVpnId, primarySwitchId);
+ LOG.debug(
+ "installFlowsWithUpdatedVpnId : Update the {} ID {} in the NAPT PFIB TABLE which forwards the"
+ + " outgoing packet to FIB Table in the Primary switch {}",
+ idType, changedVpnId, primarySwitchId);
installNaptPfibEntryWithBgpVpn(primarySwitchId, routerId, changedVpnId, writeFlowInvTx);
- LOG.debug("{} in the NAPT flows for the Outbound NAPT table (table ID 46) and the "
- + "INBOUND NAPT table (table ID 44) in the Primary switch {}",
- logMsg, changedVpnId, primarySwitchId);
+ LOG.debug(
+ "installFlowsWithUpdatedVpnId : Update the {} ID {} in the NAPT flows for the Outbound NAPT "
+ + "table (table ID 46) and the INBOUND NAPT table (table ID 44) in the Primary switch"
+ + " {}", idType, changedVpnId, primarySwitchId);
updateNaptFlowsWithVpnId(primarySwitchId, routerName, routerId, bgpVpnId);
LOG.debug("installFlowsWithUpdatedVpnId : Installing SNAT PFIB flow in the primary switch {}",
removeNatFlow(naptSwitch, NwConstants.OUTBOUND_NAPT_TABLE, routerId, internalIp, portnum);
} catch (Exception ex) {
LOG.error("removeSnatEntriesForPort : Failed to remove snat flow for internalIP {} with "
- + "Port {} protocol {} for routerId {} in OUTBOUNDTABLE of NaptSwitch {}: {}",
+ + "Port {} protocol {} for routerId {} in OUTBOUNDTABLE of NaptSwitch {}",
internalIp, portnum, protocol, routerId, naptSwitch, ex);
}
//Get the external IP address and the port from the model
naptManager.removePortFromPool(internalIpPort, externalIpAddress);
} catch (Exception ex) {
LOG.error("removeSnatEntriesForPort : releaseIpExtPortMapping failed, Removal of "
- + "ipportmap {} for router {} failed {}", internalIpPort, routerId, ex);
+ + "ipportmap {} for router {} failed", internalIpPort, routerId, ex);
}
}
}
try {
removeFromIpMapDS(segmentId, address.getIpAddress());
} catch (Exception e) {
- LOG.error("releaseAddressMapping : Removal of ipmap {} for router {} failed {}",
+ LOG.error("releaseAddressMapping : Removal of ipmap {} for router {} failed",
address.getIpAddress(), segmentId, e);
return false;
}
NatUtil.buildSnatIntIpPortIdentifier(segmentId, address.getIpAddress(), protocolType),
intIpProtocolType);
} catch (Exception ex) {
- LOG.error("removeSnatIntIpPortDS : Failed to write into snat-internal-ip-port-info with exception",ex);
+ LOG.error("removeSnatIntIpPortDS : Failed to write into snat-internal-ip-port-info with exception", ex);
}
- LOG.debug("removeSnatIntIpPortDS : Removing SnatIp {} Port {} of router {} from SNATIntIpport datastore : {}",
+ LOG.debug("removeSnatIntIpPortDS : Removing SnatIp {} Port {} of router {} from SNATIntIpport datastore",
address.getIpAddress(), address.getPortNumber(), segmentId);
}
natPfibSubnetFlowRef);
mdsalManager.removeFlowToTx(natPfibFlowEntity, removeFlowInvTx);
LOG.debug("removeSnatFlowsInOldNaptSwitch : Removed the flow in table {} with external subnet "
- + "Vpn Id {} as metadata on Napt Switch {} and vpnId {}", NwConstants.NAPT_PFIB_TABLE,
+ + "Vpn Id {} as metadata on Napt Switch {}", NwConstants.NAPT_PFIB_TABLE,
subnetVpnId, naptSwitch);
}
}
BigInteger naptDpn = NatUtil.getPrimaryNaptfromRouterName(dataBroker, routerNameAssociated);
if (naptDpn != null && naptDpn.equals(naptSwitch)) {
LOG.debug("removeSnatFlowsInOldNaptSwitch : Napt switch {} is also acting as primary "
- + "for router {}", routerIdAssociated);
+ + "for router {}", naptSwitch, routerIdAssociated);
switchSharedByRouters = true;
break;
}
IpPortExternal ipPortExternal = ipPortMap.getIpPortExternal();
if (ipPortExternal == null) {
LOG.debug("removeSnatFlowsInOldNaptSwitch : External Ipport mapping not found for internalIp {} "
- + "with port {} for router", internalIp, internalPort, routerId);
+ + "with port {} for router {}", internalIp, internalPort, routerId);
continue;
}
String externalIp = ipPortExternal.getIpAddress();
} else {
if (naptSwitch.equals(BigInteger.ZERO)) {
LOG.warn("isNaptSwitchDown : No napt switch is elected since all the switches for router {}"
- + " are down. SNAT IS NOT SUPPORTED FOR ROUTER {}", routerName);
+ + " are down. SNAT IS NOT SUPPORTED FOR ROUTER {}", routerName, routerName);
boolean naptUpdatedStatus = updateNaptSwitch(routerName, naptSwitch);
if (!naptUpdatedStatus) {
LOG.debug("isNaptSwitchDown : Failed to update naptSwitch {} for router {} in ds",
vpnId, routerId, bgpVpnId, sourceAddress, externalAddress, proto, extGwMacAddress);
} catch (RuntimeException ex) {
LOG.error("handleNatFlowsInNewNaptSwitch : Failed to add flow in OUTBOUND_NAPT_TABLE for "
- + "routerid {} dpnId {} ipport {}:{} proto {} extIpport {}:{} BgpVpnId {} - {}",
+ + "routerid {} dpnId {} ipport {}:{} proto {} extIpport {}:{} BgpVpnId {}",
routerId, newNaptSwitch, internalIpAddress,
intportnum, proto, externalAddress, extportNumber, bgpVpnId, ex);
return false;
MDSALUtil.syncWrite(dataBroker, LogicalDatastoreType.CONFIGURATION,
NatUtil.getRouterInterfaceId(interfaceName), getRouterInterface(interfaceName, routerId));
} catch (Exception e) {
- LOG.error("add: Unable to write data in RouterInterface model", e.getMessage());
+ LOG.error("add: Unable to write data in RouterInterface model", e);
}
org.opendaylight.yang.gen.v1.urn.ietf.params.xml.ns.yang.ietf.interfaces.rev140508.interfaces
mdsalManager.removeFlowToTx(flowEntity, writeFlowInvTx);
} catch (Exception ex) {
- LOG.error("removeSNATFromDPN : SNAT->Failed to remove default SNAT miss entry flow entity {} : {}",
+ LOG.error("removeSNATFromDPN : SNAT->Failed to remove default SNAT miss entry flow entity {}",
flowEntity, ex);
return;
}
long groupId = externalRouterListner.installGroup(srcDpnId, routerName, bucketInfoForNonNaptSwitches);
LOG.debug("hndlTepAddOnNonNaptSwitch : SNAT -> in the SNAT miss entry pointing to group {} "
- + "in the non NAPT switch {}", vpnId, groupId, srcDpnId);
+ + "in the non NAPT switch {}", groupId, srcDpnId);
FlowEntity flowEntity =
externalRouterListner.buildSnatFlowEntityWithUpdatedVpnId(srcDpnId, routerName, groupId, vpnId);
mdsalManager.addFlowToTx(flowEntity, writeFlowInvTx);
Uuid networkId = routerData.get().getNetworkId();
if (networkId == null) {
LOG.error("hndlTepDelForSnatInEachRtr : SNAT->Ignoring TEP delete for the DPN {} having the router {} "
- + "since the Router instance {} not found in ExtRouters model b/w SRC IP {} and DST IP {} "
- + "and TUNNEL NAME {} ", dpnId, tunnelType, srcTepIp, destTepIp, tunnelName);
+ + "since the Router instance {} not found in ExtRouters model b/w SRC IP {} and DST "
+ + "IP {} and TUNNEL NAME {} ", dpnId, routerData.get().getRouterName(), tunnelType,
+ srcTepIp, destTepIp, tunnelName);
return;
}
BigInteger vmDpnId = getDpnForInterface(ifaceMgrRpcService, vmInterfaceName);
if (vmDpnId.equals(BigInteger.ZERO) || !vmDpnId.equals(curDpnId)) {
LOG.debug("removeFromDpnRoutersMap : DPN ID {} for the removed interface {} is not the same as that of "
- + "the DPN ID for the checked interface {} ",
+ + "the DPN ID {} for the checked interface {}",
curDpnId, vpnInterfaceName, vmDpnId, vmInterfaceName);
continue;
}
extNwProvType);
} else {
LOG.debug("onRouterAssociatedToVpn : Ignoring the Router {} association with VPN {} "
- + "since it is not external router", routerName);
+ + "since it is not external router", routerName, vpnName);
}
NatUtil.waitForTransactionToComplete(writeFlowInvTx);
extNwProvType);
} else {
LOG.debug("onRouterDisassociatedFromVpn : Ignoring the Router {} association with VPN {} "
- + "since it is not external router", routerName);
+ + "since it is not external router", routerName, vpnName);
}
NatUtil.waitForTransactionToComplete(writeFlowInvTx);
BigInteger dpnId = NatUtil.getDpnForInterface(interfaceManager, portName);
if (dpnId.equals(BigInteger.ZERO)) {
LOG.warn("handleDNATConfigurationForRouterAssociation : DPN not found for {}, "
- + "skip handling of router {} association with vpn", portName, routerName, vpnName);
+ + "skip handling of router {} association with vpn {}", portName, routerName, vpnName);
continue;
}
BigInteger dpnId = NatUtil.getDpnForInterface(interfaceManager, portName);
if (dpnId.equals(BigInteger.ZERO)) {
LOG.debug("handleDNATConfigurationForRouterDisassociation : DPN not found for {}, "
- + "skip handling of router {} association with vpn", portName, routerName, vpnName);
+ + "skip handling of router {} association with vpn {}", portName, routerName, vpnName);
continue;
}
List<InternalToExternalPortMap> intExtPortMapList = port.getInternalToExternalPortMap();
5, String.format("%s:%d", "TST Flow Entry ", serviceId), 0, 0,
COOKIE_TUNNEL.add(BigInteger.valueOf(serviceId)), mkMatches, null);
mdsalManager.removeFlowToTx(dpnId, flowEntity, removeFlowInvTx);
- LOG.debug("removeTunnelTableEntry : Terminating service Entry for dpID {} : label : {} removed successfully {}",
+ LOG.debug("removeTunnelTableEntry : Terminating service Entry for dpID {} : label : {} removed successfully",
dpnId, serviceId);
}
mdsalManager.addFlowToTx(dpId, flowEntity, writeFlowInvTx);
- LOG.debug("makeLFibTableEntry : LFIB Entry for dpID {} : label : {} modified successfully {}", dpId, serviceId);
+ LOG.debug("makeLFibTableEntry : LFIB Entry for dpID {} : label : {} modified successfully", dpId, serviceId);
}
private void removeLFibTableEntry(BigInteger dpnId, long serviceId, WriteTransaction removeFlowInvTx) {