Detailed in the video below is a joint PowerShell integration utilizing both Cisco UCS PowerTool and VMware PowerCLI. The goal of the integration is to show how easy it is in PowerShell to integrate across different functional areas within a virtualized infrastructure stack. By taking the power of managing UCS with UCS Powertool and coupling it with the power of managing VMware with PowerCLI an infrastructure administrator can fully automated configuration of a net-new cluster of hypervisors from bare metal in UCS to fully configured clusters in vSphere within minutes with very minimal script writing.
There was very minimal prework performed for both UCS and VMware in the environment being demoed in the video below. For UCS, the prework that was performed was racking, stacking, and cabling the physical UCS gear and performing an initial configuration of UCS manager. On the storage side, a 200 GB LUN was created and zoned to a range of 18 WWPN's as well. For VMware, vSphere and Auto-Deploy software were both installed and configured inside of a Windows 2008 R2 server that had DNS, DHCP, and TFTP installed and configured to best practices from VMware for Auto-Deploy.
From there, PowerShell utilizing the Cisco UCS PowerTool module and VMware PowerCLI snap-ins takes over!!! Three different scripts were created to perform the following functions:
Initial Configuration - The first scripts configures all of the pools, policies, VLANs, VSANs, Service Profile Templates, etc. needed on the UCS side to create new servers to be used in the cluster to be created in VMware. On the VMware side, this script will download the latest and greatest ESXi hypervisor, as well as create separate Auto-Deploy Hypervisor and Cluster rules that define the hypervisor version and destination cluster for net new servers with the Service Profile Template name provided in the oem strings like "oemstring=$SPT:CL2012", where CL2012 is the service profile template name. The script will create new service profile from a template, associate it with a server from a pool, monitor the progress of the association and addition of the host into the cluster, perform initial configuration of the new host in the cluster and create a host profile from the configuration, and create a rule for the cluster to use the new host profile. Download: https://communities.cisco.com/docs/DOC-36049
Addition of New Hypervisors - The second script is run to add new hypervisors to the cluster created in step one. This script accomplishs that by creating a new service profile from the template created in script one, associating it, and booting it which will cause the server to boot via AutoDeploy based on the autodeploy and cluster rules created from script one, which are triggered from the service profile template name. The script will verify the host is added to the cluster and is fully compliant with the host profile created in step one. Download: https://communities.cisco.com/docs/DOC-36046
Rolling Hypervisor and Server Firmware Upgrade of a Cluster - The third script will download the newest version of a ESXi hypervisor from VMware, create a new Auto-Deploy rule utilizing it for servers that are created from the Service Profile Template created in step one. Once the rules are updated, the script will loop through each hypervisor one by one in the cluster by first setting the hypervisor in maintenance which will trigger VM evacuation, shutting the hypervisor down, change the host firmware pack on the service profile which upgrades the firmware on the server, powering the server on which will cause the server to boot ESXi via Auto-Deploy and rejoin the cluster. Download: https://communities.cisco.com/docs/DOC-36050
These scripts are provided freely as examples of how you can use both UCS PowerTool and VMware PowerCLI together to achieve end to end automation. Please feel free to modify and utilize them as examples of how you might automate UCS and VMware in your own datacenter.
Hi Team, I am using secured environment where python code is working fine but after converting the code to .exe file using pyinstaller it giving below error. Code for connecting to pod from ucsmsdk.ucshandle import UcsHandlehandle = U...
I am getting the below error while running the plugin: ./cisco_imc_nagiosError occurred while trying to import IMC Python SDK. Check if you are using the latest IMC Python SDK. Else check IMC Python SDK install guide for further information. we ...
I'm trying to use the Python uscmsdk library; however it's failing at the login with the error "Not supported on server". The code I'm using is equivalent to: "from ucsmsdk.ucshandle import UcsHandle# Create a connection handle handle = UcsHandle(<...
UCS always recommends to keep vNIC MTU same as that of assigned QoS policy priority class value.
Below warning appears when you assign QoS policy to any vNIC.
When the QoS policy is not assigned to vNIC, it takes the best-efforts cl...
I'm trying to install the IMC plugin 0.9.4. I'm running Nagios Core 4.4.5. There doesn't seem to have been any posts on this in a while I'm wondering if the plugin will still work? The install guide is dated 2017. I'm looking to monitor a UCS C2...