Answered step by step
Verified Expert Solution
Question
1 Approved Answer
Use a while loop to indefinitely perform the following.. Prompt the user for port# Prompt the user for device _ type Connect to a device
Use a while loop to indefinitely perform the following..
Prompt the user for port#
Prompt the user for devicetype
Connect to a device and print the prompt
Use a try block to handle timeout and authentication exceptions, should also have a catch all exception for any unexpected exception.
Exception should print the type of exception that occurred.
device login script
devicelogin.py
a basic program to create an initial login to a cisco device
from netmiko import ConnectHandler
device
'devicetype': 'vyos',
ip:
'port':
'username': 'itsc
'password': itsc',
#create SSH socket to connect to device using the data in the library 'cisco'
netconnect ConnectHandlerdevice
promptnetconnect.findprompt
printprompt
Device Name Port Vendor DeviceType Type Model Username Password Inside IP Address
DLLSCOR VYOS vyos Router itscitsc
DLLSCOR VYOS vyos Router itscitsc
DLLSDIS VYOS vyos Router itscitsc
DLLSDIS VYOS vyos Router itscitsc
DLLSACC Extreme Networks extremeexos L Switch XSQ itscitsc
DLLSACC Extreme Networks extremeexos L Switch XSQ itscitsc
DLLSACC Extreme Networks extremeexos L Switch XSQ itscitsc
FTWCOR MikroTik mikrotikrouteros Router itscth itsc
FTWCOR MikroTik mikrotikrouteros Router itscth itsc
FTWDIS MikroTik mikrotikrouteros Router itscth itsc
FTWDIS MikroTik mikrotikrouteros Router itscth itsc
FTWACC Extreme Networks extremeexos L Switch XSQ itscitsc
FTWACC Extreme Networks extremeexos L Switch XSQ itscitsc
FTWACC Extreme Networks extremeexos L Switch XSQ itscitsc
Step by Step Solution
There are 3 Steps involved in it
Step: 1
Get Instant Access to Expert-Tailored Solutions
See step-by-step solutions with expert insights and AI powered tools for academic success
Step: 2
Step: 3
Ace Your Homework with AI
Get the answers you need in no time with our AI-driven, step-by-step assistance
Get Started