goUCS Automation Toolkit

goUCS is a toolkit that was created as a proof of concept to show how a UCS systems administrator could easily automate tasks across multiple UCS domains.  Since the advent of UCS's singular API, it has been clear to UCS admins the inherent power of being able to utilize and take advantage of this single API for use cases like auto-populating data in a central CMDB with the physical inventory of an entire UCS domain with one query; creating or modifying objects across multiple UCS domains like VLANs, policies, pools, etc.; and gathering data about a specific set of objects across UCS domains.  goUCS was designed for a UCS sysadmin as an example of a flexible and extensible command line style interface that provides the basic framework for managing multiple UCS sessions and the communication to and from UCS via the XMLAPI; and parsing and displaying any returned XML data into multiple output formats like CSV, tables, indented hierarchical lists, and raw XML.

 

goUCS enables the ability for a UCS sysadmin to learn at a much deeper level exactly how UCS communicates via the XMLAPI.  What better way to learn than to actually perform the action in the UCSM GUI manually, use goUCS to filter the Java log file from the UCSM GUI for the exact XML method the UCSM GUI used, and then provide a mechanism to replace the cookie and unique data in the XML document with variables enabling the UCS sysadmin to reuse the XML document over and over again programmatically.  goUCS provides a UCS sysadmin the ability to automate anything a UCSM GUI can do, albeit querying for data; modifying existing objects in UCS; or even complex tasks like creating 10 service profiles from a template, associating them to 10 blades, and powering the 10 blades on via a single transaction.

 

The options are endless, so take the plunge in automating UCS and download goUCS today!

 

What is new in goUCS version 2.1?

  • SUPPORT FOR UCS MANAGER 2.1: Added support for UCS Manager version 2.1.
  • SUPPORT FOR UCS CENTRAL:
    • Added support for UCS Central version 1.0. Added a new parameter named "SYSTEM" to <session>.cfg file to specify either UCS Manager (UCSM) or UCS Central (UCSC) to communicate with.
      • Added XML Tags to XML Wrappers to specify the default DME to send queries to when communicating with UCS Central.
  • FILTERLOG SUPPORT FOR UCS CENTRAL:  Added support for filterlog capabilities for UCS Central. The XML wrapper is named "filterlogc".
  • SESSION FILE CHANGES: Added a new parameter named "SYSTEM" in <session>.cfg file to specify either UCS Manager (UCSM) or UCS Central (UCSC) to communicate with.
  • JAVA 1.7 SUPPORT: Added additional Java support to support both Java versions 1.6 and 1.7
  • DEBUG SUPPORT: Added support for a debug flag ("d:") to process type to show XML API communication to and from goUCS and managed system.
  • XML WRAPPER CHANGES: Added support for providing options to parameters defined in XML wrappers.
    • OPTIONAL PARAMETERS – Provides the ability to define a parameter in a XML Wrapper as an optional parameter in XML Wrapper. goUCS will not require the parameter to be defined during goUCS execution of the XML Wrapper. Example syntax of optional parameter: $NAME:O:ARG$
      • DEFAULT PARAMETERS – Provides the ability to define a default response to parameter in XML Wrapper. goUCS will provide the default response defined in the XML Wrapper argument definition during goUCS execution of the XML Wrapper. Example syntax of default parameter: $RECURSIVE:D:false:ARG$
  • ANSWER FILE SYNTAX CHANGE: Added support for providing answer file syntax to support passing only arguments that are user defined arguments in the answer file, versus the default behavior where answer files required xml wrapper, process type, output type, and user defined arguments to be provided. Argument file format is still the same for the new syntax, but xml wrapper, process type, and output type lines are ignored passing only the user defined arguments to goUCS.
  • CLASS TYPE XML WRAPPER PARAMETER AUTO-TRANSLATOR: Added support for defining default translation of classes to user arguments present in returned XML documents returned with filterlog.

Features added in goUCS version 2.0?

  • LINUX / MAC OS X SUPPORT: Ported goUCS to support Mac OS X and Linux (Red Hat and Ubuntu tested and supported).  All features implemented in goUCS version 2.0 are implemented to function across all supported operating systems as detailed in the goUCS version 2.0 README.
  • HTTPS COMMUNICATION: Added support for HTTPS communication to UCS Manager.
  • TAGGED BASED USER ARGUMENTS: Changed default behavior for user based arguments from positional arguments ($ARG1$ ... $ARGx$) to tagged based arguments ($NAME:ARG$). Positional based user arguments will be obsoleted as default behavior from goUCS version 2.0 forward, but goUCS still supports their usage to maintain backwards compatibility.
  • PERFORMANCE ENHANCEMENTS:   Re-engineered and re-coded to be nearly 100% Java based for cross platform portability.  goUCS version 2.0 commands generally execute much faster than the equivalent goUCS version 1.0 commands.
  • Plus many other new features that are documented in the goUCS version 2.0 README.


NOTE:  If you have any questions, problems, or find any bugs with the goUCS tool and / or documentation, please feel free to email goucs@cisco.com.  If you have created any XML or CMD wrappers that you would like to share on UCS Communities, please email goucs@cisco.com with a zip file that includes the XML and / or CMD wrapper with the appropriately documented help files and README.

 

DISCLAIMER:   goUCS is a proof of concept tool that has been posted as freeware on Cisco Developer Network with no warranty or formal support from Cisco.  Please use as a development tool only.  Use at your own risk, as it is NOT intended to be used in production.  Please refer to Cisco Developer Network forums for assistance in using this tool as well as any notification of any potential bugs encountered.  Feel free to edit <GOUCS_PATH>/lib/disclaimer.help to provide an appropriate disclaimer.