sFlow is a technology for monitoring traffic in data networks containing switches and routers. It consists of an sFlow Agent running on the router, and a central sFlow Collector.

The sFlow Agent uses sampling technology to capture traffic statistics from the device it is monitoring. sFlow Datagrams are used to immediately forward the sampled traffic statistics to an sFlow Collector for analysis.

More information is available in RFC 3176 and sflow.org.

To configure sFlow you need to specify the collector endpoint and which interfaces will be polled.

For each interface, you can tune the sampling interval or let the system choose a value according to the speed of interface.

Configuration example:

vrouter running config# vrf main sflow
vrouter running sflow# sflow-collector port 6343
vrouter running sflow# sflow-interface eth1
vrouter running sflow# sflow-sampling speed 10G rate auto
vrouter running sflow# commit

To display the sFlow state:

vrouter running config# show state vrf main sflow
    sflow-collector port 6343
    enabled true
    sflow-interface eth1
    sflow-port 36343
    polling disabled
    sflow-sampling speed other rate auto
    sflow-sampling speed 100M rate auto
    sflow-sampling speed 1G rate auto
    sflow-sampling speed 10G rate auto
    sflow-sampling speed 40G rate auto

The same configuration can be made using this NETCONF XML configuration:

vrouter> show config xml absolute vrf main sflow
<config xmlns="urn:6wind:vrouter">
    <sflow xmlns="urn:6wind:vrouter/sflow">

See also

The command reference for details.