open network install environmentonie.org/static/onie/pdf/ocp_summit_sj_onie_16x9_final.pdfopen...

27
Open Network Install Environment Curt Brune Member of Technical Staff January 2014

Upload: others

Post on 26-Jun-2020

3 views

Category:

Documents


0 download

TRANSCRIPT

Page 1: Open Network Install Environmentonie.org/static/onie/pdf/OCP_Summit_SJ_ONIE_16x9_final.pdfOpen Network Install Environment Curt Brune Member of Technical Staff January 2014 . cumulusnetworks.com

Open Network Install Environment

Curt Brune

Member of Technical Staff

January 2014

Page 2: Open Network Install Environmentonie.org/static/onie/pdf/OCP_Summit_SJ_ONIE_16x9_final.pdfOpen Network Install Environment Curt Brune Member of Technical Staff January 2014 . cumulusnetworks.com

cumulusnetworks.com 2

• Overview

• What Is ONIE?

• Lessons Learned

• ONIE Development

• Demo

• Project Directions

Agenda

Page 3: Open Network Install Environmentonie.org/static/onie/pdf/OCP_Summit_SJ_ONIE_16x9_final.pdfOpen Network Install Environment Curt Brune Member of Technical Staff January 2014 . cumulusnetworks.com

What Is ONIE?

§ Network OS Install Environment §  Provides an environment for network OS installer discovery

and execution §  Like a pre-installed kickstarter §  Defined by its behaviors §  Implemented using a modern Linux kernel and BusyBox

§ An Open Source Project within OCP §  http://www.onie.org/

§ Evolving …

cumulusnetworks.com 3

Page 4: Open Network Install Environmentonie.org/static/onie/pdf/OCP_Summit_SJ_ONIE_16x9_final.pdfOpen Network Install Environment Curt Brune Member of Technical Staff January 2014 . cumulusnetworks.com

Hardware Vendors

cumulusnetworks.com 4

Page 5: Open Network Install Environmentonie.org/static/onie/pdf/OCP_Summit_SJ_ONIE_16x9_final.pdfOpen Network Install Environment Curt Brune Member of Technical Staff January 2014 . cumulusnetworks.com

Operating System Vendors

cumulusnetworks.com 5

Page 6: Open Network Install Environmentonie.org/static/onie/pdf/OCP_Summit_SJ_ONIE_16x9_final.pdfOpen Network Install Environment Curt Brune Member of Technical Staff January 2014 . cumulusnetworks.com

ONIE: Anatomy of a Network Switch

cumulusnetworks.com 6

(  Management  Interfaces  )   (  Data  Plane  )  

CPU SoC

DRAM Boot Flash

Mass Storage

Switching ASIC

Serial  Console  

Ethernet  Mgmt  Port  

10Gb  Port  

40Gb  Port  …  10Gb  

Port  40Gb  Port  

…  

PCIe  

Page 7: Open Network Install Environmentonie.org/static/onie/pdf/OCP_Summit_SJ_ONIE_16x9_final.pdfOpen Network Install Environment Curt Brune Member of Technical Staff January 2014 . cumulusnetworks.com

ONIE: Uses Management Interfaces

cumulusnetworks.com 7

(  Management  Interfaces  )   (  Data  Plane  )  

CPU SoC

DRAM Boot Flash

Mass Storage

Switching ASIC

Serial  Console  

Ethernet  Mgmt  Port  

10Gb  Port  

40Gb  Port  …  10Gb  

Port  40Gb  Port  

…  

PCIe  

Page 8: Open Network Install Environmentonie.org/static/onie/pdf/OCP_Summit_SJ_ONIE_16x9_final.pdfOpen Network Install Environment Curt Brune Member of Technical Staff January 2014 . cumulusnetworks.com

ONIE: Bare Metal Install – First Time Boot Up

cumulusnetworks.com 8

Boot Loader (HW Vendor Supplied)

ONIE (HW Vendor Supplied)

Installer (OS Vendor)

Boot  Loader  •  Low  Level  boot  loader,  configures  CPU  complex  •  Loads  and  boots  ONIE  

ONIE  •  Linux  Kernel  with  Busybox  •  Configures  management  Ethernet  interface  •  Locates  and  executes  an  OS  installer  •  Provides  tools  and  environment  for  installer  

OS  Installer  •  Available  from  network  or  USB  •  Linux  executable  •  Installs  vendor  OS  into  mass  storage  Network OS

(OS Vendor Supplied)

Fetches  

Installs  

Page 9: Open Network Install Environmentonie.org/static/onie/pdf/OCP_Summit_SJ_ONIE_16x9_final.pdfOpen Network Install Environment Curt Brune Member of Technical Staff January 2014 . cumulusnetworks.com

ONIE: Subsequent Reboots – Vendor’s OS is Already Installed

cumulusnetworks.com 9

Boot Loader (HW Vendor Supplied)

ONIE (HW Vendor Supplied)

Boot  Loader  •  Low  Level  boot  loader,  configures  CPU  complex  •  Loads  and  boots  OS  vendor’s  installed  OS  

Network  OS  •  Configures  Switching  ASIC  •  Runs  Network  Protocols  •  Provides  CLI  

Network OS (OS Vendor Supplied)

ONIE  •  SSll  exists,  but  is  not  used  •  Available  for  uninstall  /  re-­‐install  operaSons  

Page 10: Open Network Install Environmentonie.org/static/onie/pdf/OCP_Summit_SJ_ONIE_16x9_final.pdfOpen Network Install Environment Curt Brune Member of Technical Staff January 2014 . cumulusnetworks.com

ONIE: Network OS Installer Discovery and Install Behavior

cumulusnetworks.com 10

Configure Network Interface

Locate Installer

Run Installer

•  Uses  DHCPv4,  DHCPv6  •  Configures  Ethernet  interface  for  IPv4  /  IPv6  •  Configures  DNS  and  hostname  

•  Determines  the  locaSon  of  an  installer  executable  •  Examines  local  file  systems,  e.g.  USB  flash  drives  •  Uses  DHCP  opSons,  DNS  Service  Discovery,  MulScast  

DNS  and  IPv6  Neighbors  

•  Downloads  installer  via  URL  •  Passes  various  environment  variables  to  installer  •  Launches  installer  

Page 11: Open Network Install Environmentonie.org/static/onie/pdf/OCP_Summit_SJ_ONIE_16x9_final.pdfOpen Network Install Environment Curt Brune Member of Technical Staff January 2014 . cumulusnetworks.com

Why  Not  Use  PXE?  

cumulusnetworks.com 11

•  IPv6  and  HTTP  out  of  the  box  •  Use  exisSng  Linux  device  drivers.    No  need  to  write  new  ones  •  Integrated  automaSon  

Page 12: Open Network Install Environmentonie.org/static/onie/pdf/OCP_Summit_SJ_ONIE_16x9_final.pdfOpen Network Install Environment Curt Brune Member of Technical Staff January 2014 . cumulusnetworks.com

ONIE: Other Behaviors

§ Provides a mechanism for a network OS to invoke the above behaviors.

cumulusnetworks.com 12

Reinstall Remove currently installed OS and return to the “out of box” provisioning state

Uninstall Completely wipe out everything, except ONIE

Rescue Reboot box into ONIE for repair, debug and forensics

Update Install a new ONIE version

Diag Run HW Vendor’s diag (optional)

Page 13: Open Network Install Environmentonie.org/static/onie/pdf/OCP_Summit_SJ_ONIE_16x9_final.pdfOpen Network Install Environment Curt Brune Member of Technical Staff January 2014 . cumulusnetworks.com

Lessons Learned

§ Hardware Platforms §  Diverse mix of CPU complex designs, even within a

single CPU family. §  HW Vendors need freedom to customize ONIE §  Need mechanism to run HW vendor diag

§ Recurring Themes §  TLV based EEPROM format widely adopted §  Common HW designs reduce development time

cumulusnetworks.com 13

Page 14: Open Network Install Environmentonie.org/static/onie/pdf/OCP_Summit_SJ_ONIE_16x9_final.pdfOpen Network Install Environment Curt Brune Member of Technical Staff January 2014 . cumulusnetworks.com

ONIE Ongoing Development

§ Support Multiple CPU Architectures §  PowerPC – Today §  x86 – VM Prototype available today §  Thinking about ARM, MIPS §  Maintain ONIE behaviors across architectures

§ Testing and Compliance §  Enhance and extend regression test suites §  Develop compliance test suites

cumulusnetworks.com 14

Page 15: Open Network Install Environmentonie.org/static/onie/pdf/OCP_Summit_SJ_ONIE_16x9_final.pdfOpen Network Install Environment Curt Brune Member of Technical Staff January 2014 . cumulusnetworks.com

ONIE Ongoing Development

§ New Features §  DHCPv6 §  DNS Service Discovery / Multicast DNS discovery §  HW Vendor diagnostic

§ Releases §  Quarterly release cadence §  Ongoing maintenance §  Enhancements

cumulusnetworks.com 15

Page 16: Open Network Install Environmentonie.org/static/onie/pdf/OCP_Summit_SJ_ONIE_16x9_final.pdfOpen Network Install Environment Curt Brune Member of Technical Staff January 2014 . cumulusnetworks.com

ONIE x86 Strategy

§  Use existing BIOS from hardware vendors §  During manufacturing install GRUB2 and ONIE-x86 on

the mass storage block device §  NOS Installer adds partitions, installs software and

updates GRUB2 configuration.

cumulusnetworks.com 16

Page 17: Open Network Install Environmentonie.org/static/onie/pdf/OCP_Summit_SJ_ONIE_16x9_final.pdfOpen Network Install Environment Curt Brune Member of Technical Staff January 2014 . cumulusnetworks.com

Block Device Partitioning

§  Partition using GUID Partition Table (GPT) format §  GPT supported by Linux, GRUB, UEFI §  Supports dual-booting multiple operating systems

cumulusnetworks.com 17

Partition # Name R/W Notes 1 GRUB Boot r/o Used by GRUB and

GPT 2 ONIE BOOT r/o ONIE Kernel 3 ONIE CONFIG r/w Configuration 4+ For NOS use

Page 18: Open Network Install Environmentonie.org/static/onie/pdf/OCP_Summit_SJ_ONIE_16x9_final.pdfOpen Network Install Environment Curt Brune Member of Technical Staff January 2014 . cumulusnetworks.com

GRUB Menu

cumulusnetworks.com 18

Page 19: Open Network Install Environmentonie.org/static/onie/pdf/OCP_Summit_SJ_ONIE_16x9_final.pdfOpen Network Install Environment Curt Brune Member of Technical Staff January 2014 . cumulusnetworks.com

NOS Installer Duties

§  Create new GPT partition(s) §  Create file systems on partition(s) §  Install NOS files into partition(s) §  Update ONIE-CONFIG using ONIE provided CLIs

§  onie-boot-entry-add!§  onie-boot-entry-remove!§  onie-boot-entry-show!§  onie-boot-default!§  onie-boot-update!

cumulusnetworks.com 19

Page 20: Open Network Install Environmentonie.org/static/onie/pdf/OCP_Summit_SJ_ONIE_16x9_final.pdfOpen Network Install Environment Curt Brune Member of Technical Staff January 2014 . cumulusnetworks.com

x86 DEMO

§  Interface Masters Box with ONIE §  HTTP based install §  DHCP server configuration §  Install the ONIE Demo OS §  Go back and Install Cumulus Linux

cumulusnetworks.com 20

Page 21: Open Network Install Environmentonie.org/static/onie/pdf/OCP_Summit_SJ_ONIE_16x9_final.pdfOpen Network Install Environment Curt Brune Member of Technical Staff January 2014 . cumulusnetworks.com

ONIE Project Directions

§ Administrative §  Update ONIE draft specification with community §  Improve documentation §  Meeting cadence, e.g. monthly phone conference §  Area specialists, contributors, testers

cumulusnetworks.com 21

Page 22: Open Network Install Environmentonie.org/static/onie/pdf/OCP_Summit_SJ_ONIE_16x9_final.pdfOpen Network Install Environment Curt Brune Member of Technical Staff January 2014 . cumulusnetworks.com

Resources

§ ONIE Websites §  Main Page: http://www.onie.org/ §  Source Code: https://github.com/onie/onie/ §  Documentation: http://onie.github.io/onie/

cumulusnetworks.com 22

Page 23: Open Network Install Environmentonie.org/static/onie/pdf/OCP_Summit_SJ_ONIE_16x9_final.pdfOpen Network Install Environment Curt Brune Member of Technical Staff January 2014 . cumulusnetworks.com

© 2013 Cumulus Networks. Cumulus Networks, the Cumulus Networks Logo, and Cumulus Linux are trademarks or registered trademarks of Cumulus Networks, Inc. or its affiliates in the U.S. and other countries. Other names may be trademarks of their respective owners. The registered trademark Linux® is used pursuant to a sublicense from LMI, the exclusive licensee of Linus Torvalds, owner of the mark on a world-wide basis.

§ Thank You!

cumulusnetworks.com 23

Page 24: Open Network Install Environmentonie.org/static/onie/pdf/OCP_Summit_SJ_ONIE_16x9_final.pdfOpen Network Install Environment Curt Brune Member of Technical Staff January 2014 . cumulusnetworks.com

Back Up Slides

cumulusnetworks.com 24

Page 25: Open Network Install Environmentonie.org/static/onie/pdf/OCP_Summit_SJ_ONIE_16x9_final.pdfOpen Network Install Environment Curt Brune Member of Technical Staff January 2014 . cumulusnetworks.com

ONIE Boot Partition

§ Read-Only, except when updating ONIE itself §  Contains default GRUB config file §  Contains ONIE kernel and initramfs

cumulusnetworks.com 25

Page 26: Open Network Install Environmentonie.org/static/onie/pdf/OCP_Summit_SJ_ONIE_16x9_final.pdfOpen Network Install Environment Curt Brune Member of Technical Staff January 2014 . cumulusnetworks.com

ONIE Config Partition

§ Read-Write §  Contains GRUB configuration files §  The NOS installer updates the GRUB

configuration by changing files in this partition

cumulusnetworks.com 26

Page 27: Open Network Install Environmentonie.org/static/onie/pdf/OCP_Summit_SJ_ONIE_16x9_final.pdfOpen Network Install Environment Curt Brune Member of Technical Staff January 2014 . cumulusnetworks.com

Booting

§  BIOS loads GRUB from block device Master Boot Record §  GRUB checks the following:

cumulusnetworks.com 27

On a fresh install grub-default.cfg boots ONIE in the installer mode. Otherwise load the grub.cfg a NOS installer has setup.

if exists ONIE-CONFIG/grub.cfg { load ONIE-CONFIG/grub.cfg

} else { load ONIE-BOOT/grub-default.cfg }