メモのページ - チラシの裏メモ 3枚目

通信技術や気になった事を黙々とメモし続ける

15年ぶりのExtreme XOSをVirtualBoxで動かす

再会したきっかけ
15年以上もの間 IPネットワークの設計や運用等の仕事をしてきた中で、ここ数年間は稀にExtreme Networks社の名や製品を耳にする事は有っても特に気に留める事も無く月日は経ち、今年になって、あの紫の箱達は今はどうなっているのだろうかとGoogleで検索したら、Extreme Networks社の日本法人のサイトがまだ存在している事に気が付く。そしてExtreme XOSが今も使われ続けている事を知り、更に、Extreme XOSの仮想アプライアンス版が公開されている事を知る。
ちょっと遊んでみようかと仮想アプライアンス版のダウンロードサイトを探したら、Extreme Networks社公式のgithubのサイトにて公開されている事が判明。
無償公開である事が分かると、早速試用してみる事とした。今はどうなっているか知りたいし、SONiCやCumulus LinuxとIP Clos構成組めるか確認したいし...


Extreme XOSと自分との関係
Extreme XOSとは、Extreme Networks社製スイッチにて稼働するNOS(Network Operation System)の事。
自分にとってExtreme Networks社製スイッチと言えば、SummitシリーズやAlpineシリーズ、BlackDiamondシリーズスイッチ等の紫色の筐体の機器を指す。2000年代前半(※1)、省庁や学校のインフラにて紫色の筐体が席巻していた事を覚えている同業の方々は居るであろう。
当時のExtreme Networks社の製品の主要なOSはVxWorksベースのExtremeWareだったが、2004年にLinux OSをベースとしたExtreme XOS(ExtremeWare XOS)が登場。「生命体のような回復力」(※2)のような謳い文句で市場に攻勢をかけた。Ciscoや他の機器ベンダにシェアを年々奪われ続け日本市場を一度撤退する事態に陥ったもの経営戦略の立て直しにより復活し、2010年代中頃に再参入を果たす。2015年のINTEROPにて、また宜しくお願い致しますと名刺やノベルティグッズを頂いた事を覚えている。
自分は2007年まで居た常駐先にてExtreme Networks社製機器を扱っており、旧OSのExtremeWareのCLIに触れまくっていた。お世話していた某システムにてExtreme XOS搭載機が導入されるという事で検証用機器にてExtreme XOSの予習目的で触れていたものの案件の開始前に離任し、その後10年以上に渡りExtreme Networks社の製品に触れる機会は無かった。


Extreme XOSは何が出来る?
リリースノートやユーザガイドを斜め読みした限りでは、CiscoやJuniperのL2スイッチやL3スイッチが出来るような事は一通り出来るように見える。
ESRP(Extreme Standby Router Protocol)というExtreme Networks社独自規格の冗長化プロトコルもまだまだ健在のようだ。
VXLANも出来るようだ。REST APIも叩けるようだ。少なくとも、ExtremeWare時代に出来た事は今も出来るだろう。
...という事で早速、VirtualBoxにデプロイしてみた。


今回やる事
Extreme XOSのCLIに触れるのは約15年ぶりという事で、コマンドはほぼ100%忘却の彼方である。
よって、今回はVirtualBoxへのデプロイとSSHログインの為の設定までとする。
他の機器との間でIP Clos構成を組んだりBGPを喋らせたり...は次回以降に実施する。


当方の環境
ホストOS:macOS 10.13.6 / MacBook Air 2011 / RAM: 4GB / CPU: Intel Core i7 1.8GHz
Oracle VirtualBox:6.1.24
ゲストOS:Extreme XOS 31.1.1.3


VirtualBoxの設定
ダウンロードした.isoファイルを使用する。
今回は最新版であるvm-31.1.1.3-patch1-1.x86_64.isoを使用。
検証環境であれば、仮想RAMは512MB確保すれば充分なようだ。今時の仮想ルータや仮想スイッチは4GBや8GB等多めの容量を必要とするものが増えてきている中で、稀有な存在である。

[General]
Operating System
Type:Linux
Version:Other Linux (64-bit)

[System]
Base Memory:512MB
Processors:1
Boot Order:Hard Disk
Acceleration:VT-x/AMD-V, Nested Paging, PAE/NX, KVM Paravirtualization

[Display]
Video Memory:16MB
Graphics Controller:VMSVGA
Remote Desktop Server:Disabled
Recording:Disabled

[Storage]
Controller:IDE
IDE Primary Master:
vm-31.1.1.3-patch1-1.x86_64.vdi
vm-31.1.1.3-patch1-1.x86_64.iso デプロイ完了後は外す

[Audio]
Disabled

[Network]
Adapter 1:Intel PRO/1000 MT Desktop (82540EM) (Bridged Adapter, Broadcom 4313 802.1b/g/n)
Adapter 2:Intel PRO/1000 MT Desktop (82540EM) (Internal Network, 'intnet01')
Adapter 3:Intel PRO/1000 MT Desktop (82540EM) (Internal Network, 'intnet02')
自分の環境では、ネットワークアダプタを4つ以上作成しても、Extreme XOSでは3つのポートしか作成されなかった。



デプロイ開始
VirtualBox Managerウインドウ内上側の緑色の三角印をクリックし、Extreme XOSのデプロイを開始。
起動時のログにてちらりと見えるが、Alpine Linuxと同じようにBusyBoxが導入されている事が分かる。

起動は以下で一旦止まる。
cキーを叩き、デプロイを進める。

Rescue mode will always download and install a new image.
Rescure options:
1) format disk before install (ERASE ALL DATA).... "true"
2) clear NVRAM after install...................... "false"

c) continue
r) reboot
~> ここでc キーを叩く


cキーを叩いた後、デプロイを進めるか聞いてくる。
Yキーを叩き先に進む。

OK to continue? (Y/N) Yキーを叩く

**** Starting Extreme Memory Card device
**** Installing operating system from cd-rom device /dev/hde
**** Copying rescure image to ramdisk
**** Partitioning Disk Device
**** Sufficiently large VM hard drive detected
**** Creating ext4 FS on /dev/hda1
**** Creating ext4 FS on /dev/hda2
**** Creating ext4 FS on /dev/hda5
**** Creating ext4 FS on /dev/hda6
**** Creating ext4 FS on /dev/hda7
**** Creating ext4 FS on /dev/hda8
**** Creating ext4 FS on /dev/hda9
**** Creating ext4 FS on /dev/hda10
**** Creating ext4 FS on /dev/hda11
**** Mounting Partitions
**** Checking Image Wrapper
**** Extract Upgrade Script
**** Execute Upgrade Script
Installing 31.1.1.3
Installing for i386-pc platform
Installation finished. No error reported.
**** Set default boot partition to primary 
**** Sideloading will not take place ***
***** press ENTER to reboot:


ここでEnterキーを叩くとExtreme XOSの再起動が始まる。
一旦Virtualマシンのウインドウを閉じて、CD/DVDメディアを読み込ませないようVirtualBox側の設定を修正。
VirtualBox Managerの画面に戻り、Setting -> System -> Boot Orderの欄にてOpticalのチェックを外す。
次に、Storage -> Storage Device欄にて.isoファイルを選択し、欄下側のバツアイコンをクリックし.isoファイルを外す。
OKをクリックし設定内容を保存。
再びExtreme XOSを起動させる。

動作は非常に軽快で、1分も経たないうちにログインプロンプトが出力される。
クソ重いNX-OSvよ、少しは見習え。

(pendong-AAA) login:のログインプロンプトは無視する。
以下のログが出力されたら、Enterキーを叩きログインプロンプトを出力させる。

Authentication Service (AAA) on the master node is now available for login.

login:


adminを入力し、パスワードは入力せずEnterキーを叩く。
これより対話形式の設定に入るが、全てNで返答し設定を終わらせるか、qキーを叩き対話形式の設定から抜ける。

Would you like to disable MSTP? [y/N/q]:
and have the choice to enable this enhanced security mode? [y/N/q]

Telnet is enabled by default. Telnet is unencrypted and has been the target of security exploits in the past.

Would you like to disable Telnet? [y/N/q]

SNMP access is disabled by default. SNMPv1/v2c uses no encryption, SNMPv3 can be 
configured to eliminate this problem.

Would you like to enable SNMPv1/v2c? [y/N/q]

Would you like to enable SNMPv3? [y/N/q]

All ports are enabled by default. In some secure applications, it may be more 
desirable for the ports to be turned off.

Would you like unconfigured ports to be turned off by default? [y/N/q]

No failsafe account username and password are in effect. If you choose to 
configure them, please remember them because they cannot be recovered.
Would you like to configure the failsafe username and password now? [y/N/q]


ここで対話形式の設定は終了となる。
adminユーザのパスワード設定を求めるログと一緒に、ロンプトが出力される。

   * change your admin password

* EXOS-VM.1 #


これで、Extreme XOSのコマンドを打てる状態となった。早速show versionを打ってみる。
Extreme XOSのバージョンやハードウェアのシリアル番号等の情報が出力されている。
仮想アプライアンスであるにも関わらず、PSUが認識されシリアル番号が出力されている。

* EXOS-VM.1 # show version
Switch          : PN:1N2039      SN:123456      Rev 01  BootROM: 1.2   IMG: 31.1.1.3
PSUCTRL-1       : PN:MEAD        SN:MD1         Rev 01  BootROM: 2.1
PSUCTRL-2       : PN:MEAD        SN:MD2         Rev 11  BootROM: 2.3
mouse-usb       : PN:MOUSE       SN:4321        Rev 11  BootROM: 4.3
floppy-A        :
PSU-1        : Internal PSU-2 PN:1N2039  SN:12345
PSU-2        : Internal PSU-3 PN:1N2039  SN:12345

Image      : ExtremeXOS version 31.1.1.3 31.1.1.3-patch1-1 by release-manager
Certified Version : EXOS Linux 4.14.170, Extreme Networks FIPS Object Module 2.0.16

Build Tools Version : exos-x86_64-sdk-3.0.3.1.0
* EXOS-VM.2 #


ここで、show switchコマンドを打ってみる。
ホスト名(SysName)や稼働時間(System UpTime)やExtreme XOSのバージョン等が出力されている。

* EXOS-VM.2 # show switch

SysName:          EXOS-VM
SysLocation:
SysContact:       https://www.extremenetworks.com/support/
System MAC:       08:00:27:7E:27:C9
System Type:      EXOS-VM

SysHealth check:  Enabled
Recovery Mode:    All
System Watchdog:  Enabled

Current Time:     Sat Sep 18 08:25:22 2021
Timezone:         [Auto DST Disabled] GMT Offset: 0 minutes, name is UTC.
Boot Time:        Sat Sep 18 08:07:18 2021
Boot Count:       0
Next Reboot:      None scheduled
System UpTime:    18 minutes 3 seconds

Current State:    OPERATIONAL
Image Selected:   primary
Image Booted:     primary
Primary ver:      31.1.1.3
                  patch1-1
Secondary ver:    31.1.1.3
                  patch1-1

Config Selected:  primary.cfg
Config Booted:    Factory Default
Config Automatic: NONE (Disabled)

primary.cfg       Created by ExtremeXOS version 31.1.1.3
                  142432 bytes saved on Sat Sep 18 08:11:14 2021


LAA MAC:          Locally Administered MAC Address Disabled
* EXOS-VM.3 #


show portsコマンドを打ち、ポートの状態やVirtualBoxで設定したネットワークアダプタの設定がどのように認識されているのか確認する。
VirtualBoxでは4つの仮想ネットワークアダプタを作成したにも関わらず、3つしか認識していない事が分かる。
スイッチなのにたった3つかよ...

* EXOS-VM.3 # show ports
Port Summary Monitor                      Sat Sep 18 08:27:40 2021
Port     Display              VLAN Name           Port  Link  Speed  Duplex
#        String               (or # VLANs)        State State Actual Actual
===========================================================================
1                             Default             E     A      100    FULL
2                             Default             E     A      100    FULL
3                             Default             E     A      100    FULL
:
:
========================================================================
   Port State: D-Disabled, E-Enabled, F-Disabled by link-flap detection,
               L-Disabled due to licensing
   Link State: A-Active, R-Ready, NP-Port Not Present, L-Loopback,
               D-ELSM enabled but not up,
               d-Ethernet OAM enabled but not up,
               B-MACsec enabled but blocked awaiting authentication
   U->page up  D->page down ESC->exit

この状態で何かコマンドを叩いても何も出力されない。
show portsコマンドから抜ける為に、Escキーを叩く必要がある。


ホスト名の変更
Extreme XOSではhostnameではなくSystem Nameと呼ばれる。
ホスト名を設定すると即座にプロンプトに反映される。

* EXOS-VM.4 # configure snmp sysName jpmtkvmsw99
* jpmtkvmsw99.1 #


adminユーザのパスワードを設定
SSHログインもしくはTelnetログインをするのであれば、ログインするアカウントにパスワードを設定する必要が有る。

* jpmtkvmsw99.1 # confugure account admin password (Enterキーを叩く)
Current user's password;  (デフォルトでパスワード無しにつきEnterキー叩く)
New password; xxxxxxxx (パスワードを入力)
Reenter password: xxxxxxxx (パスワードを入力)
* jpmtkvmsw99.2 #


IPアドレスの設定
show vlanコマンドを実行すると、DHCPにより既にIPアドレスがアサインされている事が分かる。
VLAN ID(VID)は1、VLAN NameはMgmtで、自分の環境では192.168.3.0/24のネットワークからアサインされている。
よって、改めてSSHアクセス用のVLANおよびIPアドレスを設定する必要は無い。

* jpmtkvmsw99.2 # show vlan
Untagged ports auto-move: Inform
-----------------------------------------------------------------------------------------------
Name            VID  Protocol Addr       Flags                         Proto  Ports  Virtual
                                                                              Active router
                                                                              /Total
-----------------------------------------------------------------------------------------------
Default         1    --------------------------------T-------------    ANY    2 /2   VR-Default
Mgmt            4095 192.168.3.12   /24  --------------------------    ANY    1 /1   VR-Mgmt
-----------------------------------------------------------------------------------------------
:
Total number of VLAN(s) : 2
* jpmtkvmsw99.3 #


SSHアクセスを有効にする
enable ssh2コマンドを実行するだけ。
telnetの場合は、enable telnetコマンドを実行する。

* jpmtkvmsw99.3 # enable ssh2
WARNING: Generating new server host key
This could take up to 1 minute and cannot be cancelled. Continue? (y/N) yキーを叩く

Key Generated.
* jpmtkvmsw99.4 #


設定内容の保存
saveコマンドを打ち、これまでに設定した内容を保存する。

* jpmtkvmsw99.4 # save
No default configuration database has been selected to boot up the system.
Save configuration will set the new configuration as the default database.

Do you want to save configuration to primary.cfg? (y/N) yキーを叩く
Saving configuration primary.cfg  on master .. done!
Configuration saved to primary.cfg successfully.
* jpmtkvmsw99.5 #


さあ、これでSSHログインが可能になった。
VirtualBoxのウインドウは狭い上に、ウインドウから見えなくなった出力内容を確認する事が出来ない。
よって、ここから先はTera TermやPuTTY等のターミナルツールでSSHアクセスし設定を進める方が良い。


今回はここまで。
デプロイ自体はすぐに終ったものの、sshログインが出来るようになるまで思って居た以上に時間を要した。
管理用VLANであるMgmtにIPアドレスが自動でアサインされる事に気が付かず、外向き用のインタフェース(VirtualBoxのネットワークアダプタ1)にMgmtと同じネットワークからIPアドレスをアサインし設定し、そこに対しsshを叩いていた事が原因だった。
RAMが8GBあるHPのノートPCであれば、仮想RAMが512MBで済むExtreme XOSが4台、Cumulus Linuxが2台という構成が組めそうだ。Extreme XOSが8台という構成も出来そう。
次回は仮想アプライアンスの台数を増やし、IP Clos構成を組んでみようと思う。


亀「何だ、今日は俺の出番は無いのか...」



参照サイト
https://www.extremenetworks.com/ Extreme Networks
https://jp.extremenetworks.com/ Extreme Networks (日本語ページ)
https://jp.extremenetworks.com/products/ 製品紹介ページ
https://www.extremenetworks.com/support/documentation/extremexos-31-1/ EXOS 31.1のドキュメント
https://github.com/extremenetworks/Virtual_EXOS EXOSのダウンロードサイト
http://paultclark.com/network/extreme/EXOS_Quick_Guide.pdf Extreme XOS Quick Guide


※1:その頃の自分は30歳になったばかりだったと思う。
※2:何らかの不具合が発生したプロセスを自動で再起動させる...といった感じのものではないか。