Help us improve your experience.

Let us know what you think.

Do you have time for a two-minute survey?

Navigation
Guide That Contains This Content
[+] Expand All
[-] Collapse All

    Configuring sFlow Technology for Network Monitoring (CLI Procedure)

    sFlow technology is a network monitoring technology for high-speed switched or routed networks. It is a technology that is based on statistical sampling. You can configure sFlow technology to continuously monitor traffic at wire speed on all interfaces simultaneously. Junos OS fully supports the sFlow standard described in RFC 3176, InMon Corporation's sFlow: A Method for Monitoring Traffic in Switched and Routed Networks.

    To configure sFlow features:

    1. Configure the IP address and the UDP port of the collector:
      [edit protocols]
      user@switch# set sflow collector ip4/ipv6-address udp-port port-number

      The default UDP port is 6343,

    2. Enable sFlow technology on a specific interface:
      [edit protocols sflow]
      user@switch# set interfaces interface-name

      Note: You cannot enable sFlow technology on a Layer 3 VLAN-tagged interface.

      You cannot enable sFlow technology on a link aggregation group (LAG), but you can enable it on the member interfaces of a LAG.

    3. Specify in seconds how often the sFlow agent polls interfaces:
      [edit protocols sflow]
      user@switch# set polling-interval seconds

      Note: Specify 0 if you do not want to poll the interface.

    4. Specify the rate at which packets must be sampled. You can specify either an egress or an ingress sampling rate, or both.

      Note: We recommend that you configure the same sampling rates on all the ports on a line card. If you configure different sampling rates on different ports, the lowest value is used for all ports. You could still configure different rates on different line cards.

      To specify an egress sampling rate:

      [edit protocols sflow]
      user@switch# set sample-rate egress number

      To specify an ingress sampling rate:

      [edit protocols sflow]
      user@switch# set sample-rate ingress number
    5. To configure the polling interval and the egress and ingress sampling rates at the interface level:
      [edit protocols sflow interfaces interface-name]
      user@switch# set polling-interval seconds
      [edit protocols sflow interfaces]
      user@switch# set sample-rate egress number
      [edit protocols sflow interfaces]
      user@switch# set sample-rate ingress number

      Note: The interface-level configuration overrides the global configuration.

    6. To specify an IP address to be used as the agent ID for the sFlow agent:
      [edit protocols sflow]
      user@switch# set agent-id ip4/ipv6 -address
    7. To specify the source IP address to be used for sFlow datagrams:
      [edit protocols sflow]
      user@switch# set source-ip ip4/ipv6-address

    Modified: 2018-02-20