Comment 2 for bug 1495002

Revision history for this message
Andriy Berestovskyy (aber-k) wrote :

The bug is confirmed. vRouter does not get the vif delete message from the Agent.

Here is an example:
root@l3:~/log# cat contrail-vrouter-dpdk-stdout.log | grep "vif 38"
// This is a normal add/delete sequence:
2015-12-15 17:25:43,318 VROUTER: Adding vif 38 (gen. 405) virtual device tapb3f27625-22
2015-12-15 17:25:43,319 UVHOST: Adding vif 38 virtual device tapb3f27625-22
2015-12-15 17:25:43,319 UVHOST: vif 38 socket tapb3f27625-22 FD is 167
2015-12-15 17:25:47,465 VROUTER: Deleting vif 38 virtual device
// Another one:
2015-12-15 17:27:23,847 VROUTER: Adding vif 38 (gen. 423) virtual device tapda29cbdb-f3
2015-12-15 17:27:23,847 UVHOST: Adding vif 38 virtual device tapda29cbdb-f3
2015-12-15 17:27:23,847 UVHOST: vif 38 socket tapda29cbdb-f3 FD is 167
2015-12-15 17:27:27,989 VROUTER: Deleting vif 38 virtual device
// No delete message for a reason:
2015-12-15 17:28:14,291 VROUTER: Adding vif 38 (gen. 432) virtual device tapbed8df27-35
2015-12-15 17:28:14,291 UVHOST: Adding vif 38 virtual device tapbed8df27-35
2015-12-15 17:28:14,291 UVHOST: vif 38 socket tapbed8df27-35 FD is 165
// After a restart, the Agent adds the interface back again:
2015-12-16 09:06:50,221 VROUTER: Adding vif 38 (gen. 39) virtual device tapbedb6892-36
2015-12-16 09:06:50,223 UVHOST: Adding vif 38 virtual device tapbedb6892-36
2015-12-16 09:06:50,223 UVHOST: vif 38 socket tapbedb6892-36 FD is 90

So basically, there are two issues here:
1) The vif delete message gets lost, so the "orphan" vifs appear.

2) After restart, Agent keeps adding those "orphan" vifs back to vRouter.
In kernel version we do not add vif if there is no tap in the kernel, but there is no such a check for the DPDK version.