Bug 2650

Summary: In aodv destination sequence numbers is not incremented in case of Local Repair
Product: ns-3 Reporter: Deepti <jsmsscd>
Component: aodvAssignee: Deepti <jsmsscd>
Status: NEEDINFO ---    
Severity: normal CC: jsmsscd, tahiliani.nitk, tomh
Priority: P3    
Version: ns-3.25   
Hardware: All   
OS: Linux   
Attachments: patch file for aodv-packet.h
patch flie to change aodv-routing-protocol.cc

Description Deepti 2017-02-06 01:06:01 EST
AS per RFC 3561 of AODV protocol in section 6.12 (Local Repair) on the occurrence of link break Nodes must increment the destination sequence numbers of the routing entries contained in the RERR message before transmitting to nodes in precursor list. The  function which initiates  RERR is 
void RoutingProtocol::SendRerrWhenBreaksLinkToNextHop (Ipv4Address nextHop) in this function the first call is m_routingTable.LookupRoute (nextHop, toNextHop). when we read this function in aodvrtable.cc in case of true the following code is given where the destination sequence number is not incremented anywhere.

std::map<Ipv4Address, RoutingTableEntry>::const_iterator i =
    m_ipv4AddressEntry.find (id);
  if (i == m_ipv4AddressEntry.end ())
    {
      NS_LOG_LOGIC ("Route to " << id << " not found");
      return false;
    }
  rt = i->second;
  NS_LOG_LOGIC ("Route to " << id << " found");
  return true;
Comment 1 Tom Henderson 2017-02-07 09:52:14 EST
Thank you for the report; are you able to provide a patch to fix it?
Comment 2 Deepti 2017-03-16 03:38:55 EDT
Created attachment 2801 [details]
patch file for aodv-packet.h

Sir I tried to resole the problem by adding the function given below in aodv-packet.h file
void SetDestCount (uint32_t sdc) { if (sdc==0) m_unreachableDstSeqNo.clear (); }
Comment 3 Deepti 2017-03-16 03:42:23 EDT
Created attachment 2802 [details]
patch flie to change aodv-routing-protocol.cc
Comment 4 Deepti 2017-05-18 04:07:00 EDT
(In reply to Deepti from comment #2)
> Created attachment 2801 [details]
> patch file for aodv-packet.h
> 
> Sir I tried to resole the problem by adding the function given below in
> aodv-packet.h file
> void SetDestCount (uint32_t sdc) { if (sdc==0) m_unreachableDstSeqNo.clear
> (); }