Router FAQ -

(Frequently Asked Route-Debugging Questions)

Q: I'm having trouble controlling paths with routing costs. How to debug how path-costs are being compared?
A: The Router's verbosity level 3 shows you the costs as it compares paths.
Example:
          router -v 3 netinfo

Certainly for a large network, this would be tedious to follow. I suggest the following trick: Give your path's cost a unique numeric sequence, for example, instead of 10000, use something like 123450.
Then do:
          router -v 3 netinfo | grep 12345

You should see just the path comparisons which contain your suspected link.
Example:
          Comparing Node 46's distance from 103 of 123450
            to node 48's distance of 1000000000.0
          Comparing Node 46's distance from 28 of 1.0
            to node 48's distance of 123451.
          Comparing Node 46's distance from 103 of 123453
            to node 47's distance of 1000000000.0

Note that the Router considers 1e9 (=1000000000.0) as the infinite, or not-connected distance. (All paths are initialized to that distance which is replaced as shorter paths are found.)

Also note that the paths involving your link get costs of 123450, 123451, 123452, etc., as unity-cost links are added to make paths, so don't search for 123450 as your cost, but truncate the lower digit(s). One digit gives you ten hops. Two digits would give a hundred, assuming your other links are unity. Obviously, all bets are off if you have other links with costs much higher than 1 which would destroy your match pattern more quickly.

Here are some other things to check:

  1. The Router runs from information in file netinfo, which depends on toptab.dat. Make sure you have an up-to-date toptab.dat. Also remember that netinfo comes from running sim.exe -net. (Normally performed automatically by GUI.) Make sure you have an up-to-date executable sim.exe which made the netinfo file (from toptab.dat).

  2. Behind the scenes to the Router, is the the netinfo.net intermediate file. The Router makes netinfo.net from netinfo. The netinfo.net file is a purely numeric translation of netinfo's net-list section. Device names are replaced by their logical ID numbers. Port names are replaced by the logical index numbers.

    You should be able to search for your unique cost (ex. 12345) within the netinfo.net file.
    Example:
              grep 12345 netinfo.net

If you can check these things, it may help isolate a problem. For example, the link may be getting eliminated from the routing calculation altogether, perhaps because it was not attached to a "numbered" port, etc..





(Questions, Comments, & Suggestions: admin@csim.com)