Last active
January 12, 2018 02:08
-
-
Save ksator/1e513cf0079efe243f7d177a4cd1aefc to your computer and use it in GitHub Desktop.
pass an rpc with an arg to Junos using pyez
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
from lxml import etree | |
from jnpr.junos import Device | |
dev=Device(host="172.30.54.108", user="lab", password='m0naco') | |
dev.open() | |
result=dev.rpc.get_interface_information(level_extra="descriptions") | |
type(result) | |
print (etree.tostring(result)) | |
etree.dump(result) | |
dev.close() |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
How to get the equivalent rpc for
show interface description | display xml