On Sun, Sep 25, 2016 at 10:59 AM, Shmulik Ladkani <shmulik.ladk...@gmail.com> wrote: > Hi, > > On Sat, 24 Sep 2016 17:07:12 -0700 Cong Wang <xiyou.wangc...@gmail.com> wrote: >> One problem to use your code for us is that, the RX side of veth >> is inside containers, not visible to outside, perhaps we need some >> more parameter to tell the netns before the device name/index? >> Thoughts? > > Well, this is way trickier... > > tc_mirred doesn't cope with netns movement of the target device. > See 'mirred_device_event': upon NETDEV_UNREGISTER the 'tcfm_dev' gets > nullified. > > (dev_change_net_namespace sequence includes NETDEV_UNREGISTER, > dev_net_set, NETDEV_REGISTER). > > As upposed to veth, which keeps the peer netdev pointer (since veth peers > lifetime is coupled), here in act_mirred we can't easily distinguish a > "real" NETDEV_UNREGISTER vs a namespace change...
Yeah, isolation is a barrier for this, so we probably can't use this feature. But I still think it could be useful. Thanks.