+ All Categories
Home > Documents > Unified Computing System

Unified Computing System

Date post: 24-Feb-2016
Category:
Upload: kiley
View: 34 times
Download: 0 times
Share this document with a friend
Description:
Unified Computing System. XML API Integration / Systems Management Standard Administration Tools. UCS API Integration. curl / xml Session Mgmt Example. curl / xml Session Example – continued. Login - Get a Cookie < aaaLogin inName ="admin" inPassword =" cisco123 " /> - PowerPoint PPT Presentation
Popular Tags:
16
© 2009 Cisco Systems, Inc. All rights reserved. Cisco Confidential Advanced Services 1 Unified Computing System XML API Integration / Systems Management Standard Administration Tools
Transcript
Page 1: Unified Computing System

© 2009 Cisco Systems, Inc. All rights reserved. Cisco ConfidentialAdvanced Services 1

Unified Computing System

XML API Integration / Systems ManagementStandard Administration Tools

Page 2: Unified Computing System

© 2009 Cisco Systems, Inc. All rights reserved. Cisco ConfidentialAdvanced Services 2

UCS API Integration

Standard Administration

Tools

Shell Scripts, bash /

csh / ksh / sh

Perl / awk

grep / sed / more

/ lesscurl and

xml

Firefox – Poster add-in

XML Transform

XSLT

Non-Disruptive Integration

Page 3: Unified Computing System

© 2009 Cisco Systems, Inc. All rights reserved. Cisco ConfidentialAdvanced Services 3

curl / xml Session Mgmt Example

• curl – Command-Line URL• xml – XMLStarlet

Tools

• aaaLogin• aaaRefresh• aaaLogout

Methods

• Conserve resources in the UCS execution environment

Session Management

Page 4: Unified Computing System

© 2009 Cisco Systems, Inc. All rights reserved. Cisco ConfidentialAdvanced Services 4

curl / xml Session Example – continuedLogin - Get a Cookie<aaaLogin inName="admin" inPassword="cisco123" />

<aaaLogin cookie="" response="yes" outCookie="1237375605/d563f79e-5205-4240-b0bc-b65b7aac461d" outRefreshPeriod="600" outPriv="admin" outDomains="org-root" outChannel="noencssl" outEvtChannel="noencssl"></aaaLogin>

Stay Active - Refresh your Cookie<aaaRefresh inName="admin" inPassword="cisco123"

inCookie="1237375605/d563f79e-5205-4240-b0bc-b65b7aac461d" />

<aaaRefresh cookie="" response="yes" outCookie="1237376246/e2012cdc-7072-486c-ab3a-7f8ba58516b4" outRefreshPeriod="600" outPriv="admin" outDomains="org-root" outChannel="noencssl" outEvtChannel="noencssl">

</aaaRefresh>

Logout – Deactivate your Cookie<aaaLogout inCookie="1237375605/d563f79e-5205-4240-b0bc-b65b7aac461d" />

<aaaLogout cookie="" response="yes" outStatus="success"> </aaaLogout>

Page 5: Unified Computing System

© 2009 Cisco Systems, Inc. All rights reserved. Cisco ConfidentialAdvanced Services 5

curl / xml Session Example – continuedaaaLogin

curl-k – connect to SSL sites without certs-H – Custom header to pass to server-N – Disable buffering of the output-s – Silent mode. Don't output anything-d – HTTP POST data

Page 6: Unified Computing System

© 2009 Cisco Systems, Inc. All rights reserved. Cisco ConfidentialAdvanced Services 6

curl / xml Session Example – continuedaaaLogin

xmlfo – Format outputsel – Select data or query XML -t – template named or default-m – match XPATH expression-v – print value of XPATH expression

Page 7: Unified Computing System

© 2009 Cisco Systems, Inc. All rights reserved. Cisco ConfidentialAdvanced Services 7

curl / xml Session Example – continuedaaaRefresh & aaaLogout

Page 8: Unified Computing System

© 2009 Cisco Systems, Inc. All rights reserved. Cisco ConfidentialAdvanced Services 8

curl / xml Query Example

• curl – Command-Line URL• xml – XMLStarlet

Tools

• configResolveClass

Methods

• Retrieve Information about the UCS

Queries

Page 9: Unified Computing System

© 2009 Cisco Systems, Inc. All rights reserved. Cisco ConfidentialAdvanced Services 9

curl / xml Query Example – continuedconfigResolveClasscurl -k -H "Content-Type: text/xml" -N -s –d

'<configResolveClass classId="lsServer" inHierarchical="true" cookie="1251318687/d201cae3-059a-4c76-baa7-e85fbc0f8496" />' https://172.21.60.75/nuova |xml sel –t -m //lsServer[@assignState=\'assigned\'] -s A:T:U @dn -v "concat('SP: ',@dn,':',@assignState,':',@pnDn,':')" -m lsPower -v @state –b –n

curl format remains the samexml has additional operatorsxpath query – [@assignState='assigned']-s – sort A:T:Uconcat – concatenation function-b – break nesting-n – print newline

Page 10: Unified Computing System

© 2009 Cisco Systems, Inc. All rights reserved. Cisco ConfidentialAdvanced Services 10

curl / xml Query Example – continuedconfigResolveClass – lsServer object<lsServer agentPolicyName="" assignState="assigned" assocState="associated" bootPolicyName=""

childAction="deleteNonPresent" configQualifier="" configState="applied" descr="ESX 4 Cluster 01 Node 02" dn="org-root/org-tory_org/ls-esx4-cluster-01-node-02" dynamicConPolicyName="" fltAggr="0" hostFwPolicyName="101e_host_fw" identPoolName="" intId="138635" localDiskPolicyName="internal-RAID-1" mgmtAccessPolicyName="" mgmtFwPolicyName="101e_mgmt_fw" name="esx4-cluster-01-node-02" operState="ok" owner="management" pnDn="sys/chassis-1/blade-8" scrubPolicyName="" solPolicyName="default" srcTemplName="" statsPolicyName="default" type="instance" uuid="000025b5-0000-0000-0001-000000000002" uuidSuffix="0000-000000000000">

<vnicEther adaptorProfileName="" addr="00:25:B5:01:02:02" bootDev="disabled" childAction="deleteNonPresent" configState="applied" equipmentDn="sys/chassis-1/blade-8/adaptor-1/host-eth-1" fltAggr="0" identPoolName="" instType="manual" name="eth1" nwTemplName="vnic_b_esx_01" order="2" owner="logical" pinToGroupName="" qosPolicyName="" rn="ether-eth1" statsPolicyName="default" switchId="B" type="ether">

<vnicEtherIf addr="00:25:B5:01:02:02" childAction="deleteNonPresent" defaultNet="yes" name="default" operState="indeterminate" owner="logical" rn="if-default" switchId="B" type="ether" vnet="1"/>

<vnicEtherIf addr="00:25:B5:01:02:02" childAction="deleteNonPresent" defaultNet="no" name="vlan700" operState="indeterminate" owner="logical" rn="if-vlan700" switchId="B" type="ether" vnet="700"/>

</vnicEther> <vnicFc adaptorProfileName="" addr="20:00:00:25:B5:01:02:01" bootDev="enabled" childAction="deleteNonPresent"

configState="applied" equipmentDn="sys/chassis-1/blade-8/adaptor-1/host-fc-1" fltAggr="0" identPoolName="" instType="manual" name="fc0" nodeAddr="20:00:00:25:B5:01:02:00" nwTemplName="vhba_a_esx_01" order="3" owner="logical" persBind="disabled" persBindClear="no" pinToGroupName="" rn="fc-fc0" statsPolicyName="default" switchId="B" type="fc">

<vnicFcIf childAction="deleteNonPresent" initiator="20:00:00:25:B5:01:02:01" name="vsan10" operState="indeterminate" owner="logical" rn="if-default" switchId="B" type="fc" vnet="10"/>

</vnicFc> <lsPower childAction="deleteNonPresent" rn="power" state="up"/> <lsBinding childAction="deleteNonPresent" computeEpDn="fabric/server/compute-ep-ven-Cisco Systems Inc-mod-N20-

B6620-1-ser-QCI125200GR" name="pn-binding" pnDn="sys/chassis-1/blade-8" rn="pn"/> </lsServer>

Page 11: Unified Computing System

© 2009 Cisco Systems, Inc. All rights reserved. Cisco ConfidentialAdvanced Services 11

curl / xml Query Example – continuedconfigResolveClass

Response:SP: org-root/ls-jefhillm-rhel:assigned:sys/chassis-1/blade-4:upSP: org-root/org-QuickStartRoot/org-Tests/org-Hypervisor/ls-esx4-local_disk:assigned:sys/chassis-1/blade-2:upSP: org-root/org-tory_org/ls-esx4-cluster-01-node-01:assigned:sys/chassis-1/blade-6:upSP: org-root/org-tory_org/ls-esx4-cluster-01-node-02:assigned:sys/chassis-1/blade-8:up

Alternate UCS Query that pre filters lsServer based on assignState=assigned alleviates the need for [@assignedState='assigned'] as part of the XPATH expression<configResolveClass cookie="1251387546/3b3832e5-d066-40f3-a3b1-bb65789b8de0" inHierarchical="true" classId="lsServer"><inFilter><eq class="lsServer" property="assignState" value="assigned" /></inFilter> </configResolveClass>

Page 12: Unified Computing System

© 2009 Cisco Systems, Inc. All rights reserved. Cisco ConfidentialAdvanced Services 12

curl / xml Configuration Example

• curl – Command-Line URL• xml – XMLStarlet

Tools

• configConfMos

Methods

• Manipulate UCS Objects

Configurations

Page 13: Unified Computing System

© 2009 Cisco Systems, Inc. All rights reserved. Cisco ConfidentialAdvanced Services 13

curl / xml Config Example – continuedconfigConfMos – mgmtBackup object<configConfMos inHierarchical="true" cookie="1251492362/1177b546-1da1-4f30-8410-6bc6d8c288f7"> <inConfigs> <pair key="sys/backup-10.98.47.74"> <mgmtBackup adminState="enabled" descr="" dn="sys/backup-10.98.47.74" hostname="10.98.47.74"

proto="tftp" pwd="" remoteFile="ucs-bk1-172.21.60.75-config-system-2009-08-28" status="created" type="config-system" user=""

/> </pair> </inConfigs></configConfMos>

<configConfMos cookie="1251492362/1177b546-1da1-4f30-8410-6bc6d8c288f7" response="yes"> <outConfigs> <pair key="sys/backup-10.98.47.74"> <mgmtBackup adminState="enabled" childAction="deleteNonPresent" descr="" dn="sys/backup-

10.98.47.74" fsmDescr="" fsmPrev="nop" fsmProgr="100" fsmRmtInvErrCode="none" fsmRmtInvErrDescr="" fsmRmtInvRslt="" fsmStageDescr="" fsmStamp="never" fsmStatus="backupBegin" fsmTry="0" hostname="10.98.47.74" intId="157607" job="immediate" name="" postAction="remove" proto="tftp" pwd="" remoteFile="ucs-bk1-172.21.60.75-config-system-2009-08-28" status="created" type="config-system" user=""

/> </pair> </outConfigs></configConfMos>

Page 14: Unified Computing System

© 2009 Cisco Systems, Inc. All rights reserved. Cisco ConfidentialAdvanced Services 14

curl / xml Config Example – continuedconfigConfMos

Page 15: Unified Computing System

© 2009 Cisco Systems, Inc. All rights reserved. Cisco ConfidentialAdvanced Services 15

XML API PotentialUtilize the XML API to Extend UCS Functionality

• 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 16: Unified Computing System

© 2009 Cisco Systems, Inc. All rights reserved. Cisco ConfidentialAdvanced Services 16


Recommended