cancel
Showing results for 
Search instead for 
Did you mean: 
cancel
1601
Views
5
Helpful
2
Replies

Streaming Telemetry

Ubuntu machine in devnet_sandox Streaming telemetry  is missing netconf packages for connection to the cisco ios xe devices and subscribe to the device.

When running the script # python /home/telemetry/telemetry_stacks/consumers/xe/kafka_telemetry.py

i get the error says No module named ncclient

Thanks in advance  to install the missing package and its dependencies

1 Accepted Solution

Accepted Solutions

I think as you are running this arbitrarily the python modules aren’t resolving. I test this now, please see below
 
 
(xe-GaNVPkqR) telemetry@telemetryubuntu:~/telemetry_stacks/consumers/xe$ ls
kafka_telemetry.py  Pipfile  Pipfile.lock  print_telemetry.py
(xe-GaNVPkqR) telemetry@telemetryubuntu:~/telemetry_stacks/consumers/xe$ python kafka_telemetry.py
No handlers could be found for logger "ncclient.operations.subscribe"
Subscription Result : notif-bis:ok
Subscription Id     : 2147483649
Subscription Result : notif-bis:ok
Subscription Id     : 2147483650
Subscription Result : notif-bis:ok
Subscription Id     : 2147483651
{1: <?xml version="1.0" encoding="UTF-8"?>
<rpc-reply xmlns="urn:ietf:params:xml:ns:netconf:base:1.0" message-id="urn:uuid:a106617a-95bb-4285-9a86-e217fc84f7c5"><subscription-result xmlns='urn:ietf:params:xml:ns:yang:ietf-event-notifications' xmlns:notif-bis="urn:ietf:params:xml:ns:yang:ietf-event-notifications">notif-bis:ok</subscription-result>
<subscription-id xmlns='urn:ietf:params:xml:ns:yang:ietf-event-notifications'>2147483649</subscription-id>
</rpc-reply>, 2: <?xml version="1.0" encoding="UTF-8"?>
<rpc-reply xmlns="urn:ietf:params:xml:ns:netconf:base:1.0" message-id="urn:uuid:357c4d8e-2647-4d96-8843-e0f2586dff83"><subscription-result xmlns='urn:ietf:params:xml:ns:yang:ietf-event-notifications' xmlns:notif-bis="urn:ietf:params:xml:ns:yang:ietf-event-notifications">notif-bis:ok</subscription-result>
<subscription-id xmlns='urn:ietf:params:xml:ns:yang:ietf-event-notifications'>2147483650</subscription-id>
</rpc-reply>, 3: <?xml version="1.0" encoding="UTF-8"?>
<rpc-reply xmlns="urn:ietf:params:xml:ns:netconf:base:1.0" message-id="urn:uuid:343e5f00-8003-40d5-9ae5-e0cf4ff973ad"><subscription-result xmlns='urn:ietf:params:xml:ns:yang:ietf-event-notifications' xmlns:notif-bis="urn:ietf:params:xml:ns:yang:ietf-event-notifications">notif-bis:ok</subscription-result>
<subscription-id xmlns='urn:ietf:params:xml:ns:yang:ietf-event-notifications'>2147483651</subscription-id>
</rpc-reply>}
^C(xe-GaNVPkqR) telemetry@telemetryubuntu:~/telemetry_stacks/consumers/xe$ pip freeze | grep ncc
ncclient==0.6.0
(xe-GaNVPkqR) telemetry@telemetryubuntu:~/telemetry_stacks/consumers/xe$

 

Please mark this as helpful or solution accepted to help others
Connect with me https://bigevilbeard.github.io

View solution in original post

2 Replies 2

I think as you are running this arbitrarily the python modules aren’t resolving. I test this now, please see below
 
 
(xe-GaNVPkqR) telemetry@telemetryubuntu:~/telemetry_stacks/consumers/xe$ ls
kafka_telemetry.py  Pipfile  Pipfile.lock  print_telemetry.py
(xe-GaNVPkqR) telemetry@telemetryubuntu:~/telemetry_stacks/consumers/xe$ python kafka_telemetry.py
No handlers could be found for logger "ncclient.operations.subscribe"
Subscription Result : notif-bis:ok
Subscription Id     : 2147483649
Subscription Result : notif-bis:ok
Subscription Id     : 2147483650
Subscription Result : notif-bis:ok
Subscription Id     : 2147483651
{1: <?xml version="1.0" encoding="UTF-8"?>
<rpc-reply xmlns="urn:ietf:params:xml:ns:netconf:base:1.0" message-id="urn:uuid:a106617a-95bb-4285-9a86-e217fc84f7c5"><subscription-result xmlns='urn:ietf:params:xml:ns:yang:ietf-event-notifications' xmlns:notif-bis="urn:ietf:params:xml:ns:yang:ietf-event-notifications">notif-bis:ok</subscription-result>
<subscription-id xmlns='urn:ietf:params:xml:ns:yang:ietf-event-notifications'>2147483649</subscription-id>
</rpc-reply>, 2: <?xml version="1.0" encoding="UTF-8"?>
<rpc-reply xmlns="urn:ietf:params:xml:ns:netconf:base:1.0" message-id="urn:uuid:357c4d8e-2647-4d96-8843-e0f2586dff83"><subscription-result xmlns='urn:ietf:params:xml:ns:yang:ietf-event-notifications' xmlns:notif-bis="urn:ietf:params:xml:ns:yang:ietf-event-notifications">notif-bis:ok</subscription-result>
<subscription-id xmlns='urn:ietf:params:xml:ns:yang:ietf-event-notifications'>2147483650</subscription-id>
</rpc-reply>, 3: <?xml version="1.0" encoding="UTF-8"?>
<rpc-reply xmlns="urn:ietf:params:xml:ns:netconf:base:1.0" message-id="urn:uuid:343e5f00-8003-40d5-9ae5-e0cf4ff973ad"><subscription-result xmlns='urn:ietf:params:xml:ns:yang:ietf-event-notifications' xmlns:notif-bis="urn:ietf:params:xml:ns:yang:ietf-event-notifications">notif-bis:ok</subscription-result>
<subscription-id xmlns='urn:ietf:params:xml:ns:yang:ietf-event-notifications'>2147483651</subscription-id>
</rpc-reply>}
^C(xe-GaNVPkqR) telemetry@telemetryubuntu:~/telemetry_stacks/consumers/xe$ pip freeze | grep ncc
ncclient==0.6.0
(xe-GaNVPkqR) telemetry@telemetryubuntu:~/telemetry_stacks/consumers/xe$

 

Please mark this as helpful or solution accepted to help others
Connect with me https://bigevilbeard.github.io

Thanks a lot, from your snippet's prompt, i found that i missed activating the python virtual environment for xe consumer.