Cisco UCS powershell command recording how to with Cisco UCS PowerTool

Cisco UCS is the market leading blade technology right now. With UCS you are able to virtualize your hardware by abstracting components like HBAs, NICs, BIOS or even MAC and WWPN addresses. Every relevant component is configured in policies and bundled to service profiles. In this post I don’t want to tell the details around UCS as there are more than enough blog posts out there in the World Wide Web. I want to show you a very nice tool which can help you a lot in installing and configuring a UCS environment.

For Cisco UCS there is a Cisco UCS PowerTool available which is extremely powerful. With my experience I would say you’re able to execute about 90% of the administration tasks on the toolkit. But I don’t want to talk about the possibility to use a powershell toolkit as most of the enterprise vendors deliver some kind of powershell integration. With the toolkit you are able to record your clicks in the UCS manager. You may ask why this is a benefit. By recording the clicks you will get a full export of all your settings in a powershell format. Meaning you can configure a UCS once and then reuse the most common commands for the next one to finish the work much faster. You can download the toolkit with your Cisco login under the following link: https://communities.cisco.com/docs/DOC-37154

How does it look like?

First open the PowerTool.
2015-09-23 16_33_03-192.168.178.214 - Remote Desktop Connection

After you open the Cisco UCS PowerTool there is a command called
“Connect-Ucs”. With this command you connect the powershell toolkit to your UCS manager:
2015-09-23 16_33_12-192.168.178.214 - Remote Desktop Connection
2015-09-23 16_33_38-192.168.178.214 - Remote Desktop Connection

The following output shows how it looks like after you are connected:
2015-09-23 16_33_47-192.168.178.214 - Remote Desktop Connection
After you are connected to the UCS manager you can execute the command “ConvertTo-UcsCmdlet” to start recording:
2015-09-23 16_36_05-192.168.178.214 - Remote Desktop Connection

Right after that you can open your UCS manager. Now that your UCS manager is opened just try to configure a MAC address pool.
2015-09-23 16_42_20-192.168.178.214 - Remote Desktop Connection 2015-09-23 16_42_54-192.168.178.214 - Remote Desktop Connection

As soon as your pool is created you will see the powershell command which is needed to create the tool by cli on the open powershell window. Just copy and paste the line to a editor and safe it for later. With that functionality you can build up a script for a base configuration of UCS very quickly. So it becomes quite easy to install and configure new systems or even create new pools or adapter.

By using powershell you can eliminate problems like wrong names or different configurations on different systems very easily and at the end you have a documentation where you can see at any time what was executed.

TIP: User the UCS emulator to create your scripts. It can be found here: https://communities.cisco.com/docs/DOC-37827

I hope this post helps you in your daily business.

 

Advertisements

Leave a Reply

Fill in your details below or click an icon to log in:

WordPress.com Logo

You are commenting using your WordPress.com account. Log Out / Change )

Twitter picture

You are commenting using your Twitter account. Log Out / Change )

Facebook photo

You are commenting using your Facebook account. Log Out / Change )

Google+ photo

You are commenting using your Google+ account. Log Out / Change )

Connecting to %s