22

Cisco USC Manager XML API Introduction and Overview

Embed Size (px)

Citation preview

Page 1: Cisco USC Manager XML API Introduction and Overview
Page 2: Cisco USC Manager XML API Introduction and Overview

Cisco UCS Manager XML API Introduction and Overview Session

Jason Shaw

Technical Marketing Engineer

Cisco

Jeff Foster

Technical Marketing Engineer

Cisco

Page 3: Cisco USC Manager XML API Introduction and Overview

© 2014 Cisco and/or its affiliates. All rights reserved. Cisco Public

Cisco Unified Computing System

3

Cisco UCS CentralMulti-UCS Manager

Global Inventory, Faults, Statistics, Admin Settings

Global Service Profiles, Pools, Policies

Service Profiles,

Cisco UCS Fabric Interconnects(Read Only / Cut Through Interfaces)

SNMP, Syslog, SMTP, SMASH CLP, CIM XML, Smart Call Home

20, 40, 48, and 96 portsCisco UCS I/O Modules and FEX’s

Cisco UCS Blade Server Chassis

Cisco UCS Blade and Rack Servers(Cut through Interfaces to CIMC)

Serial over LAN, KVM, IPMI

Cisco UCS I/O Adapters

Cisco UCS Manager (Read / Write Configuration Interfaces)

Embedded Element Manager, GUI and CLI

Page 4: Cisco USC Manager XML API Introduction and Overview

© 2014 Cisco and/or its affiliates. All rights reserved. Cisco Public

UCS Service Profiles

4

LAN

SAN

Page 5: Cisco USC Manager XML API Introduction and Overview

© 2014 Cisco and/or its affiliates. All rights reserved. Cisco Public

Programmatic Infrastructure

5

• Comprehensive XML API, standards-based interfaces

• Bi-Directional access to physical & logical internals

XML API

Direct UCS CLI UCS GUI 3rd Party Customer

Self Serve portals

Management Tools

Auditing Tools

System Status

Physical Inventory

Logical Inventory

Broad 3rd party integration support

Faster custom integration for customer use cases

Consistent data and views across ALL interfaces

Page 6: Cisco USC Manager XML API Introduction and Overview

© 2014 Cisco and/or its affiliates. All rights reserved. Cisco Public

UCS XML API Overview

• Communicates over HTTP / HTTPS

• XML Based, Transactional

• XML Transactions are Order Agnostic

• Standard Request / Response cycle

• Role Based Authentication

• Object Model Hierarchy

• Built-in Object Browser

• Published XML Schema

• Java Doc Style documentation

• High Availability

• Event Stream

UCS XML API Features

XML API

7

Page 7: Cisco USC Manager XML API Introduction and Overview

© 2014 Cisco and/or its affiliates. All rights reserved. Cisco Public

Use Case Examples for the UCS XML API

•Overarching system to maintain resource pools, users, policies, etc…

Manage Multiple UCS Systems

•Capture events, parse, store, report

•Create event gateway to monitoring solutions

Monitor and Integrate the Event Stream

•Generate appropriate responses to events

Automate Issue Remediation

•Export entire UCS Information Model

Configuration Backup

•Ensure Firmware consistency across all components

Firmware Image Management

Page 8: Cisco USC Manager XML API Introduction and Overview

© 2014 Cisco and/or its affiliates. All rights reserved. Cisco Public

Everything is an object

Objects are hierarchically organized

Class identifies object type Card, Port, VNIC…

Class InheritanceServer port is a subclass of port.

A server blade is a subclass of compute entity.

Set of attributes

identity states descriptions

references lifecycle

UCS XML Database contains comprehensive system information Discovered components

System configuration

Operational status including statistics and faults

Managed Objects (MO)

Managed Object

Root

9

Page 9: Cisco USC Manager XML API Introduction and Overview

© 2014 Cisco and/or its affiliates. All rights reserved. Cisco Public

Authentication

Object Navigation

DN (Name) Resolution

Class Resolution

Ancestor-Descendant Resolution

Sub-tree “Scope”

Child

Parent

Object Property Filters

Apply to DN or matching class

Single or multiple objects

Apply a hierarchical config

Object Configuration

Event Channel

Events

Method Categories

Managed Object

Root

DN

{RN}*

DN

Registry

Class

Registry

Instance IDRegistry

10

Page 10: Cisco USC Manager XML API Introduction and Overview

Cisco UCS Scripting Tools and SDKs

Page 11: Cisco USC Manager XML API Introduction and Overview

© 2014 Cisco and/or its affiliates. All rights reserved. Cisco Public

Cisco UCS PowerToolProgrammatic control over UCS hardware

• Architected for Flexibility and coverage• PowerShell Wrapper

– Cmdlet definition and structure

– Get-help support

• .NET UCS Namespace Library

– XML API call construction

– Class Definition

– Validation

• PowerShell Design• In-line get-help support

• Full Pipelining support

• Fully classed object definition

• All ‘legal’ verbs

• .NET Namespace provides common base for all Microsoft focused integration

• Targeted to support full manageability of UCS across multiple releases

Cisco UCS

PowerTool Module

UCS .NET Namespace

UCS XML API

cmdlets

12

Page 12: Cisco USC Manager XML API Introduction and Overview

© 2014 Cisco and/or its affiliates. All rights reserved. Cisco Public

UCS XML

Schema

Processor

UCSM-IN.xsd

UCSM-OUT.xsd

Augment

Schema

XML Method

& MO Meta

Information

PowerShell

Generator

Microsoft SCO IP

Generator

XYZ

Generator

Cisco UCS

PowerTool

(1850+ cmdlets)

Microsoft SCO

Integration Pack

XYZ

Integration Pack

Cisco UCS PowerTool Automated Code CreationAutomated Activity Generation from UCS XML Schema

13

Page 13: Cisco USC Manager XML API Introduction and Overview

© 2014 Cisco and/or its affiliates. All rights reserved. Cisco Public

Cisco UCS PowerTool for UCS ManagerMost Commonly Used Objects and Assets

• Chassis– Hardware – Power Supply / Fan

Modules / IO Modules

– Environmental statistical data (Power, cooling, network)

– Config and Hardware Faults

• Fabric Interconnect– Hardware – Power Supply / Fan

Modules / Network Expansion Modules

– Power / cooling / network/ environmental statistical data

– Network Elements (VLAN, VSAN, QoS, Port Profiles)

– Config and Hardware Faults

• Config. Operations– Pools (WWN, UUID, MAC, IP)

– Policy creation, manipulation, deletion, and consumption

– vNIC / vHBA Templates

– Service profile template creation, cloning, deletion, and consumption

• Simplistic service profile creation (with a limited scope of what is available to configure)

• Expert SP creation (use variabilized XML w/ config file)

– Compare Managed Objects across orgs and/or domains

– Sync Managed Objects across orgs and/or domains

• Service Profiles– Policies (Firmware, Boot Order,

vNIC / vHBA config, Storage, IPMI, SoL, BIOS)

– Pools (WWN, UUID, MAC, IP)

– Configuration Faults

– Launch UCS KVM for SP

• Servers– Hardware - CPU, Memory,

Adaptors, CIMC

– Power Operations

– Power / cooling / network /environmental statistical data

– Hardware Faults

14

Page 14: Cisco USC Manager XML API Introduction and Overview

© 2014 Cisco and/or its affiliates. All rights reserved. Cisco Public

Getting Started: ConvertTo-UcsCmdlet

• The best way to discover usage of PowerTool cmdlets and usage

• Usage: Option #1

• Launch UCS GUI & Login

• C:\> ConvertTo-UcsCmdlet

• Usage: Option #2

• C:\> Connect-Ucs 1.2.3.4

• C:\> Start-UcsGuiSession -LogAllXml

• C:\> ConvertTo-UcsCmdlet

• Usage: Option #3

• Create a ‘config-all’ XML backup from UCS Manager

• C:\> ConvertTo-UcsCmdlet -UcsBackup -LiteralPath backup.xml -OutputPath output.ps1

15

Page 15: Cisco USC Manager XML API Introduction and Overview

© 2014 Cisco and/or its affiliates. All rights reserved. Cisco Public

UCS Platform Emulator (UCSPE)

• No UCS Hardware Needed for API integration Development

• Full featured emulator for the UCS Manager

• Installs as a Virtual Machine

• Provides complete support for all XML API calls

• Object Browser to peruse the UCSM model

• Import & replicate existing live UCS Manager physical inventory

• Share saved physical inventories among UCS Platform Emulators

• Drag-n-drop hardware builder to create custom physical inventory

16

http://communities.cisco.com/ucspe

Page 16: Cisco USC Manager XML API Introduction and Overview

UCS PowerTool Demo

Page 17: Cisco USC Manager XML API Introduction and Overview

© 2014 Cisco and/or its affiliates. All rights reserved. Cisco Public

Cisco UCS PowerTool for IMCMost Commonly Used Objects and Assets

• Server Inventory– Hardware Inventory

• CPU

• Memory

• Motherboard

• Power Supplies

• Hard Disk Drives

• Fans

– Environmental statistical data (Power / Temperature)

– Hardware Faults

• Equipment Operations– Server Power State Change

– Enable / Disable LED

– KVM GUI Launch

– CIMC User Interface Launch

• CIMC Admin Config Operations– Monitoring (SNMP, Syslog, NTP)

– Authentication (Local Users, LDAP, LDAP Group to Role Mapping)

– Firmware Management via Host Update Utility Non-Interactive

– Import / Export CIMC Configuration

• Server Config Operations– BIOS Settings

– Boot Order (Legacy and Precision Boot Config)

– Local Storage Configuration

– Virtual Interface Card Adaptor Configuration

– Compare / Sync Objects across IMC’s

18

• Adaptors

– Storage Controller

– Virtual Interface Card

– LOM’s

– Other PCI devices

Page 18: Cisco USC Manager XML API Introduction and Overview

© 2014 Cisco and/or its affiliates. All rights reserved. Cisco Public

Getting Started: ConvertTo-ImcCmdlet

• The best way to discover the UCS PowerTool cmdlets and usage

• Launch IMC GUI, login, and make changes In CIMC GUI (Example: Configure BIOS Settings)

• Connect via UCS PowerTool for IMC and run:

• C:\> Connect-Imc 1.2.3.4

• C:\> $BiosSettings = Get-ImcBiosSettings -Hierarchy

• C:\> $BiosSettings | ConvertTo-ImcCmdlet

Page 19: Cisco USC Manager XML API Introduction and Overview

IMC PowerTool Demo

Page 20: Cisco USC Manager XML API Introduction and Overview

© 2014 Cisco and/or its affiliates. All rights reserved. Cisco Public

Cisco UCS User Community

http://communities.cisco.com/ucs

http://communities.cisco.com/ucsintegrations

• Tools, Downloads, Examples• UCS Platform Emulator (UCSPE)

• goUCS Automation Tool

• Python SDK for UCSM and IMC

• XML API, PowerShell code Examples

• Cisco UCS PowerTool (PowerShell Module)

• Microsoft Systems Center Integrations:– SCOM MP for Cisco UCS and Cisco IMC

– SCVMM UI Plugin

– SCO Integration pack for Cisco UCS and Cisco IMC

• Nagios plugin for Cisco IMC

• Documentation• Programming & Developer Guides

• Whitepapers

• Reference Guides (XML Model, Faults)

• Collaboration• Blogs, Videos, Forums

• Access to Cisco Subject Matter Experts

• Web Based End User Community

21

Page 21: Cisco USC Manager XML API Introduction and Overview
Page 22: Cisco USC Manager XML API Introduction and Overview