Exec Cli Model - Cisco ASR 5500 System Administration Manual

Hide thumbs Also See for ASR 5500:
Table of Contents

Advertisement

NETCONF and ConfD
</file>
<file>
</file>
</bulkstats-operational>

Exec CLI Model

The following examples use the Exec CLI model.
Using Curl to Obtain the 'show version' Output
See below for a sample use of curl to obtain the show version output:
cat exec_cli_show_version.xml
<input><args>show version</args></input>
************
[<user>@server] ]$ curl -u admin:pswd!
https://rtp-mitg-si06.cisco.com:234/api/running/staros_exec/_operations/exec --cert
/users/<user>/ssl_cert/client_cert/client.crt --key
/users/<user>/ssl_cert/client_cert/client.key --cacert
/users/<user>/ssl_cert/root_cert/rootCA.pem -X POST -T ./exec_cli_show_version.xml
<output xmlns='http://www.cisco.com/staros-exec'>
<result>Active Software:
Image Version:
Image Build Number:
Image Description:
Image Date:
Boot Image:
Source Commit ID:
</result>
</output>
Using Curl to Obtain Multiple Show Command Outputs
See below for a sample use of curl to obtain the show build and show confdmgroutputs, using "\r\n" as the
delimiter between commands:
cat exec_cli_show_build_and_confdmgr.xml
<input><args>show build \r\n show confdmgr</args></input>
************
[<user>@server] ]$ curl -u admin:pswd!
https://rtp-mitg-si06.cisco.com:234/api/running/staros_exec/_operations/exec --cert
</variable>
</key_ids>
</names>
</schemas>
<number>2</number>
<schemas>
<schema>system</schema>
<names>
<name>system</name>
<key_ids>
<key_id>none</key_id>
<variable>
<name>host</name>
<value><host_name></value>
</variable>
<variable>
<name>ipaddr</name>
<value>1.2.3.4</value>
</variable>
<variable>
<name>uptime</name>
<value>5781</value>
</variable>
</key_ids>
</names>
</schemas>
21.2.M0.private
private
Developer_Build
Thu Feb 23 15:25:47 EST 2017
/flash/qvpc-si.bin.confd
bd234043a93c68873ea77444733a8c632356d161
ASR 5500 System Administration Guide, StarOS Release 21.5
Exec CLI Model
357

Advertisement

Table of Contents
loading

Table of Contents