nitefood / asn

ASN / RPKI validity / BGP stats / IPv4v6 / Prefix / URL / ASPath / Organization / IP reputation / IP geolocation / IP fingerprinting / Network recon / lookup API server / Web traceroute server
MIT License
1.33k stars 161 forks source link

Two routers with same IP address are treated as "routing loop" #20

Closed robert-scheck closed 2 years ago

robert-scheck commented 2 years ago

Two routers with same IP address are treated as "routing loop", even there is no real routing loop. From asn output while using commit 64e92533f57e9261d1d6588b4714a4183fc3c304:

 Hop IP Address                                                                                  Loss%      Ping avg     AS Information                                                                                         
  1. fritz.box (192.168.0.1)                                                                        0%        1.2 ms    BOGON  rfc1918 (Private Space)                                                                          
  2. dslb-084-059-211-001.084.059.pools.vodafone-ip.de (84.59.211.1)                                0%        5.5 ms   [AS3209] VODANET International IP-Backbone of Vodafone, DE                                               
  3. 88.79.14.158                                                                                   0%        5.2 ms   [AS3209] VODANET International IP-Backbone of Vodafone, DE                                               
  4. 88.79.15.124                                                                                   0%        5.5 ms   [AS3209] VODANET International IP-Backbone of Vodafone, DE                                               
  5. 188.111.129.42                                                                                 0%        6.6 ms   [AS3209] VODANET International IP-Backbone of Vodafone, DE                                               
  6. 145.254.2.209                                                                                  0%       10.2 ms   [AS3209] VODANET International IP-Backbone of Vodafone, DE                                               
  7.  no route to host (routing loop detected)                                                    100%             *   (No reply)                                                                    

However, in mtr it looks like this:

$ mtr -w -z <…>
Start: 2021-10-14T01:31:28+0200
HOST: tux.example.net                                               Loss%   Snt   Last   Avg  Best  Wrst StDev
  1. AS???    fritz.box                                              0.0%    10    1.1   1.1   1.0   1.1   0.0
  2. AS3209   dslb-084-059-211-001.084.059.pools.vodafone-ip.de      0.0%    10    5.5   5.4   5.0   6.6   0.5
  3. AS3209   88.79.14.158                                           0.0%    10    5.0   5.2   4.8   5.8   0.3
  4. AS3209   88.79.15.124                                           0.0%    10    5.7   5.9   5.1   6.5   0.4
  5. AS3209   188.111.129.42                                         0.0%    10    7.0   6.8   6.2   8.1   0.5
  6. AS3209   145.254.2.209                                          0.0%    10   10.6  10.5  10.1  11.4   0.4
  7. AS3209   145.254.2.209                                          0.0%    10    9.7  10.1   9.6  11.2   0.4
  8. AS6830   de-str01c-rb01-be-1050.aorta.net                       0.0%    10   12.5  12.7  12.3  13.8   0.5
  9. AS3209   <…>                                                    0.0%    10   12.2  12.2  11.9  12.7   0.2
 10. AS<…>    <…>                                                    0.0%    10   12.0  18.7  11.7  78.2  20.9
$ 

So yes, the same IP address appears twice in the trace, but there is still no routing loop, the target can be properly reached.

nitefood commented 2 years ago

I have in all honesty never seen that happen IRL, but there's always a first time, I guess :-) Would you mind commenting out these lines and confirming there's no more false positive loop detection? Thanks for your feedback!

robert-scheck commented 2 years ago

Yes, after commenting out these lines, there is no more false positive loop detection.