> On Aug 4, 2015, at 12:17 PM, Ben Pfaff <b...@nicira.com> wrote: > > On Tue, Aug 04, 2015 at 04:05:58AM +0000, Wenyu Zhang wrote: >> In ipfix and sflow, the sampling rate can be set as 1, which means >> 100%. And in order to make 100% packets sampled, I work out a patch >> in datapath, which is for review on net-next. And the same change >> seems need to be added into lib/odp-execute.c too. Do you mean that it >> is not necessary here? > > I mean that we should modify the IPFIX and sFlow sampling code so that > in the 0% and 100% sample rates cases it doesn't generate a sample > action; there isn't any value in it. > > This situation is a little different from the kernel situation, since we > know exactly what actions can be fed to the userspace datapath in > odp-execute.c, since the actions that it executes are generated by > another part of the same source tree. The kernel datapath, however, > should be equally capable of handling actions from sources other than > the Open vSwitch userspace.
It is OK that sample action shouldn’t be generated when the sampling rate is 0%. But I wonder why we shouldn’t generate sample action when the sampling rate is 100%. It should happen in kernel datapth. Or you means that the 100% sampling rate case won’t happen in the userspace datapath? _______________________________________________ dev mailing list dev@openvswitch.org http://openvswitch.org/mailman/listinfo/dev