Telemetry

You are currently browsing articles tagged Telemetry.

ANX(Advanced NETCONF Explorer) 是一个cisco开源软件, 发布如下github上,能帮助我们快速的查找一些sensor path, 做一些telemetry的实验, 具体的安装步骤可参考github主页。

https://github.com/cisco-ie/anx

安装

[root@xuxing239 ~]# git clone https://github.com/cisco-ie/anx
[root@xuxing239 ~]# cd anx/
[root@xuxing239 anx]# docker build -t netconf-explorer .
[root@xuxing239 anx]# docker run --name netconf-exlorer -d -p 9269:8080 netconf-explorer
[root@xuxing239 anx]# docker ps
CONTAINER ID   IMAGE              COMMAND                  CREATED      STATUS      PORTS                    NAMES
34cd21044420   netconf-explorer   "/usr/share/jetty9/b…"   3 days ago   Up 3 days   0.0.0.0:9269->8080/tcp   netconf-exlorer
[root@xuxing239 anx]# 
Read the rest of this entry »

Tags:

Telemetry 是一种类似SNMP技术的feature,用于远程采集网络设备上相关信息。与SNMP不同的是,SNMP是Pull Mode,需要server端主动的要求Get某些信息,而Telemetry则是一种Push Mode,可以周期性、主动的push相关信息到server上。SNMP是秒级的数据采集, 而Telemetry可以实现毫秒级的数据采集.

如何获得相应的sensor-path

与SNMP的OID类似,sensor-path代表着你想要的获得哪些信息,在XR设备上我们可以使用如下命令去判断我们需要获得的信息是哪一类,即获得关键字;然后到yang文件夹过滤相关关键字:

RP/0/RSP1/CPU0:9910-B#schema-describe show segment-routing traffic-eng forwarding policy name test-policy detail
Fri Dec 27 01:57:38.336 UTC
Action: get
Path:   RootOper.XTC.PolicyForwarding   <<< XTC

RP/0/RSP1/CPU0:9910-B#run
Fri Dec 27 01:57:42.449 UTC
[xr-vm_node0_RSP1_CPU0:~]$cd /pkg/yang/
[xr-vm_node0_RSP1_CPU0:/pkg/yang]$ls | grep xtc      <<<cfg代表配置相关,oper与show command相关
Cisco-IOS-XR-infra-xtc-agent-cfg.yang
Cisco-IOS-XR-infra-xtc-agent-oper-sub1.yang
Cisco-IOS-XR-infra-xtc-agent-oper-sub2.yang
Cisco-IOS-XR-infra-xtc-agent-oper.yang
Cisco-IOS-XR-infra-xtc-cfg.yang
Cisco-IOS-XR-infra-xtc-oper-sub1.yang
Cisco-IOS-XR-infra-xtc-oper.yang

//有用的文件:
RP/0/RP0/CPU0:XTC#run
Tue Jan 22 06:58:56.512 UTC
[xr-vm_node0_RP0_CPU0:~]$cd /pkg/telemetry/mdt/protogen
[xr-vm_node0_RP0_CPU0:/pkg/telemetry/mdt/protogen]$ls
yang_to_schema.txt

接下来就需要自己去yang文件中找一些关键词,自己把sensor path组合起来.

当然有更好的方法,可以参考我另一篇文章 ANX

Read the rest of this entry »

Tags: