The documentation set for this product strives to use bias-free language. For the purposes of this documentation set, bias-free is defined as language that does not imply discrimination based on age, disability, gender, racial identity, ethnic identity, sexual orientation, socioeconomic status, and intersectionality. Exceptions may be present in the documentation due to language that is hardcoded in the user interfaces of the product software, language used based on RFP documentation, or language that is used by a referenced third-party product. Learn more about how Cisco is using Inclusive Language.
The topics covered in this chapter are:
The bootable USB drive is used to re-image the router for the purpose of system upgrade or boot the router in case of boot failure. The bootable USB drive can be created using a compressed boot file.
A bootable USB drive is created by copying a compressed boot file into a USB drive. The USB drive becomes bootable after the contents of the compressed file are extracted.
Note | In case of failure to read or boot from USB drive, ensure that the drive is inserted correctly. If the drive is inserted correctly and still fails to read from USB drive, check the contents of the USB on another system. |
This task can be completed using Windows, Linux, or MAC operating systems available on your local machine. The exact operation to be performed for each generic step outlined here depends on the operating system in use.
Have access to a USB drive with a storage capacity that is between 8GB (min) and 32 GB (max). USB 2.0 and USB 3.0 are supported.
Copy the compressed boot file from the software download page at cisco.com to your local machine. The file name for the compressed boot file is in the format ncs5k-usb-boot-<release_number>.zip . For example, ncs5k-usb-boot-6.0.zip .
Use the bootable USB drive to boot the router or upgrade its image.
The router can be booted using an external bootable USB drive. This might be required when the router is unable to boot from the installed image. A boot failure may happen when the image gets corrupted. During the USB boot, process the router gets re-imaged with the version available on the USB drive.
Note | During the USB boot process, the router is completely re-imaged with the ISO image version present in the bootable USB drive. All existing configurations are deleted because the disk 0 content is erased. No optional packages are installed during the upgrade process; they need to be installed after the upgrade is complete. |
Create a bootable USB drive. See Create a Bootable USB Drive Using Compressed Boot File.
Ensure that an external connection unit (ECU) with two solid-state drives (SSDs) is present.
Step 1 | Connect the USB drive to the active RP. |
Step 2 | Connect to the console |
Step 3 | Power the router. |
Step 4 | Press Esc to pause the boot process and get the RPs to BIOS menu. |
Step 5 | Select the
USB from the boot menu on the RP to which the USB is connected to.
The image is copied in internal disk, and the router is restarted automatically. |
iPXE is a pre-boot execution environment that is embedded in the router and works at the BIOS level. iPXE is used to re-image the system, boot the router in case of boot failure or in the absence of a valid bootable partition.
iPXE acts as a boot loader and provides a flexibility to choose the image the system will boot based on the Platform Identifier (PID), the Serial Number or the management mac-address. iPXE must be defined in the DHCP server configuration file.
Zero Touch Provisioning (ZTP) helps in auto provisioning after the software installation of the router using iPXE.
Configuration: Downloads and executes the configuration files. The first line of the file must contain !! IOS XR for ZTP to process the file as a configuration.
Script: Downloads and executes the script files. These script files include a programmatic approach to complete a task. For example, scripts created using IOS XR commands to perform patch upgrades. The first line of the file must contain #! /bin/bash or #! /bin/sh for ZTP to process the file as a script.
Note | ZTP is supported only on the management port 0/RP0/CPU0/0. The port 0/RP0/CPU0/1 is not supported. |
A DHCP server must be configured for IPv4, IPv6 or both communication protocols.
Consult your network administrator or system planner to procure IP addresses and a subnet mask for the management interface.
Physical port Ethernet 0 on RP is the management port. Ensure that the port is connected to management network.
Enable firewall to allow the server to process DHCP packets.
interface eth3 { AdvSendAdvert on; MinRtrAdvInterval 60; MaxRtrAdvInterval 180; AdvManagedFlag on; AdvOtherConfigFlag on; prefix 2001:1851:c622:1::/64 { AdvOnLink on; AdvAutonomous on; AdvRouterAddr off; }; };
The HTTP server can be in the same server as that of the DHCP server, or can be on a different server. After the IP address is assigned from DHCP server, the router must connect to the HTTP server to download the image.
Step 1 | Create the dhcpd.conf file (for IPv4, IPv6 or both communication protocols), dhcpv6.conf file (for IPv6) or both in the /etc/ or /etc/dhcp directory. This configuration file stores the network information such as the path to the script, location of the ISO install file, location of the provisioning configuration file, serial number, MAC address of the router. |
Step 2 | Test the server
once the DHCP server is running. For example, for IPv4:
|
The following example shows a sample DHCP server configuration including iPXE and ZTP:
host <host-name> { hardware ethernet <router-serial-number or mac-id>; fixed-address <ip-address>; if exists user-class and option user-class = "iPXE" { # Image request, so provide ISO image filename "http://<ip-address>/<directory>/ncs5k-mini-x.iso"; } else { # Auto-provision request, so provide ZTP script or configuration filename "http://<ip-address>/<script-directory-path>/ncs5k-ztp.script"; #filename "http://<ip-address>/<script-directory-path>/ncs5k-ztp.cfg } }
Note | Either the ZTP .script file or the .cfg file can be provided at a time for auto-provisioning. |
Before your use the iPXE boot, ensure that:
DHCP server is set and is running. For more information, see Setup DHCP Server.
You have logged in to the System Admin console using the admin command.
hw-module location all bootmedia network reload
sysadmin-vm:0_RP0# hw-module location all bootmedia network reload Wed Dec 23 15:29:57.376 UTC Reload hardware module ? [no,yes]
iPXE 1.0.0+ (3e573) -- Open Source Network Boot Firmware -- http://ipxe.org
Features: DNS HTTP TFTP VLAN EFI ISO9660 NBI Menu
Trying net0...
net0: c4:72:95:a6:14:e1 using dh8900cc on PCI01:00.1 (open)
[Link:up, TX:0 TXE:0 RX:0 RXE:0]
Configuring (net0 c4:72:95:a6:14:e1).................. Ok << Talking to DHCP/PXE server to obtain network information
net0: 10.37.1.101/255.255.0.0 gw 10.37.1.0
net0: fe80::c672:95ff:fea6:14e1/64
net0: 2001:1800:5000:1:c672:95ff:fea6:14e1/64 gw fe80::20c:29ff:fefb:b9fe
net1: fe80::c672:95ff:fea6:14e3/64 (inaccessible)
Next server: 10.37.1.235
Filename: http://10.37.1.235/ncs5k/ncs5k-mini-x.iso
http://10.37.1.235/ncs5k/ncs5k-mini-x.iso ... 58% << Downloading file as indicated by DHCP/PXE server to boot install image