-
. |
Beta Was this translation helpful? Give feedback.
Answered by
ktbyers
Jan 6, 2021
Replies: 2 comments 2 replies
-
I would probably make a custom Nornir task similar to this: def netmiko_direct(task):
list_of_commands = ["show ip int brief", "show ip arp"]
# Manually create Netmiko connection
net_connect = task.host.get_connection("netmiko", task.nornir.config)
results_dict = {}
for cmd in list_of_commands:
output = net_connect.send_command(cmd)
results_dict[cmd] = output
# You also could make a more formal Nornir Results object
return results_dict |
Beta Was this translation helpful? Give feedback.
2 replies
Answer selected by
dbarrosop
-
Hi Kirk, Did you get an answer for your comment on Jan 13th 2021? I too want to know how to execute multiple show commands for each device. One output per device. |
Beta Was this translation helpful? Give feedback.
0 replies
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
I would probably make a custom Nornir task similar to this: