Archive

标签为 ‘Yang’的文章

New install NSO and Connect with XR by CLI/Netconf NED

Not update any NSO article to my blog, I will put more NSO info to here, wish that will help more guys. The article will include more hands-on experiences, help beginner fast connect xr devices with nso by cli or netconf ned. For netcong NED, build by Pioneer at former, that need to manual exclude the Yang file that no support. In the article, will build netconf ned by native tool of NSO 5.2.0.

Platform Info

[root@nso opt]# ncs --version
5.2.0.1
[root@nso opt]# cat /etc/redhat-release 
CentOS Linux release 7.6.1810 (Core) 
RP/0/RP0/CPU0:frank#show ins ac sum
Wed Aug  7 01:53:03.286 UTC
    Active Packages: 1
        xrv9k-xr-6.6.3.14I version=6.6.3.14I [Boot image]

完整阅读

How To Get Telemetry sensor path for show cmd on IOS XR?

When we want to collect some show information by Telemetry, we will face the 1st question that how to find the correct/resolved sensor path. The first step often traps us. Is there any good way to easily find the sensor path? The answer is “Yes”. I had summarized a way that can help you quickly find the sensor path.

Before read the article,there is a file that mapping between YANG and Sensor Path in XR, you can check by keyword(e.g fan, cpu and so on) first, if not found, then check my article.

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
[xr-vm_node0_RP0_CPU0:/pkg/telemetry/mdt/protogen]$

yang_to_Schema.txt has all yang path to xml schema path maps. https://github.com/AlexFengCisco/Telemetry_Receiver

完整阅读

Install/Use Yangsuite by Docker

Cisco finally published the YangSuit at Devnet at Feb 2021, that can be downloaded and used by customer, and it is Free! I updated the installation section of the article to use the public version, other section should similar and not update.

Cisco YANG Suite provides a set of tools and plugins to learn, test, and adopt YANG programmable interfaces such as NETCONF, RESTCONF, gNMI and more.

YANG Suite will provides network operators with a common tool to interact with Cisco IOS XE, IOS XR, and the NX-OS Network Operating Systems as they look to modernize their network management and migrate from traditional network management tools.

https://developer.cisco.com/yangsuite/?utm_campaign=yang21&utm_source=social&utm_medium=dntwitter-yang-ww

Install

xxx:~ xxx$ git clone https://github.com/CiscoDevNet/yangsuite
xxx:~ xxx$ cd yangsuite/docker/ ; ./gen_test_certs.sh
xxx:docker xxx$ pwd
/Users/xxx/yangsuite/docker
xxx:docker xxx$ docker-compose up
Creating network "docker_default" with the default driver
Creating volume "docker_static-content" with default driver
Creating volume "docker_uwsgi" with default driver
Building yangsuite
……
完整阅读

How to get correct Yang configuration on ASR9k

Now some customer test netconf-yang on our XR platform. And frequency to check how to get correct yang config(XML), then they test the yang config by their controller to touch with our devices. Now there are several ways to achieve that, summed up to facilitate review:

Commit follow cmd:

netconf-yang agent ssh
ssh server v2
ssh server rate-limit 300
ssh server netconf vrf default
ssh server logging

Generate key:

#crypto key generate dsa
—————————————————

 

  • We can ssh 830 to asr9k paltform, then get the configuration, that should correct yang config, you can reference attachment at test-xml-by-ssh.txt
ssh [email protected] -p 830 -s netconf
  • We can build Netconf NED by pioneer in NSO, then sync-from devices, and “devices device 9001-A compare-config outformat xml”, that should correct yang config
  • After install NSO, we can use follow tools to achieve that function too
netconf-console -u cisco -p cisco --host 10.75.49.53 --port 831 --get-config

 

Btw, please attention “-” and “–” that maybe cause command issue.

blonde teen swallows load.xxx videos