[[CISCO入門]]

#setlinebreak(on)
[[Moroha's Wiki]]に戻る &br;

バージョン: &Version; &br;
オンラインユーザー数: &online;
閲覧数表示 本日/トータル: &counter(today); / &counter(total); &br;
最終更新:&lastmod();&br;

**QoS実装モデル [#l41f4d14]
-IntServ (イントサーブ:Integrated Services)
必要な大域を予約してから転送を開始し、終了するとリリースを開放するモデル。
RSVP(ReSource reserVation Protocol)を使用し、非常に高いサービスレベルを提供する。
備考:あまり使われない


-DiffServ(ディフサーブ:Differentiated Services)
アプリケーション毎のパケットを分類し、中継する機器毎にあらかじめ定義された条件に従い、
混雑するリンクでパケット毎に優先度の差をつけて転送するモデル。

-BestEffort
パケットが到着した順番に転送し、特別な優先制御は行われない。
全てのアプリケーションパケットを平等に転送します。

**DiffServモデルの実装 [#s395e7dd]
-分類(Classification):アプリケーショントラフィックを異なるクラスに分類する
-マーキング:トラフィックの振る舞いやポリシーに基づいて分類されたパケットに優先順位の値を設定する
-キューイング:パケットにマークされた値を基に複数のキュー(待ち行列)にパケットを振り分ける
-スケジューリング:キューに割当てた優先度や帯域幅に基づいて、パケットを転送する

**マーキングフィールド [#s4b7cbc6]
-L2:IEEE802.1Q CoS:プライオリティ3ビット
-L3:IPプレシーデンス:ToSフィールド内6ビット
     DSCP(Differentiated Service Code Point)

-IPプレシーデンス及びCoS:0-7(3ビット)
-DSCP:0-63(6ビット)

**DSCP、IPプレシーデンス、CoSでの優先順位 [#oc857a85]

,アプリケーション,IPプレシーデンス,PHB,DSCP,CoS
,IPルーティング,6,CS6,48,6
,音声Real-Time Transport Protocol(RTP),5,EF,46,5
,ビデオ会議,4,AF41,34,4
,コールコントロール,3,CS3 AF31,24 26,3
,トランザクションデータ,2,AF21,18,2
,ネットワーク管理,2,CS2,16,2
,Scavenger,1,CS1,8,1
,ベストエフォート型,0,0,0,0

**PHB(Per Hop Bechavior) [#o0dde0fc]
DSCP6ビットを用いたホップ(機器)毎のパケット転送方式を表現しています。

-Default:優先制御無し(000000)
-AF(Assured Forwarding):優先度に応じた転送
-EF(Expedited Forwarding):緊急転送の為に絶対的に優先して転送''(101110)''
-CS(Class Selector):IPプレシーデンスと互換性の為、後半3ビットに000を入れて優先制御(CS1=001000)

***CSとDSCPの置き換え方法 [#w8de967c]
,CS表記,bit表記,DSCP10進表記
,CS6,110 000,48
,CS5,101 000,40
,CS4,100 000,32
,CS3,011 000,24
,CS2,010 000,16
,CS1,001 000,08

***AFとDSCPの置き換え [#p76e50ce]
AFxyのxは優先度(先頭3ビット)、yは廃棄確率(4,5ビット)を示します。
DSCPの6ビット目は用途が決まっておらず、必ず0が入ります。
,AF表記,bit表記,DSCP10進表記
,AF11,001 01 0,10
,AF12,001 10 0,12
,AF13,001 11 0,14
,AF21,010 01 0,18
,AF22,010 10 0,20
,AF23,010 11 0,22
,AF31,011 01 0,26
,AF32,011 10 0,28
,AF33,011 11 0,30
,AF41,100 01 0,34
,AF42,100 10 0,36
,AF43,100 11 0,38


***もう一度AFとCSとDSCP比較 [#x5cfaa16]
,IPプレシーデンス,bit表記,DSCP10進表記,,IPプレシーデンス,bit表記,DSCP10進表記
,CS1,001 000,08,   ,AF32,011 10 0,28
,AF11,001 01 0,10,   ,AF33,011 11 0,30
,AF12,001 10 0,12,   ,CS4,100 000,32
,AF13,001 11 0,14,   ,AF41,100 01 0,34
,CS2,010 000,16,   ,AF42,100 10 0,36
,AF21,010 01 0,18,   ,AF43,100 11 0,38
,AF22,010 10 0,20,   ,CS5,101 000,40
,AF23,010 11 0,22,   ,EF,101110,46
,CS3,011 000,24,   ,CS6,110 000,48
,AF31,011 01 0,26,   ,,,





**キューイング&スケジューリングの種類 [#y9ff0087]

-FIFO(First In First Out)
キューは1つ、キューに最初に入ったパケットが最初に送出される

-PQ(Priority Queueing)
優先度が『High』『Medium』『Normal』『Low』の4つのキューに振り分け、Highから順番に送出される

-CQ(Costom Queueing)
複数のキューを作成し、キューごとに帯域幅とパケットを割当、大まかな帯域幅の割合された制御度にしたがって送出される

-WFQ(Weighted Fair Queue)
アプリケーショントラフィックが自動的にフロー毎にキューに分離され、各フローに設定された優先度に基づいた帯域幅を利用するように送出される

-CBWFQ(Class-Based Weighted Fair Queue)
CQを改善し、より正確な帯域幅の割合に従って送出される

-LLQ(Low Latency Queue)
CBWFQにPQを組み合わせ、絶対優先されるキューとそれ以外の帯域の割合で処理されるキューでキューイングされる

-WRR(Weighted Round Robin)
4つのキューの重みに従って送出される(1つのキューを絶対優先キューに設定可能)

-SRR(Shaped Round Robin)
4つのキューの重みに従って送出され(1つのキューを絶対優先急キューに設定可能)スケージュリングの際にシェーピングを組み合わせられる。

**QoS設定例 [#l1157860]


シスコルータのイーサネットIFのDefaultはFIFOでシリアルIFのDefaultはWFQで動作します。
データのみの環境でCBWFQ、音声やビデオ統合環境ではLLQの使用が推奨されています。
Catalyst2950/3550ではWRR
Catalyst3750/3560/2960ではSRRの設定が可能。

**QoS有効化(Cisco ip-phone用) [#i4028c3c]

,Switch(config)#mls qos,QoSの有効化
,Switch(config)#interface fastEthernet 2/0/1,着信ポートへ
,Switch(config-if)#mls qos trust cos,着信ポートでCoS値を信頼
,Switch(config-if)#cdp enable,CDPを有効にする
,Switch(config-if)#mls qos trust device cisco-phone,CDPでIP-Phoneを検出した場合に着信パケットのCoS値を信頼

***DSCP値を信頼 [#d0a5feaa]
,Switch(config-if)#mls qos trust dscp,着信ポートでDSCPを信頼

**MQC(Modular QoS CLI)設定サンプル [#m5fcd85f]

①トラフィッククラスの定義(分類)
,Switch(config)#class-map TEST-CLASS,クラスマップ作成、TEST-CLASSがクラスマップ名
,Switch(config-cmap)#match access-group 1,アクセスリスト1に一致が条件
,Switch(config-cmap)#exit,

②QoSポリシーの定義(マーキング)
,Switch(config)#policy-map TEST-PM,ポリシーマップ作成、TEST-PMがポリシーマップ名
,Switch(config-pmap)#class TEST-CLASS,条件のクラスマップ指定
,Switch(config-pmap-c)#set ip dscp 46,クラスマップに一致したパケットをDSCP46へマーキング
,Switch(config-pmap-c)#exit,
,Switch(config-pmap)#exit,

③IFへの適用
,Switch(config)#access-list 1 permit 10.10.10.0 0.0.0.255,クラスマップ適応用のACL
,Switch(config)#interface fastEthernet 2/0/1,適応するIF
,Switch(config-if)#service-policy input TEST-PM,適応するポリシーマップ指定


***Auto QoS [#tf521694]
AutoQoSはシスコルータ及びCatalystスイッチに1つのコマンドを適用するだけで、
統合的なQoS(分類、マーキング、キューイングなど)を実装出来る機能です。
AutoQoSの特徴は次のとおりです。

・IF単位で1つのコマンド適用により、一連のQoS設定の有効化
・Cisco IP Phone及びIP Communicatiorの接続環境をサポート
・スタティック及びダイナミックアクセスポート、AUX VLAN設定ポート、トランクポートをサポート
・CDPを有効にするとAutoQoS機能を適切に利用可能

   Switch(config-if)#auto qos voip trust
   Switch(config-if)#auto qos voip cisco-phone

-AutoQoSを実行するとQoS設定が追加される(Catalyst3750 Ver12.2例)
    !
    mls qos map cos-dscp 0 8 16 24 32 46 48 56
    mls qos srr-queue input bandwidth 90 10
    mls qos srr-queue input threshold 1 8 16
    mls qos srr-queue input threshold 2 34 66
    mls qos srr-queue input buffers 67 33
    mls qos srr-queue input cos-map queue 1 threshold 2 1
    mls qos srr-queue input cos-map queue 1 threshold 3 0
    mls qos srr-queue input cos-map queue 2 threshold 1 2
    mls qos srr-queue input cos-map queue 2 threshold 2 4 6 7
    mls qos srr-queue input cos-map queue 2 threshold 3 3 5
    mls qos srr-queue input dscp-map queue 1 threshold 2 9 10 11 12 13 14 15
    mls qos srr-queue input dscp-map queue 1 threshold 3 0 1 2 3 4 5 6 7
    mls qos srr-queue input dscp-map queue 1 threshold 3 32
    mls qos srr-queue input dscp-map queue 2 threshold 1 16 17 18 19 20 21 22 23
    mls qos srr-queue input dscp-map queue 2 threshold 2 33 34 35 36 37 38 39 48
    mls qos srr-queue input dscp-map queue 2 threshold 2 49 50 51 52 53 54 55 56
    mls qos srr-queue input dscp-map queue 2 threshold 2 57 58 59 60 61 62 63
    mls qos srr-queue input dscp-map queue 2 threshold 3 24 25 26 27 28 29 30 31
    mls qos srr-queue input dscp-map queue 2 threshold 3 40 41 42 43 44 45 46 47
    mls qos srr-queue output cos-map queue 1 threshold 3 5
    mls qos srr-queue output cos-map queue 2 threshold 3 3 6 7
    mls qos srr-queue output cos-map queue 3 threshold 3 2 4
    mls qos srr-queue output cos-map queue 4 threshold 2 1
    mls qos srr-queue output cos-map queue 4 threshold 3 0
    mls qos srr-queue output dscp-map queue 1 threshold 3 40 41 42 43 44 45 46 47
    mls qos srr-queue output dscp-map queue 2 threshold 3 24 25 26 27 28 29 30 31
    mls qos srr-queue output dscp-map queue 2 threshold 3 48 49 50 51 52 53 54 55
    mls qos srr-queue output dscp-map queue 2 threshold 3 56 57 58 59 60 61 62 63
    mls qos srr-queue output dscp-map queue 3 threshold 3 16 17 18 19 20 21 22 23
    mls qos srr-queue output dscp-map queue 3 threshold 3 32 33 34 35 36 37 38 39
    mls qos srr-queue output dscp-map queue 4 threshold 1 8
    mls qos srr-queue output dscp-map queue 4 threshold 2 9 10 11 12 13 14 15
    mls qos srr-queue output dscp-map queue 4 threshold 3 0 1 2 3 4 5 6 7
    mls qos queue-set output 1 threshold 1 138 138 92 138
    mls qos queue-set output 1 threshold 2 138 138 92 400
    mls qos queue-set output 1 threshold 3 36 77 100 318
    mls qos queue-set output 1 threshold 4 20 50 67 400
    mls qos queue-set output 2 threshold 1 149 149 100 149
    mls qos queue-set output 2 threshold 2 118 118 100 235
    mls qos queue-set output 2 threshold 3 41 68 100 272
    mls qos queue-set output 2 threshold 4 42 72 100 242
    mls qos queue-set output 1 buffers 10 10 26 54
    mls qos queue-set output 2 buffers 16 6 17 61
    mls qos
    !
    ~中略~
    interface FastEthernet2/0/1
      srr-queue bandwidth share 10 10 60 20
    ~以下略~

トップ   編集 差分 バックアップ 添付 複製 名前変更 リロード   新規 一覧 検索 最終更新   ヘルプ   最終更新のRSS