はじめに
このドキュメントでは、Cisco IOS® XR 7ソフトウェアバージョンのアップグレードと、リポジトリを使用したインストール操作について説明します。
前提条件
要件
次の項目に関する知識があることが推奨されます。
- Cisco IOS XR ソフトウェア
- Cisco IOS XR ソフトウェアのインストールおよびアップグレード手順
使用するコンポーネント
このドキュメントは、特定のハードウェアバージョンに限定されるものではありません。IOS XR7を実行するすべてのルータに適用されます。
このドキュメントの情報は、特定のラボ環境にあるデバイスに基づいて作成されました。このドキュメントで使用するすべてのデバイスは、クリアな(デフォルト)設定で作業を開始しています。本稼働中のネットワークでは、各コマンドによって起こる可能性がある影響を十分確認してください。
関連製品
IOS XR7はLindtとも呼ばれ、Linux 9ディストリビューション上に構築されたXRソフトウェアを発展させたものです。
主な変更の1つは、管理プレーンの完全な削除です。また、IOS XRコントロールプレーンプロセスは、ホスト上でネイティブに実行されるようになりました。
このドキュメントは現在、次のハードウェアデバイスに適用できます。
- Cisco 540 ルータ
- 8000 シリーズ ルータ
- Cisco NCS 57B1シリーズルータ
注:ソフトウェアリリースには数字の7を含めることができますが、eXRソフトウェアアーキテクチャを表します(たとえば、ASR 9000 XR 7.5.2リリースはXR7アーキテクチャではありません)。
IOS XR7インストール機能拡張。
XR7でパッケージ(RPM)、コードアップグレード、およびアップデートをインストールするには、ルータがRPMをダウンロードしてインストールするためのRPMのリポジトリが必要です。リポジトリは、ルータに対してローカルにすることも、FTP、HTTP、またはHTTPSを介してリモートにアクセスすることもできます。
XR7のインストールアクティビティのさまざまなシナリオやニーズに対応するコマンドセットがあります。
置換のインストール |
新しいリリースへのアップグレード |
インストールソース |
リリースとオプションパッケージ間のバグ修正RPMのインストール |
install commit |
変更をコミットしてリロード後も保持する |
show install active |
アクティブなパッケージの表示 |
コミットされたインストールの表示 |
コミットされたパッケージの表示 |
インストール要求の表示 |
インストール操作の状態の表示 |
show version |
現在のインストールバージョンの状態の表示 |
現在アクティブなソフトウェアは、指定したISOイメージまたはゴールデンISO(GISO)イメージのソフトウェアでシステム上のソフトウェアを置き換えることができます。新しいソフトウェアにアップグレードするために必要な変更は最小限だけです。同じ名前とバージョンのパッケージは削除されず、再インストールされません。
- ファイルにアクセスするためのリポジトリを作成します。
RP/0/RP0/CPU0:R0(config)# install repository local-repo | remote-repo
RP/0/RP0/CPU0:R0(config)# install package replace
RP/0/RP0/CPU0:R0# install apply {reload | restart} [noprompt]
RP/0/RP0/CPU0:R0# install commit
設定
このセクションでは、ルータでリポジトリを設定する方法について説明します。HTTP/FTPサーバはすでに作成されており、機能していることが推奨されます。
リモートリポジトリ
リポジトリにリモートアクセスする場合は、インストールファイルの取得元のリポジトリURLを指定する必要があります。URLには次のものが含まれます。
デフォルト以外のVRFテーブルを使用してリポジトリに到達できるように設定できます。VRF内のアドレスを使用してリポジトリに到達できる場合は、VRFの名前を指定します。
リポジトリURLの形式は、次のいずれかです。
- FTP:ftp://<server>[;<vrf>]/<path-to-repository>
- HTTP:http://<server>[;<vrf>]/<path-to-repository>
- HTTPS:https://<server>[;<vrf>]/<path-to-repository>
- ローカル:file:///<path-to-repository>リポジトリへのパスは/harddisk:/の場所に存在する必要があります。
ルータにリモートリポジトリを設定します。
RP/0/RP0/CPU0:R0# configure
RP/0/RP0/CPU0:R0(config)# install repository remote_repo url http://192.168.122.1/
RP/0/RP0/CPU0:R0(config)# commit
RP/0/RP0/CPU0:R0(config)# end
RP/0/RP0/CPU0:R0#
前述のとおり、は、インストールファイルがフェッチされる場所のリポジトリURLを提供する必要があります。
- リモートリポジトリまたは以前構成したリポジトリで利用可能な修正を検証します。
RP/0/RP0/CPU0:R0#sh install fixes available
Wed Jan 31 22:32:39.477 UTC
Trying to access repositories...
Available Fixes (count: 1):
Bug Id Packages Repository Cached
----------- ----------------------------------------------------------- ---------------------------------------- ------
CSCvz57398 xr-ospf-7.3.2v1.0.1-1 remote_repo
インストール操作
RP/0/RP0/CPU0:R0#install package upgrade xr-ospf-7.3.2v1.0.1-1 synchronous
Wed Jan 31 22:34:16.220 UTC
Starting:
install package upgrade xr-ospf-7.3.2v1.0.1-1
Packaging operation 1.1.1
Press Ctrl-C to return to the exec prompt. This will not cancel the install operation
Current activity: Initializing ...
Current activity: Veto check ..
Current activity: Package add or other package operation ..
Packaging operation 1.1.1: 'install package upgrade xr-ospf-7.3.2v1.0.1-1' completed without error
リモートリポジトリは、一部のファイルを要求しているルータのログを表示できます。この例では、HTTPサーバはHTTPの成功した要求をいくつか示しています。
成功リクエストのHTTPサーバログ
設定を効果的にする。
RP/0/RP0/CPU0:R0#sh install fixes active
Wed Jan 31 22:39:54.987 UTC
There are currently no fixes active.
RP/0/RP0/CPU0:R0#install apply
Wed Jan 31 22:40:16.628 UTC
Once the packaging dependencies have been determined, the install operation may have to reload the system.
If you want more control of the operation, then explicitly use 'install apply restart' or 'install apply reload' as reported by 'show install request'.
Continue? [yes/no]:[yes] yes
Install apply operation 1.1 has started
Install operation will continue in the background
show install request
コマンドを使用すると、インストールの進捗状況を監視できます。2回目にコマンドが実行された時点で、インストール要求はすでに完了しています。
RP/0/RP0/CPU0:R0#sh install request
Wed Jan 31 22:41:07.649 UTC
User request: install apply restart
Operation ID: 1.1
State: In progress since 2024-01-31 22:40:19 UTC
Current activity: Apply by restarting processes
Next activity: Await user input
Time started: 2024-01-31 22:40:19
No per-location information.
RP/0/RP0/CPU0:R0#sh install request
Wed Jan 31 22:43:51.577 UTC
User request: install apply restart
Operation ID: 1.1
State: Success since 2024-01-31 22:41:10 UTC <<<<
Current activity: Await user input
Time started: 2024-01-31 22:41:10
この時点で、修正はアクティブですが、永続的ではありません。
RP/0/RP0/CPU0:R0#sh install fixes active
Wed Jan 31 22:46:33.940 UTC
Active Fixes (count: 1):
Bug Id Packages
----------- -----------------------------------------------------------
CSCvz57398 xr-ospf-7.3.2v1.0.1-1
install commit
この時点で、インストールをコミットした後にエラーが0を受け取ると、インストールが終了します。
RP/0/RP0/CPU0:R0#install commit synchronous
Wed Jan 31 22:47:38.676 UTC
Starting:
install commit
Transaction 1
Press Ctrl-C to return to the exec prompt. This will not cancel the install operation
Current activity: Initializing
Current activity: Commit transaction .
Transaction 1: 'install commit' completed without error
RP/0/RP0/CPU0:R0#
ローカルリポジトリ
ルータは、RPMをホストするリポジトリとして機能できます。ルータのシェルにアクセスできるroot-lrユーザである必要があります。RPMにアクセスするには、リモートリポジトリを使用することを推奨します。ただし、リモートリポジトリが望ましいオプションでない場合は、ルータをリポジトリとして使用してRPMをホストできます。
ローカルリポジトリの方法はリモートリポジトリとほぼ同じですが、最初は若干の違いがあります。
前提条件
パッケージをリポジトリに追加するには、パッケージがハードディスクに保存されている必要があります。
たとえば、次のTARファイルは次のようになります。
RP/0/RP0/CPU0:R0#dir harddisk:
Wed Jan 31 23:07:15.476 UTC
Directory of harddisk:
12 -rw-rw-rw-. 1 8388681 Jan 31 22:55 nvgen_bkup.log
2097153 drwxrwxrwx. 2 4096 Jan 31 22:19 .sppdc
524289 drwxrwxrwx. 3 4096 Oct 18 2021 mirror
2228225 drwxrwxrwx. 2 4096 Oct 18 2021 .sppdc_new
3932161 drwxrwxrwx. 3 4096 Oct 18 2021 ztp
3276801 drwxr-xr-x. 3 4096 Jun 16 2022 pam
13 -rw-rw-rw-. 1 600 Jan 31 22:18 debug_shell_client.log
3407873 drwxrwxrwx. 2 4096 Oct 18 2021 shutdown
1835009 drwxrwxrwx. 2 4096 Oct 18 2021 nvram
14 -rw-r--r--. 1 911360 Jan 31 23:06 8000-optional-rpms.7.3.2.tar <<<<<<<
262145 drwxr-xr-x. 2 4096 Jun 16 2022 showtech
11 drwx------. 2 16384 Oct 18 2021 lost+found
655361 drwx------. 3 4096 Jan 31 22:20 ima
15 -rw-rw-rw-. 1 2 Jan 31 22:25 feature_list
786433 drwxrwxrwx. 2 4096 Jun 16 2022 dumper
1048577 drwxrwxrwx. 5 4096 Jan 31 22:24 cisco_support
3145729 drwxrwxrwx. 2 4096 Jan 31 22:18 npu_sdk_logs
65908476 kbytes total (62474792 kbytes free)
RP/0/RP0/CPU0:R0#
ルータのシェルでファイルをuntarすることをお勧めします。
RP/0/RP0/CPU0:R0#run
Wed Jan 31 23:08:20.380 UTC
[node0_RP0_CPU0:/]$cd harddisk\:
[node0_RP0_CPU0:/harddisk:]$tar -xvf 8000-optional-rpms.7.3.2.tar
ローカルリポジトリの設定
RP/0/RP0/CPU0:R0# configure
RP/0/RP0/CPU0:R0(config)# install repository local-repo url file:///harddisk:/optional-rpms
RP/0/RP0/CPU0:R0(config)# commit
RP/0/RP0/CPU0:R0(config)# end
RP/0/RP0/CPU0:R0#
ローカルリポジトリに追加されたパッケージを検証します
RP/0/RP0/CPU0:R0#sh install available
Wed Jan 31 23:14:52.788 UTC
Trying to access repositories...
Package Architecture Version Repository Cached
---------------------------------------------------- ---------------- --------------------------- ----------------------------------- ------
xr-cdp x86_64 7.3.2v1.0.0-1 local-repo
xr-healthcheck x86_64 7.3.2v1.0.0-1 local-repo
xr-telnet x86_64 7.3.2v1.0.0-1 local-repo
RP/0/RP0/CPU0:R0#
インストール操作
リモートリポジトリオプションと同じプロセスをインストールして確認するには、これらのパッケージのいずれかをインストールしてみてください。たとえば、telnet 1をインストールします。
RP/0/RP0/CPU0:R0#install source local-repo xr-telnet
Wed Jan 31 23:20:28.252 UTC
Once the packaging dependencies have been determined, the install operation may have to reload the system.
If you want to control the timing of system reload, you must not continue, but use the 'install package add' command instead, followed by 'install apply'.
Continue? [yes/no]:[yes] yes
Install source operation 3.1 has started
Install operation will continue in the background
RP/0/RP0/CPU0:R0#sh install request
Wed Jan 31 23:24:45.907 UTC
User request: install source local-repo xr-telnet
Operation ID: 3.1
State: Success since 2024-01-31 23:22:58 UTC
構成を有効にしてコミットをインストール
リモート方式と同じように、install apply
を実行して設定を有効にし、install commit
を永続的にインストールする必要があります。次のコマンドを使用して、パッケージの正しいインストールを確認します
RP/0/RP0/CPU0:R0#sh install committed summary
Wed Jan 31 23:28:15.923 UTC
Committed Packages: XR: 181 All: 1283
Label: 7.3.2
Software Hash: bfe1bf8477ebb422e0eaf5c23358fcb1
Optional Packages Version
---------------------------------------------------- ---------------------------
xr-8000-mcast 7.3.2v1.0.0-1
xr-8000-netflow 7.3.2v1.0.0-1
xr-bgp 7.3.2v1.0.0-1
xr-ipsla 7.3.2v1.0.0-1
xr-is-is 7.3.2v1.0.0-1
xr-lldp 7.3.2v1.0.0-1
xr-mcast 7.3.2v1.0.0-1
xr-mpls-oam 7.3.2v1.0.0-1
xr-netflow 7.3.2v1.0.0-1
xr-ospf 7.3.2v1.0.0-1
xr-perfmgmt 7.3.2v1.0.0-1
xr-telnet 7.3.2v1.0.0-1 <<<<<<
xr-track 7.3.2v1.0.0-1
RP/0/RP0/CPU0:R0#