Creating a Sampler
You can create a flow sampler to definer the NetFlow sampling rate for a flow.
Procedure
PurposeCommand or Action
Enters global configuration mode.configure terminal
Example:
switch# configure terminal
switch(config)#
Step 1
Creates a sampler and enters flow sampler
configuration mode. You can enter up to 63
alphanumeric characters for the flow sampler name.
sampler name
Example:
switch(config)# sampler testsampler
Step 2
(Optional)
(Optional) Describes this sampler. You can enter up
to 63 alphanumeric characters for the description.
description string
Example:
switch(config-flow-sampler)#
description samples
Step 3
Defines the number of samples to take per the
number of packets received. The sample-number
mode sample-number out-of
packet-number
Step 4
range is from 1 to 64, and the packet-number range
is from 1 to 65536 packets.
Example:
switch(config-flow-sampler)# mode 1
out-of 128
Returns to global configuration mode.exit
Example:
switch(config-flow-sampler)# exit
Step 5
(Optional)
Saves the change persistently through reboots and
restarts by copying the running configuration to the
startup configuration.
copy running-config startup-config
Example:
switch(config)# copy running-config
startup-config
Step 6
Applying a Flow Monitor to an Interface
You can not apply a flow monitor to an egress interface, only ingress Netflow is supported.Note
Cisco Nexus 5600 Series NX-OS System Management Configuration Guide, Release 7.x    
   OL-31641-01 271
Configuring NetFlow
Creating a Sampler