例:論理システムでの IS-IS デフォルト ルート ポリシーの設定
この例では、1 つの物理ルーター上で設定された論理システムを示し、1 つの論理システム上でデフォルト ルートを設定する方法を説明します。
必要条件
この例を設定する前に、デバイス初期化以外の特別な設定を行う必要はありません。
概要
この例は、論理システムがデフォルト ルートを他の論理システムに再配布する様子を示しています。すべての論理システムが IS-IS を実行します。デフォルト ルートの一般的な理由は、IS-IS ドメイン外を宛先とするトラフィックを送信するためのパスを提供することです。
この例では、トラフィックの転送にデフォルトルートは使用されていません。 no-install ステートメントは、論理システム LS3 の転送テーブルにルートがインストールされないようにします。転送テーブルにインストールされないようにルートを設定した場合でも、そのルートはルーティングテーブルから他のプロトコルにエクスポートできます。 discard ステートメントは、通知なしにパケットを暗黙のうちにドロップします。
構成
CLIクイック構成
この例を迅速に設定するには、以下のコマンドをコピーしてテキスト ファイルに貼り付け、改行を削除し、ネットワーク設定に一致させる必要がある詳細情報を変更し、コマンドを [edit] 階層レベルで CLI にコピー アンド ペーストして、設定モードからコミットを入力します。
set logical-systems LS3 interfaces lt-1/2/0 unit 3 description LS3->LS2 set logical-systems LS3 interfaces lt-1/2/0 unit 3 encapsulation ethernet set logical-systems LS3 interfaces lt-1/2/0 unit 3 peer-unit 4 set logical-systems LS3 interfaces lt-1/2/0 unit 3 family inet address 10.0.2.1/30 set logical-systems LS3 interfaces lt-1/2/0 unit 3 family iso set logical-systems LS3 interfaces lt-1/2/0 unit 5 description LS3->LS1 set logical-systems LS3 interfaces lt-1/2/0 unit 5 encapsulation ethernet set logical-systems LS3 interfaces lt-1/2/0 unit 5 peer-unit 0 set logical-systems LS3 interfaces lt-1/2/0 unit 5 family inet address 10.0.1.1/30 set logical-systems LS3 interfaces lt-1/2/0 unit 5 family iso set logical-systems LS3 interfaces lo0 unit 3 family iso address 49.0001.1234.1600.2231.00 set logical-systems LS3 protocols isis export isis-default set logical-systems LS3 protocols isis interface lt-1/2/0.3 set logical-systems LS3 protocols isis interface lt-1/2/0.5 set logical-systems LS3 protocols isis interface lo0.3 passive set logical-systems LS3 routing-options static route 0.0.0.0/0 discard set logical-systems LS3 routing-options static route 0.0.0.0/0 no-install set logical-systems LS3 policy-options policy-statement isis-default from protocol static set logical-systems LS3 policy-options policy-statement isis-default from route-filter 0.0.0.0/0 exact set logical-systems LS3 policy-options policy-statement isis-default then accept
プロシージャ
手順
次の例では、設定階層のいくつかのレベルに移動する必要があります。CLIのナビゲーションについては、CLIユーザー・ガイド の コンフィギュレーション・モードでのCLIエディタの使用を参照してください。
論理システムで IS-IS デフォルト ルート ポリシーを設定するには、次の手順に従います。
論理トンネル インターフェイスを設定します。
[edit logical-systems LS3 interfaces lt-1/2/0] user@R1# set unit 3 description LS3->LS2 user@R1# set unit 3 encapsulation ethernet user@R1# set unit 3 peer-unit 4 user@R1# set unit 3 family inet address 10.0.2.1/30 user@R1# set unit 3 family iso user@R1# set unit 5 description LS3->LS1 user@R1# set unit 5 encapsulation ethernet user@R1# set unit 5 peer-unit 0 user@R1# set unit 5 family inet address 10.0.1.1/30 user@R1# set unit 5 family iso [edit logical-systems LS3 interfaces lo0 unit 3] user@R1# set family iso address 49.0001.1234.1600.2231.00
インターフェイスで IS-IS を有効にします。
[edit logical-systems LS3 protocols isis] user@R1# set interface lt-1/2/0.3 user@R1# set interface lt-1/2/0.5 user@R1# set interface lo0.3 passive
論理システム LS3 でデフォルト ルートを設定します。
[edit logical-systems LS3 routing-options] user@R1# set static route 0.0.0.0/0 discard user@R1# set static route 0.0.0.0/0 no-install
論理システム LS3 でデフォルト ルート ポリシーを設定します。
[edit logical-systems LS3 policy-options] user@R1# set policy-statement isis-default from protocol static user@R1# set policy-statement isis-default from route-filter 0.0.0.0/0 exact user@R1# set policy-statement isis-default then accept
論理システム LS3 の IS-IS にエクスポート ポリシーを適用します。
[edit logical-systems LS3 protocols isis] user@R1# set export isis-default
デバイスの設定が完了したら、設定をコミットします。
[edit] user@R1# commit
業績
設定モードから、 show logical-systems LS3 コマンドを発行して設定を確認します。出力結果に意図した設定内容が表示されない場合は、この例の手順を繰り返して設定を修正します。
user@R1# show logical-systems LS3
interfaces {
lt-1/2/0 {
unit 3 {
description LS3->LS2;
encapsulation ethernet;
peer-unit 4;
family inet {
address 10.0.2.1/30;
}
family iso;
}
unit 5 {
description LS3->LS1;
encapsulation ethernet;
peer-unit 0;
family inet {
address 10.0.1.1/30;
}
family iso;
}
}
lo0 {
unit 3 {
family iso {
address 49.0001.1234.1600.2231.00;
}
}
}
}
protocols {
isis {
export isis-default;
interface lt-1/2/0.3;
interface lt-1/2/0.5;
interface lo0.3 {
passive;
}
}
}
policy-options {
policy-statement isis-default {
from {
protocol static;
route-filter 0.0.0.0/0 exact;
}
then accept;
}
}
routing-options {
static {
route 0.0.0.0/0 {
discard;
no-install;
}
}
}
}
検証
設定が正常に機能していることを確認します。
スタティック ルートが再配布されていることの確認
目的
ルーティングテーブルを確認して、IS-ISポリシーが機能していることを確認してください。
アクション
user@R1> show route logical-system LS3
inet.0: 6 destinations, 6 routes (6 active, 0 holddown, 0 hidden)
+ = Active Route, - = Last Active, * = Both
0.0.0.0/0 *[Static/5] 00:00:45
Discard
10.0.0.0/30 *[IS-IS/15] 1w0d 10:14:14, metric 20
to 10.0.2.2 via lt-1/2/0.3
> to 10.0.1.2 via lt-1/2/0.5
10.0.1.0/30 *[Direct/0] 1w0d 10:15:18
> via lt-1/2/0.5
10.0.1.1/32 *[Local/0] 1w0d 10:15:18
Local via lt-1/2/0.5
10.0.2.0/30 *[Direct/0] 1w0d 10:15:18
> via lt-1/2/0.3
10.0.2.1/32 *[Local/0] 1w0d 10:15:18
Local via lt-1/2/0.3
iso.0: 1 destinations, 1 routes (1 active, 0 holddown, 0 hidden)
+ = Active Route, - = Last Active, * = Both
49.0001.1234.1600.2231/72
*[Direct/0] 1w0d 10:17:19
> via lo0.3
user@R1> show route logical-system LS2
inet.0: 6 destinations, 6 routes (6 active, 0 holddown, 0 hidden)
+ = Active Route, - = Last Active, * = Both
0.0.0.0/0 *[IS-IS/160] 00:01:38, metric 10
> to 10.0.2.1 via lt-1/2/0.4
10.0.0.0/30 *[Direct/0] 1w0d 10:16:11
> via lt-1/2/0.1
10.0.0.2/32 *[Local/0] 1w0d 10:16:11
Local via lt-1/2/0.1
10.0.1.0/30 *[IS-IS/15] 1w0d 10:15:07, metric 20
> to 10.0.0.1 via lt-1/2/0.1
to 10.0.2.1 via lt-1/2/0.4
10.0.2.0/30 *[Direct/0] 1w0d 10:16:11
> via lt-1/2/0.4
10.0.2.2/32 *[Local/0] 1w0d 10:16:11
Local via lt-1/2/0.4
iso.0: 1 destinations, 1 routes (1 active, 0 holddown, 0 hidden)
+ = Active Route, - = Last Active, * = Both
49.0001.1720.1600.2002/72
*[Direct/0] 1w0d 10:18:12
> via lo0.2
user@R1> show route logical-system LS1
inet.0: 6 destinations, 6 routes (6 active, 0 holddown, 0 hidden)
+ = Active Route, - = Last Active, * = Both
0.0.0.0/0 *[IS-IS/160] 00:02:01, metric 10
> to 10.0.1.1 via lt-1/2/0.0
10.0.0.0/30 *[Direct/0] 1w0d 10:16:34
> via lt-1/2/0.2
10.0.0.1/32 *[Local/0] 1w0d 10:16:34
Local via lt-1/2/0.2
10.0.1.0/30 *[Direct/0] 1w0d 10:16:34
> via lt-1/2/0.0
10.0.1.2/32 *[Local/0] 1w0d 10:16:34
Local via lt-1/2/0.0
10.0.2.0/30 *[IS-IS/15] 1w0d 10:15:55, metric 20
to 10.0.1.1 via lt-1/2/0.0
> to 10.0.0.2 via lt-1/2/0.2
iso.0: 1 destinations, 1 routes (1 active, 0 holddown, 0 hidden)
+ = Active Route, - = Last Active, * = Both
49.0001.1720.1600.1001/72
*[Direct/0] 1w0d 10:18:35
> via lo0.1
意味
論理システム LS3 のルーティングテーブルには、プロトコル Static からのデフォルトの 0.0.0.0/0 ルートが含まれています。論理システム LS1 と論理システム LS2 のルーティング テーブルには、プロトコル IS-IS からのデフォルトの 0.0.0.0/0 ルートが含まれています。論理システム LS1 と論理システム LS2 が、ルーティング テーブルで指定されていないネットワーク宛てのパケットを受信した場合、それらのパケットは論理システム LS3 に送信され、さらに処理されます。この設定は、論理システム LS3 が ISP または別の外部ネットワークに接続されていることを前提としています。
