SD-WAN

 View Only
last person joined: 5 days ago 

Ask questions and share experiences with SD-WAN and Session Smart Router (formerly 128T).
  • 1.  Looking for GraphQL query for peer path

    Posted 11-03-2022 09:40
    Hi Team,

    We are looking for GraphQL query for show peer router RouterName details PCLI command.
    Appreciate the help.

    Thanks,
    Bhaskar.

    ------------------------------
    BHASKAR GADDAM
    ------------------------------


  • 2.  RE: Looking for GraphQL query for peer path

     
    Posted 12-02-2022 09:28
    Hi Bhaskar,

    Not sure if I get this correctly, but in order to get peers of particular router you can use this GraphQL query:
    query MyQuery {
      allRouters(name: "TA-DC-Router") {
        nodes {
          peers {
            totalCount
            nodes {
              routerName
              paths {
                addresses
                adjacentAddress
                adjacentDeviceInterface
                adjacentHostname
                adjacentNetworkInterface
                adjacentNetworkInterfaceDescription
                adjacentNode
                deviceInterface
                enabled
                isActive
                jitter
                latency
                loss
                mos
                mtu
                networkInterface
                node
                status
                uptime
              }
            }
          }
        }
      }
    }​

    You can parametrise the Router Name.

    The response would be like this:
    {
      "data": {
        "allRouters": {
          "nodes": [
            {
              "peers": {
                "totalCount": 3,
                "nodes": [
                  {
                    "routerName": "srx1",
                    "paths": [
                      {
                        "addresses": [
                          "46.31.118.17"
                        ],
                        "adjacentAddress": "23.20.51.203",
                        "adjacentDeviceInterface": null,
                        "adjacentHostname": null,
                        "adjacentNetworkInterface": null,
                        "adjacentNetworkInterfaceDescription": null,
                        "adjacentNode": null,
                        "deviceInterface": "WAN1",
                        "enabled": true,
                        "isActive": true,
                        "jitter": null,
                        "latency": null,
                        "loss": null,
                        "mos": null,
                        "mtu": null,
                        "networkInterface": "WAN1",
                        "node": "node1",
                        "status": "DOWN",
                        "uptime": null
                      }
                    ]
                  },
                  {
                    "routerName": "vsrx-222",
                    "paths": [
                      {
                        "addresses": [
                          "46.31.118.17"
                        ],
                        "adjacentAddress": "212.5.51.138",
                        "adjacentDeviceInterface": null,
                        "adjacentHostname": null,
                        "adjacentNetworkInterface": null,
                        "adjacentNetworkInterfaceDescription": null,
                        "adjacentNode": null,
                        "deviceInterface": "WAN1",
                        "enabled": true,
                        "isActive": true,
                        "jitter": 0,
                        "latency": 0,
                        "loss": 100,
                        "mos": 100,
                        "mtu": null,
                        "networkInterface": "WAN1",
                        "node": "node1",
                        "status": "UP",
                        "uptime": 37904200
                      }
                    ]
                  },
                  {
                    "routerName": "TA-Branch-SSR",
                    "paths": [
                      {
                        "addresses": [
                          "46.31.118.17"
                        ],
                        "adjacentAddress": "78.163.168.230",
                        "adjacentDeviceInterface": null,
                        "adjacentHostname": null,
                        "adjacentNetworkInterface": null,
                        "adjacentNetworkInterfaceDescription": null,
                        "adjacentNode": null,
                        "deviceInterface": "WAN1",
                        "enabled": true,
                        "isActive": true,
                        "jitter": 2,
                        "latency": 21,
                        "loss": 0,
                        "mos": 439,
                        "mtu": 1492,
                        "networkInterface": "WAN1",
                        "node": "node1",
                        "status": "UP",
                        "uptime": 86804137
                      }
                    ]
                  }
                ]
              }
            }
          ]
        }
      }
    }​


    Hope it helps.

    Cheers,
    Ivan



    ------------------------------
    Ivan Stanev
    ------------------------------