Загрузка...

Retrieve Router Facts Info using Python Napalm

A python code with Napalm library is built on Linux ubuntu desktop to connect to Huawei NE40 router, and get the output of get_facts API of Napalm which returns general information about the router.
///
Huawei Network Automation Playlist: https://www.youtube.com/playlist?list=PLc7T-rjcn-xXAJVP1HUldOncVfoH9pMgz
///
Links used in the video:
Napalm: https://napalm.readthedocs.io/en/latest/
Napalm community for Huawei on Github: https://github.com/napalm-automation-community/napalm-huawei-vrp
///
Additional Lab videos:
Enable SSH on NE40E router: https://youtu.be/8uSW3QrhPYw
Networking Ubuntu Linux with Huawei Routers: https://youtu.be/NzRw9UUW3is
Install Python 3.6, Netmiko, and Paramiko: https://youtu.be/1ATNbpyTpis
///
Our website: https://labsontrack.com/
We’re building IT and Datacom Network Digital Platform to explore new skills, deepen your hands-on experience, we deliver effective, efficient and quality training paired with real and rich experience to help you reach your learning goals.
See list of courses from here: https://labsontrack.com/all-courses/
///
Know more about us on this link: https://labsontrack.com/about/
///
Python script code:
#!/usr/bin/env python

from napalm import get_network_driver
import pprint

driver = get_network_driver('huawei_vrp')
device = driver(hostname='10.1.1.2', username='huawei', password = 'Hamdy@123')
device.open()

get_facts = device.get_facts()
pprint.pprint(get_facts)
print(get_facts['hostname'])
///
Video key moments:
00:04 Definition of Napalm
01:02 Lab Intro
01:49 Writing the python script
06:13 Running the script
07:01 Pprint
08:03: Separately Printing an item of a dictionary (hostname item)
///
Huawei NE40E
Router
Python 3
Napalm
Napalm get_facts()
Python dictionaries
Ubuntu Linux
Huawei IP Networks
Huawei Datacom
///
#networkautomation #python #ubuntulinux #hcie #hcip #huawei #router #routers #ip #network #networks #datacom

Видео Retrieve Router Facts Info using Python Napalm канала Labs On Track
Яндекс.Метрика
Все заметки Новая заметка Страницу в заметки
Страницу в закладки Мои закладки
На информационно-развлекательном портале SALDA.WS применяются cookie-файлы. Нажимая кнопку Принять, вы подтверждаете свое согласие на их использование.
О CookiesНапомнить позжеПринять