Antoni Segura Puimedon has posted comments on this change.
Change subject: sourcerouting: fix _getRoute not to include local routes ......................................................................
Patch Set 2:
(1 comment)
http://gerrit.ovirt.org/#/c/27262/2//COMMIT_MSG Commit Message:
Line 33: 240.0.0.0/24 via 240.0.0.1 dev test-network Line 34: default via 240.0.0.254 dev test-network Line 35: broadcast 127.255.255.255 dev lo proto kernel scope link src 127.0.0.1 Line 36: broadcast 240.0.0.255 dev test-network proto kernel scope link src 240.0.0.1 Line 37: local 10.34.60.31 dev eth1 proto kernel scope host src 10.34.60.31
With the pains of http://gerrit.ovirt.org/27236 fresh in mind, Assaf commen
The problem is that with the current code that does show table X, when X is equal or bigger than 2147483648 the following happens:
toniel602 vdsm (db78758*) # ip route add default via 10.34.60.33 table 2147483648 toniel602 vdsm (db78758*) # ip route add default via 10.34.60.34 table 2147483649 toniel602 vdsm (db78758*) # ip route add default via 10.34.60.35 table 214 toniel602 vdsm (db78758*) # ip route show table 2147483648 default via 10.34.60.35 dev eth1 default via 10.34.60.33 dev eth1 10.34.60.0/22 dev eth1 proto kernel scope link src 10.34.60.244 169.254.0.0/16 dev eth1 scope link metric 1002 default via 10.34.63.254 dev eth1 default via 10.34.60.34 dev eth1 default via 10.34.60.33 dev eth1 broadcast 127.255.255.255 dev lo proto kernel scope link src 127.0.0.1 broadcast 10.34.60.0 dev eth1 proto kernel scope link src 10.34.60.244 broadcast 10.34.63.255 dev eth1 proto kernel scope link src 10.34.60.244 broadcast 127.0.0.0 dev lo proto kernel scope link src 127.0.0.1 local 10.34.60.244 dev eth1 proto kernel scope host src 10.34.60.244 local 127.0.0.1 dev lo proto kernel scope host src 127.0.0.1 local 127.0.0.0/8 dev lo proto kernel scope host src 127.0.0.1 toniel602 vdsm (db78758*) #
As you can see, when asking for the 2147483648 table routes you also get the routes of tables 214 and 2147483649. It is true that currently we only have a network per device, so that this problem is kind of minimized. However, we might execute a command to remove these other routes (that the user might have created for the device) for our table. Since they will not exist in our table, the command will fail, log an error, and we will not procede to rule elimination. Line 38: local 240.0.0.1 dev test-network proto kernel scope host src 240.0.0.1 Line 39: broadcast 240.0.0.0 dev test-network proto kernel scope link src 240.0.0.1 Line 40: broadcast 10.34.60.0 dev eth1 proto kernel scope link src 10.34.60.31 Line 41: broadcast 10.34.63.255 dev eth1 proto kernel scope link src 10.34.60.31