API call for virtual router run time stats

Reply
L0 Member

API call for virtual router run time stats

Does anyone have the API call equivalent for this:

https://<panorama-host>/php/utils/router.php/NetworkDirect.getVirtualRouterRunTimeStats

 

TIA

L4 Transporter

Re: API call for virtual router run time stats

Most of this info is reflected somewhere in the API. What specifically are you looking for?

L0 Member

Re: API call for virtual router run time stats

I want to context switch ( I think that means use the &target=device_serial_number) to a specific firewall appliance and ask it for its routing table, forwarding table.  In the UI its is on the display of a specific virtual router, then click 'More Run Time Stats'.  Within that window 'Routing' tab, then 'Forwarding' tab.

L4 Transporter

Re: API call for virtual router run time stats

So the context switching would apply to operational API commands that would normally appear on the firewall. So instead of making the API call to the firewall, as you mentioned you provide the target serial number and the Panorama then forwards and returns to you the output of the operational command.

 

As far as to a UI view that shows runtime stats specifically, that wouldn't be what the API would be used for. However, there are commands that would show the routing and forwarding table which you can then leverage for the targeted redirection. They aren't presented in a UI as you see in the runtime though.

 

Those calls would be:

/api/?type=op&cmd=<show><routing><route></route></routing></show>

and

/api/?type=op&cmd=<show><routing><fib></fib></routing></show>
Like what you see?

Show your appreciation!

Click Like if a post is helpful to you or if you just want to show your support.

Click Accept as Solution to acknowledge that the answer to your question has been provided.

The button appears next to the replies on topics you’ve started. The member who gave the solution and all future visitors to this topic will appreciate it!

These simple actions take just seconds of your time, but go a long way in showing appreciation for community members and the Live Community as a whole!

The Live Community thanks you for your participation!