コンフィグレーションガイド Vol.2
本装置でsFlow統計機能を使用した場合,サンプリング間隔の調整方法として次のものがあります。
- <この項の構成>
- (1) 回線速度から調整する
- (2) 詳細情報から調整する
(1) 回線速度から調整する
sFlow統計機能を有効にしている全ポートのppsをshow interfacesコマンドで確認し,受信パケットを対象にしている場合は「Input rate」を合計してください。もし,送信パケットを対象にしている場合は,「Output rate」も合計してください。その合計値を100で割った値が,目安となるサンプリング間隔となります。この値でサンプリング間隔を設定後,show sflowコマンドで廃棄数が増えないかどうかを確認してください。
ポート0/4とポート0/5に対して受信パケットをとる場合の目安となるサンプリング間隔の例を次に示します。
図21-12 show interfacesコマンドの実行結果
> show interfaces gigabitethernet 0/4 Date 20XX/12/24 17:18:54 UTC NIF0: Port4: active up 100BASE-TX full(auto) 0012.e220.ec30 Time-since-last-status-change:1:47:47 Bandwidth:10000kbps Average out:0Mbps Average in:5Mbps Peak out:5Mbps at 15:44:36 Peak in:5Mbps at 15:44:18 Output rate: 0.0bps 0.0pps Input rate: 4063.5kbps 10.3kpps Flow control send :off Flow control receive:off TPID:8100 : > show interfaces gigabitethernet 0/5 Date 20XX/12/24 17:19:34 UTC NIF0: Port5: active up 100BASE-TX full(auto) 0012.e220.ec31 Time-since-last-status-change:1:47:47 Bandwidth:10000kbps Average out:5Mbps Average in:5Mbps Peak out:5Mbps at 15:44:36 Peak in:5Mbps at 15:44:18 Output rate: 4893.5kbps 16.8kpps Input rate: 4893.5kbps 16.8kpps Flow control send :off Flow control receive:off TPID:8100 :
- 目安となるサンプリング間隔
- = sFlow統計機能を有効にしているポートのPPS合計値/100
- = (10.3kpps+16.8kpps)/100
- = 271※
注※ サンプリング間隔を271で設定すると実際は512で動作します。サンプリング間隔の詳細はコンフィグレーションコマンドsflow sampleを参照してください。
(2) 詳細情報から調整する
show sflow detailコマンドを実行して表示されるSampling rate to collector(廃棄が発生しない推奨するサンプリング間隔)の値をサンプリング間隔として設定します。設定後はclear sflow statisticsコマンドを実行し,しばらく様子を見てまだSampling rate to collectorの値が設定より大きい場合は同じ手順でサンプリング間隔を設定してください。
図21-13 show sflow detailコマンドの実行結果
> show sflow detail Date 20XX/12/21 20:04:01 UTC sFlow service status: enable Progress time from sFlow statistics cleared: 8:00:05 : Collector IP address: 192.168.4.203 UDP:65535 Source IP address: 130.130.130.1 Send FlowSample UDP packets : 12077 Send failed packets: 0 Send CounterSample UDP packets: 621 Send failed packets: 0 Detail data : Max packet size: 1400 bytes Packet information type: header Max header size: 128 bytes Extended information type: switch,router,gateway,user,url Url port number: 80,8080 Sampling mode: random-number Sampling rate to collector: 1 per 2163 packets Target ports for CounterSample: 0/2-4
All Rights Reserved, Copyright(C), 2011, 2018, ALAXALA Networks, Corp.