Calculating Net/Rom route quality

From Ohio Packet
Revision as of 11:54, 16 April 2010 by Opadmin (talk | contribs)
Jump to: navigation, search

Once you start building packet nodes, you may be faced with the question of how to setup the routing quality between them. This may be your node and then a node of a neighbor, or they may be both your nodes. We aim to give examples of real world routing with both TheNet (X1J4/Plus) as well as G8BPQ.


Why have quality?

The quality setting is intended to allow node operators to govern the amount of nodes they have on their nodes table as well as limiting the number of hops the nodes are permitted to take. Each node operator has their own idea what they want, this is just an example of how to calculate qualities and what it means.

A list of commands

For this example, we will assume there are two single port nodes running on the same frequency. The alias/callsigns are:

NODEA:KB8UVN-1 NODEB:KB8UVN-2

Both sides have locked routes of a quality 200 to one another. You can check the nodes tables on node A with the "n" command.

n
NODEA:KB8UVN-1} Nodes:
NODEB:KB8UVN-2

Next, you can list the nodes routing table with the "r" command (or "nr" with most *NOS systems).

For BPQ, this is

r
NODEA:KB8UVN-1} Routes:
> KB8UVN-2 200 1!

The leading > indicates the route is presently active, followed by the neighbor callsign, quality and destination nodes.

For TheNet, this is

r
NODEA:KB8UVN-1} Routes:
> 0 NODEB:KB8UVN-2 200 1 !

The leading > also indicates the route is presently active, followed by the port (0 = RF, 1 = RS-232/Diode Matrix), neighbor alias:callsign, quality, destination nodes.

Lastly, you can see available routes for a target node with the "n nodename" command.

For BPQ, this is

n nodeb
NODEA:KB8UVN-1} Routes to: NODEB:KB8UVN-2
> 200 6 1 KB8UVN-2

The leading > indicates the route is presently active, followed by the obsolence counter, port number and neighbor callsign.

For TheNet, this is

n nodeb
NODEA:KB8UVN-1} Routes to: NODEB:KB8UVN-2
> 200 5 0 NODEB:KB8UVN-2

The leading > indicates the route is presently active, followed by the quality, obsolence counter, port (0 = RF, 1 = RS-232/Diode Matrix) and lastly neighbor alias:callsign.

Node A to Node B

The route calculation here is straight forward:

RouteQuality Node A-B/256 * 256 = Node Quality

Plugging in the above values, this will be:

200/256 * 256 = 200 or a route quality of 200.


Node A to Node C via Node B

Building on the above example, we will now add Node C into the equation. For simplicity sake, we will assume Node B and Node C both have locked routes of quality 200 to each other.

The route calculation here then becomes

RouteQuality Node A-B/256 * RouteQuality Node B-C/256 * 256

Given the route qualities of 200 across the board, this would then be

200/256 * 200/256 * 256 = 156 or a route quality of 122 for Node C from Node A.


Node A to Node D via Node B and Node C

Lastly, we will assume there is a 4th node on the network called Node D. It is reachable only by Node C, which is only reachable by Node B. Additionally, the route between Node C and Node D is sometimes marginal, so it's quality is set at 128.

The calculation is now

RouteQuality Node A-B/256 * RouteQuality Node B-C/256 * RouteQuality Node C-D/256 * 256

Given the routes between A and B are 200, B and C are 200 and C and D are 128, this would equate to

200/256 * 200/256 * 128/256 * 256 = 78 or a route quality of 78 for Node D from node A.


What to do with Quality

The quality alone can be helpful in determining how reliable a path may be to a given node from one another, but there is also an advantage to governing how many hops a node may take to get from itself to another remote station. There is a parameter which may be set globally (BPQ and TheNet) or on a port basis (BPQ Only).

When set globally, this number is the absolute minimum a node must have to appear on the routing table. In the last example above, Node D would have a quality of 78 on Node A's table. If the node operator of Node A did not want Node D to be listed, they could simply set their MINQUAL to something greater than 78. Keep in mind, that setting this number too high may block reliable routes. If the node operator were to set MINQUAL to 160, this would not allow Node C to display (see calculations above).

When MINQUAL is specified on a port basis (BPQ), it sets a threshold of a given quality to broadcast to a port. This can allow a local nodes list to be large, but only share the higher quality nodes with your neighbor. This may be applicable in a situation where a multiport node may have marginal connections, such as on HF, but also have Net/Rom neighbors on VHF and UHF.

In some cases, it may be desirable to have locked routes to known systems, but not assign a high quality to new/uncoordinated systems. In this instance, you would set a port quality to something lower than the locked route quality, then set the MINQUAL to something at or below the port quality.