Installing and Recovering Software Using the Open Network Install Environment (ONIE)
ONIE, the open network install environment from Cumulus Networks, is a network OS installer that installs Junos OS and third party applications on a switch. Juniper Network switches come pre-installed with ONIE. When you turn on a switch, the ONIE discovery and execution (ODE) application locates the management Ethernet interface and the Junos OS software package, which can be found either locally on the switch or on the network using HTTP, FTP, or TFTP. After the switch discovers and downloads the Junos OS software package, the switch installs the Junos OS software, reboots, and then boots from Junos OS. Junos OS then becomes the default software image.
If you want to use the Junos OS CLI to install software, see Installing Software Packages on QFX Series Devices (Junos OS).
Upgrading involves these tasks:
Understanding the Open Network Install Environment
When you log into the switch with ONIE, you see the install boot menu:
Juniper Linux (This is a default menu option.)
Juniper Linux Debug
Juniper Linux Recovery
Go to ONIE Loader
ONIE: Install OS (This is a default menu option.)
ONIE: Rescue
ONIE: Uninstall OS
ONIE: Update ONIE
ONIE: Embed ONIE
You can use the following commands to install and uninstall Junos OS and start and stop the ONIE ODE application:
onie-nos-install
Installs Junos OS from any URL, such as http://, ftp://, and file://.
onie-uninstaller
Uninstalls Junos OS.
onie-discovery-start
The discovery process starts automatically. However, if you stop the discovery process by issuing the onie-discovery-stop command, you can restart the discovery process by issuing the onie-discovery-start command.
onie-discovery-stop
Stops the discovery process. To restart the discovery process, issue the onie-discovery-start command.
Downloading Software Files with a Browser
You download the software package from the Juniper Networks Downloads page at https://support.juniper.net.
To access the download site, you must have a service contract with Juniper Networks and an access account. If you need help obtaining an account, complete the registration form at the Juniper Networks website https://www.juniper.net/registration/Register.jsp.
To download a software package:
Connecting to the Console Port
We recommend that you connect to the console port while installing the installation package so you can respond to any required user input and detect any errors that might occur.
Backing Up the Current Configuration Files
Before you install the new installation package, we strongly recommend that you back up your current configuration files because the upgrade process removes all of the stored files on the switch.
To back up your current configuration files, enter the save
command:
user@switch# save filename
Executing this command saves a copy of your configuration files to a remote location such as an external USB device.
Uninstalling the Existing Version of Junos OS
The switch comes preinstalled with a version of Junos OS that is to be used with the Junos OS CLI. However, if you want to use ONIE to install Junos OS, you need to uninstall the existing Junos OS and reinstall the Junos OS image that has a .bin extension—for example, jnpr-qfx-5e-jdm-onie-updater-15.1-20150819_ups.4.bin file.
To uninstall your existing Junos OS version:
Installing a Junos OS Software Package That Resides on a Webserver or DHCP Server with DHCP Options Configured
To install a Junos OS software package residing on a webserver or DHCP server:
Installing Junos OS Software Using Secure Copy Protocol (SCP)
To install Junos OS software using SCP:
Installing Junos OS Software Using FTP or TFTP Without a Webserver
To install Junos OS software using FTP or TFTP:
Installing Junos OS Software Using DHCP Server with No DHCP Options Configured
Use this installation method if you cannot modify or set the DHCP options on your DHCP server.
To install the Junos OS software using a DHCP server with no DHCP options configured:
Installing Junos OS Software Using Webserver Without DHCP Configured
Use this installation method if you do not have a DHCP server.
To install the Junos OS software using a webserver without DHCP configured:
Installing Junos OS Software Using USB Media
ONIE installation from a Junos OS image stored on USB media is not currently supported.
Use another procedure from this document to install ONIE.
Verifying Software Installation
Troubleshooting Boot Problems
Problem
Description
Junos OS does not boot.
Solution
If Junos OS does not boot, and the console displays the Yocto GNU Linux shell instead, it could mean that you have booted in the Juniper Linux Debug mode. If you see an error message that says, “[Error] Does not seem to be an QFX10002.” could mean that the EEPROM does not contain vendor-specific information. To verify the vendor-specific information, perform an ONIE: Rescue installation, and then verify the contents of the /var/run/*.dat file.
Select ONIE: Rescue from the GNU GRUB menu.
Issue the onie-syseeprom at the ONIE prompt.
For example:
ONIE:/ # onie-syseeprom TlvInfo Header: Id String: TlvInfo Version: 1 Total Length: 315 TLV Name Code Len Value -------------------- ---- --- ----- Base MAC Address 0x24 6 54:2A:A2:FB:DC:00 MAC Addresses 0x2A 2 256 Product Name 0x21 23 QFX10000-ÿÿÿÿÿÿÿ Serial Number 0x23 12 116G1EC00032 Part Number 0x22 16 1AES48S6Q.A2Gÿÿÿ Device Version 0x26 1 1 Manufacture Date 0x25 19 01/13/2015 21:40:30 Vendor Name 0x2D 20 JUNIPER NETWORKS INC Manufacturer 0x2B 14 JUNIPER NETWORKS INC Vendor Extension 0xFD 48 0x00 0x00 0x7C 0x82 0x01 0x00 0x41 0x32 0xFF 0xFF 0xFF 0xFF 0xFF 0xFF 0x0F Vendor Extension 0xFD 62 0x00 0x00 0x0A 0x4C 0x51 0x06 0x52 0x45 0x56 0x20 0x30 0x31 0x52 0x0C 0x3F Platform Name 0x28 37 x86_64-alpha_networks_snx60a0_486f-r0 Loader Version 0x29 23 master-201412161452.0.1 CRC-32 0xFE 4 0xB88C8885 Checksum is valid.
From the output, you can see that the vendor-specific information confirms that it is for Juniper Networks.
Creating an Emergency Boot Device
Before you begin, you need to have the jnpr-qfx-5e-jdm-onie-updater-15.1-20150819_ups.4.bin version of ONIE software.
If the Open Network Install Environment (ONIE) software is damaged or corrupted in some way, or the switch went into rescue mode, you can use an emergency boot device to repartition the primary disk and load a fresh installation of ONIE. Use the following procedure to create an emergency boot device.
In the following procedure, we assume that you are creating the emergency boot device on a switch. You can create the emergency boot device on any PC or laptop that supports Linux.
To create an emergency boot device:
Performing a Recovery Installation
In the event that the Open Network Install Environment (ONIE) is corrupted, the switch goes into rescue mode, or you need to reinstall ONIE software for any reason, you need to perform a recovery installation.
All Junos OS partitions are destroyed during a recovery installation.
Before you can perform a recovery installation, make sure you have an emergency boot device loaded with ONIE software.
Insert the emergency boot device into the device.
Power cycle the device.
Press the ESC button to go into the Boot Manager menu.
Select Boot Manager, and then press Enter.
Select Unigen PQS1000 under Legacy USB, and then press Enter.
Select ONIE: Embed ONIE from the ONIE Installer menu, and then press Enter.
The recovery installation proceeds using the emergency boot device.
Remove the emergency boot device.
Verify that the ONIE software was installed by looking at the installation log file.
For example:
Info: Found static url: file:///lib/onie/onie-updater ONIE: Executing installer: file:///lib/onie/onie-updater Verifying image checksum ... OK. Preparing image archive ... OK. ONIE: Version : master-201412161452.0.1
Installation log files are displayed automatically during the installation process, but if you want to verify installation log files at a different time, you can find them in the in the /var/log/ directory. To view an installation log file, issue the tail -f /var/log/onie.log command.
Issue the parted /dev/sda print command to verify that the ONIE partitions have been created.
For example:
ONIE:/ # parted /dev/sda print Model: ATA TS8GHSD630 (scsi) Disk /dev/sda: 8012MB Sector size (logical/physical): 512B/512B Partition Table: gpt Disk Flags: Number Start End Size File system Name Flags 1 1049kB 3146kB 2097kB GRUB-BOOT hidden, bios_grub 2 3146kB 137MB 134MB ext4 ONIE-BOOT hidden