PowerTool Cmdlet Generation
The ConvertTo-UcsCentralCmdlet enables you to learn about the PowerTool cmdlets that performs configuration action by generating the cmdlet in one of the following ways:
- Performing actions in GUI
- From a backup file
- From a UCS Central PowerShell object
Generate Cmdlets From UCS Central GUI Actions
Before you begin
- Install Flash Debugger (not flash player) for your web browser. You can download the software from this URL: https://www.adobe.com/support/flashplayer/downloads.html
Note
Flash debuggers are different for different browsers. For example, Internet Explorer has a different flash debugger than Mozilla Firefox.
- Configure mm.cfg file located under user directory. For example, if there is a username demoUser on the windows system, the file is located in the "C:\Users\demoUser" path. This file provides instructions to the Flash Debugger about settings related to log dumping. Modify the following properties as:
ErrorReportingEnable=1
TraceOutputFileEnable=1
If there is no mm.cfg file, you can create one and follow the link to editor configure mm.cfg file:
http://helpx.adobe.com/flash-player/kb/configure-debugger-version-flash-player.html
Procedure
Step 1 |
After the UCS Central GUI launches, at the login page, press Ctrl + Alt + Shift+L. The Logger Console flash popup is displayed. Modify the logger preferences as follows:
|
||
Step 2 |
Enter the username and password for UCS Central and log on to UCS Central. A log file is created in the log file location depending on the OS. For more information on the exact location of the log files, see https://helpx.adobe.com/flash-player/kb/configure-debugger-version-flash-player.html. The name of the log file is the name mentioned in the property TraceOutputFileName in mm.cfg. If this property does not exist, the name is flashlog.txt.
|
||
Step 3 |
Launch UCS Central PowerTool and run the ConvertTo-UcsCentralCmdlet. This cmdlet monitors the configuration logs in the log file. |
||
Step 4 |
Perform operations in the GUI. The cmdlets for actions performed in the web UI is generated in the PowerTool console. |
For Google Chrome Users
Perform the following steps to disable the integrated flash player and to install the flash debugger:
Procedure
Step 1 |
Install Flash debugger that is compatible with the Netscape browser. |
Step 2 |
Select chrome://plugins and click the "[+] Details" icon, located at the top right corner of the screen. |
Step 3 |
Search for the Shockwave Flash or Flash option. |
Step 4 |
Disable the integrated version installed under the Chrome directory on your local machine. For example, C:\Program Files (x86)\Google\Chrome\Application\39.0.2171.71\PepperFlash\pepflashplayer.dll |
Step 5 |
Enable the Netscape compatible Flash Debugger which you installed in the Systems directory on your local machine. For example, C:\Windows\SysWOW64\Macromed\Flash\NPSWF32_15_0_0_239.dll. |
Step 6 |
Restart the Google Chrome browser. |
Generate Cmdlets from UCS Central HTML GUI
Procedure
Step 1 |
Open UCS Central Web UI. |
Step 2 |
From the Setting icon, select Start Logging Session to enable logging. Perform the operations in the web UI. |
Step 3 |
From the Setting icon, select Stop Logging Session to stop the session. |
Step 4 |
Click Save at the prompt to save the logs in a file on your local system.
|
Step 5 |
Launch UCS Central PowerTool and run the ConvertTo-UcsCentralCmdlet.
|
Generate Cmdlets From Backup file
The following example is used to generate cmdlet from a backup file.
Generate cmdlets from backup file:
ConvertTo-UcsCentralCmdlet
-UcsCentralBackup -LiteralPath "C:\central-mgr.xml" -OutputPath
"C:\central-mgr.txt"
Generating Cmdlets From UCS Central PowerShell Object
Generate the cmdlets through piping the UCS Central objects from a Get cmdlet to the ConvertTo cmdlet. In the following example, ConvertTo cmdlet generates the cmdlets required to re-create the 'testSP' service profile object.
Generate cmdlets for the specified managed object
Get-UcsCentralServiceProfile
-Name testSP | ConvertTo-UcsCentralCmdlet