Licensing and Upgrade Commands
This chapter describes the license and upgrade commands.
license get
Use this command to fetch the license for this device from a network path or a USB mount path. This command validates the license against the device identifier.
Note: The system date must be correct to avoid installation failure.
For HTTP, FTP, or TFTP, ensure that the IP address is reachable from the OcNOS device and that the file location is correct.
If you install a license from a USB stick, insert it, and the contents of the USB are available as ///mnt/usb/. For example:
>license get file:///mnt/usb/IPI-CC37ABBE0340.bin
After running the license get command, you can immediately use the switch without rebooting.
To verify, run the
show license command after giving this command.
Command Syntax
license get (|(source-interface IFNAME)) WORD
Parameters
IFNAME
The interface used to download the license. If not specified, eth0 is used.
If the management interface of the switch is in the “management” VRF, then this command uses the “management” VRF to get the license from the specified path. You do need not to know if the management port is in the default VRF or the “management” VRF.
WORD
Where to get the license:
ftp://your-server-ip/path/to/file/IPI_deviceId.bin
http://your-server-ip/path/to/file/IPI_deviceId.bin
tftp://your-server-ip/path/to/file/IPI_deviceId.bin
file:///mnt-point/usb/path/to/file/IPI_deviceId.bin
Default
None
Command Mode
Exec mode
Applicability
This command was introduced before OcNOS version 1.3.
Examples
>license get http://myServer/IPI-CC37ABBE0340.bin
Specify the source-interface parameter to set the interface to use:
>license get source-interface xe2 http://myServer/IPI-CC37ABBE0340.bin
license refresh
Use this command to install a license present on the device. This command is required only when the
license get command reports error when installing the license but successfully downloaded the license.
When this command is given without a file name, the device installs the most recently downloaded license file.
Note: Always ensure that the device date is up to date to avoid license installation failures.
Once this command is successful, you can use the device without rebooting. Verify license installation with the
show license command.
Command Syntax
license refresh (FILENAME|)
Parameters
FILENAME
License file name which exists on the device.
Default
None
Command Mode
Exec mode
Applicability
This command was introduced in OcNOS version 1.3.7.
Examples
>license refresh
>license refresh IPI-CH3QX42.bin
license release
Use this command to release any type of license, node-locked or floating, on the device.
The device license is revoked immediately.
Command Syntax
license release
Parameters
None
Default
None
Command Mode
Exec mode
Applicability
This command was introduced in OcNOS version 3.0.
Examples
>license release
show installers
Use this command to display a list of downloaded images on the device.
Command Syntax
show installers
Parameters
None
Default
None
Command Mode
Exec mode
Applicability
This command was introduced in OcNOS version 1.3.6.
Examples
#show installers
/installers/DELL_S6000_ON-OcNOS-1.3.6.228a-DC_MPLS-S0-P0-installer
#
show license
Use this command to display the current license details and errors. The licenses are device locked, which means that a separate license is required for each device.
Command Syntax
show license
Parameters
None
Default
None
Command Mode
Exec mode
Applicability
This command was introduced before OcNOS version 1.3.
Examples
>show license
License Type: Trial edition
Remaining day to expires : 21 day(s)
Node Identifier: 1402EC2DA140
Device Software : OCNOS-ENT-IPBASE
>show license
License Type: Evaluation, Limited edition
License Validity: Not Applicable
Node Identifier: A82BB59DCAD9
Device Software : OCNOS-DC-IPBASE
License Error: Invalid license file
show sys-update details
Use this command to display upgrade details. The output indicates whether the current version is committed or rolled back.
Command Syntax
show sys-update details
Parameters
None
Default
None
Command Mode
Exec mode and Privileged Exec mode
Applicability
This command was introduced before OcNOS version 1.3.
Examples
#show sys-update details
Previous_version EC_AS5812_54X-OcNOS-1.3.4.265-DC_MPLS_ZEBM-S0-P0
Current_version EC_AS5812_54X-OcNOS-1.3.4.266-DC_MPLS_ZEBM-S0-P0-installer
(committed)
Last_upgraded Wed Sep 26 14:40:06 UTC 2018
Auto Rollback end time NA
sys-update delete
Use this command to delete a downloaded image.
Command Syntax
sys-update delete IMAGE_NAME
Parameters
IMAGE_NAME
Installer to delete
Default
None
Command mode
Privileged Exec mode
Applicability
This command was introduced in OcNOS version 1.3.6.
Examples
#sys-update delete DELL_S6000_ON-OcNOS-1.3.6.228a-DC_MPLS-S0-P0-installer
sys-update get
Use this command to download an installer image.
Note: The URL must be compliant with RFC 3986.
Note: At times while downloading installer through TFTP protocol, download progress would show 100% from the start to the end of the download. This behavior is observed whenever the TFTP server doesn't support the TFTP Option Negotiation. Also at times TFTP download takes more time to download the installer though the client and server are part of the same subnet, eventually download operation even times out after 30 minutes. The reason for such issue is the latency, here some of the TFTP server implementations are lagging performance. In such instances we recommend to switch to a different TFTP server. This TFTP download operation is verified in Debian Linux machine against the server present in the tftpd-hpa package.
Note: For SCP and SFTP, make sure the IP address/hostname present in the known_hosts file else SCP and SFTP will fail with the error message “curl: (60) SSL peer certificate or SSH remote key was not OK”. If sys-update fails, the user is prompted to add the hostname/IP address in the known_hosts file to proceed with sys-update.
Command Syntax
sys-update get ((source-interface IFNAME) | (source-ip (A.B.C.D | X:X::X:X))|) URL (verbose|)
Parameters
IFNAME
The interface used to download the new version. If not specified, eth0 is used.
URL
Where to get the installer:
http://username:password@your-server-ip/path/to/file/<abc-installer>> or
ftp://username:password@your-server-ip/path/to/file/<abc-installer>> or
tftp://your-server-ip/path/to/file/<abc-installer>> or
scp://username:password@your-server-ip/path/to/file/<abc-installer> or
sftp://username:password@your-server-ip/path/to/file/<abc-installer>> or
file:///mnt/usb/path/to/file/<abc-installer>
A.B.C.D
The interface IPv4 address used to download the new version.
X:X::X:X
The interface IPv6 address used to download the new version.
verbose
Include download logs in the output.
Default
None
Command Mode
Privileged Exec mode
Applicability
This command was introduced in OcNOS version 1.3.6.
Examples
#sys-update get source-interface xe3 http://myServer/OcNOS-SP-MPLS-Q1-6.3.3-41-MR-installer
Example using SCP if IP address or hostname is not present in the known_hosts file.
OcNOS#sys-update get scp://root@10.12.33.204/home/OcNOS-SP-MPLS-Q1-6.3.3-41-MR-installer
VRF default cannot be deleted or not exists
Please wait ...
curl: (60) SSL peer certificate or SSH remote key was not OK
More details here: curl - SSL CA Certificates
curl failed to verify the legitimacy of the server and therefore could not
establish a secure connection to it. To learn more about this situation and
how to fix it, please visit the web page mentioned above.
The host name is not added in known_host
Do you want to add it to known_host
continue (y/n):y
Successfully added host to known_hosts file.
Please wait ...
OcNOS#show installers
/installers/OcNOS-SP-MPLS-Q1-6.3.3-39-MR-installer
/installers/OcNOS-SP-MPLS-Q1-6.3.3-41-MR-installer
sys-update install
Use this command to upgrade the current software to a newer version. You can do two types of installation:
• If a .deb file is provided, the board is loaded with new binaries.
• If an installer file is provided, the board is completely installed with a new kernel and binaries.
Note:
1. During an upgrade, if a license is not available the existing configuration is not applied. Also, the ZebOS.conf file is not created and the terminal monitor command is not allowed.
2. The URL must be compliant with RFC 3986.
3. When this command is executed without the source-interface parameter, then eth0 and the default management VRF are used. When this command is executed with the source-interface parameter then that interface is used.
4. At times while downloading installer through TFTP protocol, download progress would show 100% from the start to the end of the download. This behavior is observed whenever the TFTP server doesn't support the TFTP Option Negotiation. Also at times TFTP download takes more time to download the installer though the client and server are part of the same subnet, eventually download operation even times out after 30 minutes. The reason for such issue is the latency, here some of the TFTP server implementations are lagging performance. In such instances we recommend to switch to a different TFTP server. This TFTP download operation is verified in Debian Linux machine against the server present in the tftpd-hpa package.
5. For SCP and SFTP, make sure the IP address/hostname present in the known_hosts file else SCP and SFTP will fail with the error message “curl: (60) SSL peer certificate or SSH remote key was not OK”. If sys-update fails, the user is prompted to add the hostname/IP address in the known_hosts file to proceed with sys-update.
Command Syntax
sys-update install (|(source-interface IFNAME | (source-ip (A.B.C.D | X:X::X:X)))) URL (verbose|)
Parameters
IFNAME
The interface used to download the new version. If not specified, eth0 is used.
URL
Where to get the new version:
<http://username:password@your-server-ip/path/to/file/<abc-updater.deb> or abc-installer> or
<ftp://username:password@your-server-ip/path/to/file/<abc-updater.deb> or abc-installer> or
tftp://your-server-ip/path/to/file/<abc-updater.deb> or abc-installer> or
scp://username:password@your-server-ip/path/to/file/<abc-updater.deb or abc-installer> or
sftp://username:password@your-server-ip/path/to/file/<abc-updater.deb> or abc-installer> or
file:///mnt/usb/path/to/file/<abc-updater.deb or abc-installer>
A.B.C.D
The interface IPv4 address used to download the new version.
X:X::X:X
The interface IPv6 address used to download the new version.
verbose
Include upgrade logs in the output.
Default
None
Caution
OcNOS services are using /usr/local/etc path to store the device configuration, and this path mounted into a separate partition to isolate system configurations. This partition is meant only for system configuration. It will affect the system stability if the user uses this partition for storing general files. In this problematic state, if the device reboots, OcNOS services will not start properly, that would even create problems to the device connectivity. There will be an impact on normal system configuration operations.
User must take care of this problem just before issuing the following commands:
• reload/sys-reload - Reboots the device.
• sys-shutdown - This is to shutdown the device, but when users powers the device OcNOS services won't start cleanly.
• reboot / shutdown - From Linux shell
• Also includes all copy commands from Linux shell before issuing the user triggered reload commands.
Command Mode
Privileged Exec mode
Applicability
This command was introduced before OcNOS version 1.3.
Examples
#sys-update install source-interface eth2 http://10.12.52.150/myServer/OcNOS-SP-MPLS-Q1-6.3.3-41-MR-installer
#sys-update install http://10.12.52.150/myServer/OcNOS-SP-MPLS-Q1-6.3.3-41-MR-installer
#sys-update install http://10.12.52.150/myServer/OcNOS-SP-MPLS-Q1-6.3.3-41-MR-installer
#sys-update install http://10.12.52.150/myServer/OcNOS-SP-MPLS-Q1-6.3.3-41-MR-installer
sys-update list-version
Use this command to display files and folders. This command supports only FTP and the local file system.
Command Syntax
sys-update list-version ((source-interface IFNAME)|) URL
Parameters
IFNAME
The interface used to download the list. If not specified, eth0 is used.
URL
Where to get the list:
ftp://(username@|)serverIP/path/to/file/
file:///mnt/usb/path/to/file/
Default
None
Command Mode
Privileged Exec mode
Applicability
This command was introduced before OcNOS version 1.3.
Examples
#sys-update list-version ftp://10.12.52.150/
sys-update un-install
Use this command to un-install the device software remotely using the CLI and NetConf.management interfaces. This command decouples the device console dependency to un-install OcNOS.
This command puts the device in ONIE un-install mode and triggers device reboot. Upon reboot, ONIE detects the un-install mode and performs the un-installation. Once the un-installation completes, the device boots ONIE. To understand more about the un-installation technique, see the U-Boot and x86 Architecture sections at:
https://opencomputeproject.github.io/onie/design-spec/index.html#.
Note: By default, ONIE has SSH and Telnet services running, so you also have the option to trigger the installation through the management connection. For more information about SSH and Telnet connectivity, see:
https://opencomputeproject.github.io/onie/user-guide/index.html#debugging-an-installation.
Command Syntax
sys-update un-install
Parameters
None
Default
None
Command Mode
Privileged Exec mode
Applicability
This command was introduced in OcNOS version 1.3.8.
Examples
#sys-update un-install
sys-update verify
Use this command to verify the checksum and compatibility of the downloaded image. This command does not install the image and just lists the compatibility with HW, license and checksum.
Command Syntax
sys-update verify IMAGE_PATH
Parameters
IMAGE_PATH
Path of downloaded image. File should be present in /installers/.
Default
None
Command Mode
Privileged Exec mode
Applicability
This command was introduced in OcNOS version 6.2.0
Examples
#sys-update verify /installers/OcNOS-6.1.0.39-MPLS_Q1-Alpha-installer
Verifying installer at /installers/OcNOS-6.1.0.39-MPLS_Q1-Alpha-installer
Checksum Validation: PASS: Checksum: d5b641802bac97df08ea87353d1e3f5daa73212b
Installer compatibility with HW: PASS
License compatibility: PASS
Overall Status: PASS