Cisco DevNet Evolving Technologies Study Guide

Transcription

Cisco DevNet Evolving TechnologiesStudy GuideNicholas Russo — CCIE #42518 (EI/SP) CCDE #20160041October 30, 20211

AbstractNicholas Russo holds active CCIE certifications in Enterprise Infrastructure and Service Provider, aswell as CCDE. Nick authored a comprehensive study guide for the CCIE Service Provider version 4examination and this document provides updates to the written test for all CCIE/CCDE tracks. Nick alsoholds a Bachelor’s of Science in Computer Science, from the Rochester Institute of Technology (RIT) andis a frequent programmer in the field of network automation. Nick lives in Maryland, USA with his wife,Carla, and daughters, Olivia and Josephine. For updates to this document and Nick’s other professionalpublications, please follow the author on his Twitter, LinkedIn, and personal website.Technical Reviewers: Angelos Vassiliou, Leonid Danilov, and many from the RouterGods team.This material is not sponsored or endorsed by Cisco Systems, Inc. Cisco, Cisco Systems, CCIE andthe CCIE Logo are trademarks of Cisco Systems, Inc. and its affiliates. All Cisco products, features, ortechnologies mentioned in this document are trademarks of Cisco. This includes, but is not limited to,Cisco IOS, Cisco IOS-XE, Cisco IOS-XR, and Cisco DevNet. The information herein is provided on an“as is” basis, without any warranties or representations, express, implied or statutory, including withoutlimitation, warranties of noninfringement, merchantability or fitness for a particular purpose.Author’s NotesThis book was originally designed for the CCIE and CCDE certification tracks that introduced the “EvolvingTechnologies” section of the blueprint for the written qualification exam. Those exams have since beenoverhauled and many of their topics have been moved under the umbrella of Cisco DevNet. This bookis not specific to any certification track and provides an overview of the three key evolving technologies:Cloud, Network Programmability, and Internet of Things (IoT). Italic text represents cited text from anothernot created by the author. This is often directly from a Cisco document, which is appropriate given that thisis a summary of Cisco’s vision on the topics therein. This book is not an official publication and does nothave an ISBN assigned. The book will always be free. The opinions expressed in this study guide andits corresponding documentation belong to the author and do not necessarily represent those of Cisco. Myonly request is that you not distribute this book yourself. Please direct your friends and colleagues to mywebsite where they can download it for free.I wrote this book because I believe that free and open-source software is the way of the future. So too do Ibelieve that the manner in which this book is published represents the future of publishing. I hope this bookserves its obviously utility as a technical reference, but also as an inspiration for others to meaningfullycontribute to the open-source community.Copyright 2021 Nicholas Russohttp://njrusmc.net2

Contents1 Cloud1.1 Introduction . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .1.2 Infrastructure, platform, and software as a service (XaaS) . . . . . . . . . . . .1.3 Performance, scalability, and high availability . . . . . . . . . . . . . . . . . . .1.4 Security implications, compliance, and policy . . . . . . . . . . . . . . . . . . .1.5 Workload migration . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .1.6 Compute virtualization . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .1.6.1 Virtual Machines . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .1.6.2 Containers with Docker Demonstration . . . . . . . . . . . . . . . . . . .1.6.3 Python Virtual Environments (venv) for Refactoring . . . . . . . . . . . .1.7 Connectivity . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .1.7.1 Virtual Switches . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .1.7.2 Software-Defined Wide Area Network (SD-WAN Viptela Demonstration)1.7.3 Software-Defined Access (SDA) . . . . . . . . . . . . . . . . . . . . . .1.7.4 Software-Defined Data Center (SD-DC) . . . . . . . . . . . . . . . . . .1.8 Virtualization functions . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .1.8.1 Network Functions Virtualization infrastructure (NFVi) . . . . . . . . . .1.8.2 Virtual Network Functions with NFVIS Demonstration . . . . . . . . . .1.9 Automation and orchestration tools . . . . . . . . . . . . . . . . . . . . . . . . .1.9.1 Cloud Center . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .1.9.2 Digital Network Architecture Center (DNA-C) Demonstration . . . . . .1.9.3 Kubernetes Orchestration with minikube Demonstration . . . . . . . . .1.9.4 Amazon Web Services (AWS) CLI Demonstration . . . . . . . . . . . .1.9.5 Infrastructure as Code using Terraform . . . . . . . . . . . . . . . . . . .1.9.6 Flask Application Monitoring with Prometheus . . . . . . . . . . . . . .1.10 References and Resources . . . . . . . . . . . . . . . . . . . . . . . . . . . . 62 Network Programmability2.1 Data models and structures . . . . . . . . . . . . . . . . . . . . . . . . . . . . .2.1.1 YANG . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .2.1.2 YAML . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .2.1.3 JSON . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .2.1.4 XML . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .2.2 Device programmability . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .2.2.1 Google Remote Procedure Call (gRPC) on IOS-XR using iosxr grpc . .2.2.2 gRPC on IOS-XR using grpcio and Manual Compilation . . . . . . . . .2.2.3 gRPC Network Management Interface (gNMI) on IOS-XR using gNMIc2.2.4 Python paramiko Library on IOS-XE . . . . . . . . . . . . . . . . . . . .2.2.5 Python netmiko Library on IOS-XE . . . . . . . . . . . . . . . . . . . . .2.2.6 NETCONF using netconf-console on IOS-XE . . . . . . . . . . . . . . .2.2.7 NETCONF using Python and jinja2 on IOS-XE . . . . . . . . . . . . . .2.2.8 REST API on IOS-XE . . . . . . . . . . . . . . . . . . . . . . . . . . . .2.2.9 RESTCONF on IOS-XE . . . . . . . . . . . . . . . . . . . . . . . . . . .2.3 Controller based network design . . . . . . . . . . . . . . . . . . . . . . . . . .2.3.1 SDN Models . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .2.3.2 Centralized SDN using OpenFlow and Faucet . . . . . . . . . . . . . . .2.4 Configuration management tools and version control systems . . . . . . . . . .2.4.1 Agent-based Summary . . . . . . . . . . . . . . . . . . . . . . . . . . .2.4.2 Agent-less Summary . . . . . . . . . . . . . . . . . . . . . . . . . . . . .2.4.3 Agent-less Demonstration with Ansible (SSH/CLI) . . . . . . . . . . . .2.4.4 NETCONF-based Infrastructure as Code with Ansible . . . . . . . . . .2.4.5 RESTCONF-based Infrastructure as Code with Ansible . . . . . . . . 145145147147150155Copyright 2021 Nicholas Russohttp://njrusmc.net3

2.4.6 Agent-less Demonstration with Nornir . . . . .2.4.7 Version Control Overview . . . . . . . . . . . .2.4.8 Git with Github . . . . . . . . . . . . . . . . . .2.4.9 Git with AWS CodeCommit and CodeBuild . .2.4.10 Subversion (SVN) and comparison to Git . . .2.4.11 Network Validation with Batfish . . . . . . . . .2.4.12 Data Validation with JSON Schema . . . . . .2.4.13 Pre/Post Checks with Cisco pyATS and Genie2.5 References and Resources . . . . . . . . . . . . . . 2292322334 Blueprint v1.0 Legacy Topics4.1 Cloud . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .4.1.1 Troubleshooting and Management . . . . . . . . . . . .4.1.2 OpenStack components with PackStack Demonstration4.1.3 Cloud Comparison Chart . . . . . . . . . . . . . . . . .4.2 Network Programmability . . . . . . . . . . . . . . . . . . . . .4.2.1 SDN Controllers . . . . . . . . . . . . . . . . . . . . . .4.2.2 DevOps methodologies, tools and workflows . . . . . .4.2.3 Basic Jenkins Setup Demonstration . . . . . . . . . . .4.3 Internet of Things . . . . . . . . . . . . . . . . . . . . . . . . . .4.3.1 Performance, Reliability, and Scalability . . . . . . . . .2342342342342442442442462482552553 Internet of Things3.1 IoT Technology Stack . . . . . .3.1.1 IoT Network Hierarchy . .3.1.2 Data Acquisition and Flow3.2 IoT standards and protocols . . .3.3 IoT security . . . . . . . . . . . .3.4 IoT Edge and Fog Computing . .3.4.1 Data Aggregation . . . . .3.4.2 Edge Intelligence . . . . .3.5 References and Resources . . .5 Glossary of Terms256List of Figures12345678910111213141516Public Cloud High Level . . . . . . . . . . . .Private Cloud High Level . . . . . . . . . . . .Virtual Private Cloud High Level . . . . . . . .Connecting Cloud via Private WAN . . . . . .Connecting Cloud via IXP . . . . . . . . . . .Connecting Cloud via Internet VPN . . . . . .Comparing Virtual Machines and ContainersViptela SD-WAN High Level . . . . . . . . . .Viptela Home Dashboard . . . . . . . . . . .Viptela Node Summary . . . . . . . . . . . .Viptela Event Logging . . . . . . . . . . . . .Viptela Flow Exploration . . . . . . . . . . . .Viptela VoIP QoS Policy . . . . . . . . . . . .Cisco ACI SD-DC High Level . . . . . . . . .Cisco NFVIS Home Dashboard . . . . . . . .Cisco NFVIS Image Repository . . . . . . . .Copyright 2021 Nicholas 44454

67686970Cisco NFVIS Image Profiles . . . . . . . . . . .Cisco NFVIS Topology Builder . . . . . . . . .Cisco NFVIS Log Reporting . . . . . . . . . . .DNA-C Home Dashboard . . . . . . . . . . . .DNA-C Geographic View . . . . . . . . . . . .DNA-C Network Setings . . . . . . . . . . . . .DNA-C Network Profile for VNFs . . . . . . . .DNA-C Images for Physical Devices . . . . . .DNA-C Images for Virtual Devices . . . . . . .DNA-C Policy Main Page . . . . . . . . . . . .DNA-C Site Topology Viewer . . . . . . . . . .DNA-C Site Event Logging . . . . . . . . . . .Kubernetes Main Dashboard . . . . . . . . . .Kubernetes Application Scaling . . . . . . . . .Kubernetes Application Scaling . . . . . . . . .Kubernetes Workload Status . . . . . . . . . .Kubernetes Pods Summary . . . . . . . . . . .AWS User/Group Assignments for Terraform .AWS EC2 Permissions for Terraform . . . . . .Verifying EC2 Instances Made By Terraform . .Verifying VPC Subnet Made By Terraform . . .Prometheus Target Status . . . . . . . . . . . .Prometheus Counter Metric — Table . . . . . .Prometheus Counter Metric — Graph . . . . .Prometheus Gauge Metric — Table . . . . . . .Prometheus Gauge Metric — Graph . . . . . .Prometheus Histogram Metric — Table . . . . .Prometheus Histogram Metric — Graph . . . .SDN Model — Distributed . . . . . . . . . . . .SDN Model — Augmented . . . . . . . . . . . .SDN Model — Hybrid . . . . . . . . . . . . . .SDN Model — Centralized . . . . . . . . . . . .SDN Communications Channels . . . . . . . .OpenFlow Testbed Topology in GNS3 . . . . .Grafana Inventory Dashboard . . . . . . . . . .Grafana Port Statistics Dashboard . . . . . . .Github Changes — Summary . . . . . . . . . .Github Changes — Detailed Differences . . . .Creating a New AWS IAM User and Group . .Assigning AWS IAM Permissions . . . . . . . .Creating a New AWS CodeCommit RepositoryAWS CodeCommit README File . . . . . . . .AWS CodeCommit Repository with Files . . . .AWS CodeCommit Fibonacci Source Code . .AWS CodeBuild Build Start . . . . . . . . . . .AWS CodeBuild Build Progress . . . . . . . . .AWS CodeBuild Build Log . . . . . . . . . . . .AWS CodeCommit Build History . . . . . . . .SVN Repository — Initial Login . . . . . . . . .SVN Repository — Empty Project . . . . . . .SVN Repository — Files Present . . . . . . . .SVN Repository — Viewing Code . . . . . . . .Batfish pandas Data Frame in HTML Format .pyATS Testbed Network . . . . . . . . . . . . .Copyright 2021 Nicholas 1791861975

96979899100101IoT Network Architecture High Level . . .IoT Network Architecture With Example .Openstack Component Interconnections .Openstack Projects Page . . . . . . . . .Openstack Projects Page . . . . . . . . .Openstack Edit Project Information . . . .Openstack Edit Project Members . . . . .Openstack Launch Details . . . . . . . . .Openstack Launch Source . . . . . . . .Openstack Launch Flavor . . . . . . . . .Openstack Launch Security Groups . . .Openstack Key Pair Creation . . . . . . .Openstack Mapping Key Pair to InstanceOpenstack Instances (Compute) . . . . .Openstack Instances (Volumes) . . . . . .Cisco IWAN High Level Architecture . . .Jenkins git Plugins . . . . . . . . . . . . .Jenkins Personal Github Access Token .Jenkins Personal Access Tokens . . . . .Jenkins User-specific Plugins . . . . . . .Setting up Github Integration on Jenkins .Github SSH Keys for Jenkins Access . . .Github Repository URL for Jenkins DemoJenkins Source Code Management via gitJenkins Project Workspace . . . . . . . .AWS EC2 Plugin for Jenkins Integration .Adding Jenkins User in AWS IAM . . . . .Jenkins AWS Credential Creation . . . . .Adding AWS Cloud Option via Jenkins . .Testing Connection from AWS to JenkinsJenkins AMIs within EC2 . . . . . . . . 49249249249250251252252253253254254254254255Cloud Design Comparison . . . . . . . . . . . . .Cloud Security Comparison . . . . . . . . . . . .NFV Advantages and Disadvantages . . . . . . .Git and SVN Comparison . . . . . . . . . . . . .IoT Transport Protocol Comparison . . . . . . . .IoT Data Aggregation Protocol Comparison . . .Commercial Cloud Provider Comparison . . . . .Software Development Methodology Comparison.171841181226231244247List of Tables12356789Copyright 2021 Nicholas Russohttp://njrusmc.net6

1Cloud1.1IntroductionCisco has defined cloud as follows:IT resources and services that are abstracted from the underlying infrastructure and provided on-demandand at scale in a multitenant environment.Cisco identifies three key components from this definition that differentiate cloud deployments from ordinarydata center (DC) outsourcing strategies:1. “On-demand” means that resources can be provisioned immediately when needed, released when nolonger required, and billed only when used.2. “At-scale” means the service provides the illusion of infinite resource availability in order to meetwhatever demands are made of it.3. “Multitenant environment” means that the resources are provided to many consumers from a singleimplementation, saving the provider significant costs.These distinctions are important for a few reasons. Some organizations joke that migrating to cloud issimple; all they have to do is update their on-premises DC diagram with the words “Private Cloud” andupper management will be satisfied. While it is true that the term “cloud” is often abused, it is important todifferentiate it from a traditional private DC.Cloud architectures generally come in four variants:1. Public: Public clouds are generally the type of cloud most people think about when the word “cloud”is spoken. They rely on a third party organization (off-premises) to provide infrastructure where acustomer pays a subscription fee for a given amount of compute/storage, time, data transferred, orany other metric that meaningfully represents the customer’s “use” of the cloud provider’s sharedinfrastructure. Naturally, the supported organizations do not need to maintain the cloud’s physicalequipment. This is viewed by many businesses as a way to reduce capital expenses (CAPEX) sincepurchasing new DC equipment is unnecessary. It can also reduce operating expenses (OPEX) sincethe cost of maintaining an on-premises DC, along with trained staff, could be more expensive thana public cloud solution. A basic public cloud design is shown in the diagram that follows; the enterprise/campus edge uses some kind of transport to reach the Cloud Service Provider (CSP) network.The transport could be the public Internet, an Internet Exchange Point (IXP), a private Wide AreaNetwork (WAN), or something else.Copyright 2021 Nicholas Russohttp://njrusmc.net7

Figure 1: Public Cloud High Level2. Private: Like the joke above, this model is like an on-premises DC except it must supply the threekey ingredients identified by Cisco to be considered a “private cloud”. Specifically, this implies automation/orchestration, workload mobility, and compartmentalization must all be supported in an onpremises DC to qualify. The organization is responsible for maintaining the cloud’s physical equipment, which is extended to include the automation and provisioning systems. This can increase OPEXas it requires trained staff. Like the on-premises DC, private clouds provide application services to agiven organization and multi-tenancy is generally limited to business units or projects/programs withinthat organization (as opposed to external customers). The diagram that follows illustrates a high-levelexample of a private cloud.Figure 2: Private Cloud High Level3. Virtual Private: A virtual private cloud is a combination of public and private clouds. An organizationmay decide to use this to offload some (but not all) of its DC resources into the public cloud, whileretaining some things in-house. This can be seen as a phased migration to public cloud, or by someskeptics, as a non-committal trial. This allows a business to objectively assess whether the cloudis the “right business decision”. This option is a bit complex as it may require moving workloadsbetween public/private clouds on a regular basis. At the very minimum, there is the initial private-topublic migration; this could be time consuming, challenging, and expensive. This design is sometimescalled a “hybrid cloud” and could, in fact, represent a business’ IT end-state. The diagram that followsCopyright 2021 Nicholas Russohttp://njrusmc.net8

illustrates a high-level example of a virtual-private (hybrid) cloud.Figure 3: Virtual Private Cloud High Level4. Inter-cloud: Like the Internet (an interconnection of various autonomous systems provide reachabilitybetween all attached networks), Cisco suggests that, in the future, the contiguity of cloud computingmay extend between many third-party organizations. This is effectively how the Internet works; acustomer signs a contract with a given service provider (SP) yet has access to resources from severalthousand other service providers on the Internet. The same concept could be applied to cloud andthis is an active area of research for Cisco.Below is a based-on-a-true-story discussion that highlights some of the decisions and constraints relatingto cloud deployments.1. An organization decides to retain their existing on-premises DC for legal/compliance reasons. Byadding automation/orchestration and multi-tenancy components, they are able to quickly increaseand decrease virtual capacity. Multiple business units or supported organizations are free to adjusttheir security policy requirements within the shared DC in a manner that is secure and invisible toother tenants; this is the result of compartmentalization within the cloud architecture. This deploymentwould qualify as a “private cloud”.2. Years later, the same organization decides to keep their most important data on-premises to meetseemingly-inflexible Government regulatory requirements, yet feels that migrating a portion of theirprivate cloud to the public cloud is a solution to reduce OPEX long term. This increases the scalabilityof the systems for which the Government does not regulate, such as virtualized network componentsor identity services, as the on-premises DC is bound by CAPEX reductions. The private cloud footprintcan now be reduced as it is used only for a subset of tightly controlled systems, while the more genericplatforms can be hosted from a cloud provider at lower cost. Note that actually exchanging/migratingworkloads between the two clouds at will is not appropriate for this organization as they are simplytrying to outsource capacity to reduce cost. As discussed earlier, this deployment could be considereda “virtual private cloud” by Cisco, but is also commonly referred to as a “hybrid cloud”.3. Years later still, this organization considers a full migration to the public cloud. Perhaps this is madepossible by the relaxation of the existing Government regulations or by the new security enhanceCopyright 2021 Nicholas Russohttp://njrusmc.net9

ments offered by cloud providers. In either case, the organization can migrate its customized systemsto the public cloud and consider a complete decommission of their existing private cloud. Such decommissioning could be done gracefully, perhaps by first shutting down the entire private cloud andleaving it in “cold standby” before removing the physical racks. Rather than using the public cloud toaugment the private cloud (like a virtual private cloud), the organization could migrate to a fully publiccloud solution.Cloud implementation can be broken into 2 main categories: how the cloud provider works, and how customers connect to the cloud. The second question is more straightforward to answer and is discussed first.There are three main options for connecting to a cloud provider, but this list is by no means exhaustive:1. Private WAN (like MPLS L3VPN): Using the existing private WAN, the cloud provider is connected asan extranet. To use MPLS L3VPN as an example, the cloud-facing PE exports a central service routetarget (RT) and imports corporate VPN RT. This approach could give direct cloud access to all sitesin a highly scalable, highly performing fashion. Traffic performance would (should) be protected underthe ISP’s SLA to cover both site-to-site customer traffic and site-to-cloud/cloud-to-site customer traffic.The ISP may even offer this cloud service natively as part of the service contract. Certain servicescould be collocated in an SP POP as part of that SP’s cloud offering. The private WAN approachis likely to be expensive and as companies try to drive OPEX down, a private WAN may not evenexist. Private WAN is also good for virtual private (hybrid) cloud assuming the ISP’s SLA is honoredand is routinely measuring better performance than alternative connectivity options. Virtual privatecloud makes sense over private WAN because the SLA is assumed to be better, therefore the intraDC traffic (despite being inter-site) will not suffer performance degradation. Services could be spreadbetween the private and public clouds assuming the private WAN bandwidth is very high and latencyis very low, both of which would be required in a cloud environment. It is not recommended to do thisas the amount of intra-workflow bandwidth (database server on-premises and application/web serverin the cloud, for example) is expected to be very high. The diagram that follows depicts private WANconnectivity assuming MPLS L3VPN. In this design, branches could directly access cloud resourceswithout transiting the main site.Copyright 2021 Nicholas Russohttp://njrusmc.net10

Figure 4: Connecting Cloud via Private WAN2. Internet Exchange Point (IXP): A customer’s network is connected via the IXP LAN (might be aLAN/VLAN segment or a layer-2 overlay) into the cloud provider’s network. The IXP network is generally access-like and connects different organizations together so that they can peer with BorderGateway Protocol (BGP) directly, but typically does not provide transit services between sites like aprivate WAN. Some describe an IXP as a “bandwidth bazaar” or “bandwidth marketplace” where suchexchanges can happen in a local area. A strict SLA may not be guaranteed but performance would beexpected to be better than the Internet VPN. This is likewise an acceptable choice for virtual private(hybrid) cloud but lacks the tight SLA typically offered in private WAN deployments. A company could,for example, use internet VPNs for inter-site traffic and an IXP for public cloud access. A private WANfor inter-site access is also acceptable.Copyright 2021 Nicholas Russohttp://njrusmc.net11

Figure 5: Connecting Cloud via IXP3. Internet VPN: By far the most common deployment, a customer creates a secure VPN over theInternet (could be multipoint if outstations require direct access as well) to the cloud provider. Itis simple and cost effective, both from a WAN perspective and DC perspective, but offers no SLAwhatsoever. Although suitable for most customers, it is likely to be the most inconsistently performingoption. While broadband Internet connectivity is much cheaper than private WAN bandwidth (in termsof price per Mbps), the quality is often lower. Whether this is “better” is debatable and depends on thebusiness drivers. Also note that Internet VPNs, even high bandwidth ones, offer no latency guaranteesat all. This option is best for fully public cloud solutions since the majority of traffic transiting this VPNtunnel should be user service flows. The solution is likely to be a poor choice for virtual private clouds,especially if workloads are distributed between the private and public clouds. The biggest drawbackof the Internet VPN access design is that slow cloud performance as a result of the “Internet” issomething a company cannot influence; buying more bandwidth is the only feasible solution. In thisexample, the branches don’t have direct Internet access (but they could), so they rely on an existingprivate WAN to reach the cloud service provider.Copyright 2021 Nicholas Russohttp://njrusmc.net

Cisco DevNet Evolving Technologies Study Guide Nicholas Russo — CCIE #42518 (EI/SP) CCDE #20160041 October 30, 2021 1