Cisco Systems 4.1 Dust Collector User Manual


 
19-88
User Guide for Resource Manager Essentials 4.1
OL-11714-01
Chapter 19 CLI Utilities
CWCLI
Example 3: Exporting device credentials of all RME devices using cwcli get request method
The password that you enter here must be in base64 encoded.
In this example,
YWRtaW4= is the base64 encoded password for admin.
%25 is the URL encode for “%”
Enter this in your browser:
http://ciscowork_servername:1741/rme/cwcli?command=cwcli inventory crmexport -u admin -p
YWRtaW4= -
device %25 -filetype xml
-filename getxml
The output is written in the getxml file. The getxml file is located:
On Windows:
NMSROOT\MDC\tomcat
Where, NMSROOT is the CiscoWorks installed directory.
On Solaris:
/opt/CSCOpx/objects/dmgt
Example 4: Exporting device credentials of all RME devices using cwcli post request method
The password that you enter here must be in base64 encoded. In this example, YWRtaW4= is the base64
encoded password for admin.
The payload file, crmexport.xml contains:
<payload>
<command>
cwcli inventory crmexport -u admin -p YWRtaW4= -device 10.66.162.208 -filetype xml
-filename /opt/CSCOpx/crmexport-xml
</command>
</payload>
At the command prompt enter:
perl samplepost.pl http://ciscowork_servername:1741/rme/cwcli crmexport.xml
To invoke the servlet using a script, see the Sample Script to Invoke the Servlet.
SUMMARY
========
Successful: Export: Success
The RME device credentials are exported into a file, crmexport-xml in XML format. This file is created
in the /opt/CSCOpx directory. By default, the specified file is created in this location:
On Windows:
NMSROOT\MDC\tomcat
Where, NMSROOT is the CiscoWorks installed directory.
On Solaris:
/opt/CSCOpx/objects/dmgt