10-21-2019
06:56 AM
- last edited on
03-09-2022
11:08 PM
by
smallbusiness
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
Solved! Go to Solution.
10-25-2019 08:11 AM
(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$
10-25-2019 08:11 AM
(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$
10-27-2019 06:59 AM
Thanks a lot, from your snippet's prompt, i found that i missed activating the python virtual environment for xe consumer.
Discover and save your favorite ideas. Come back to expert answers, step-by-step guides, recent topics, and more.
New here? Get started with these tips. How to use Community New member guide