networktocode / ntc-netbox-plugin-onboarding

A plugin for NetBox to easily onboard new devices.
Other
245 stars 46 forks source link

Issue with connecting to NXOS #133

Closed Pzharyuk closed 3 years ago

Pzharyuk commented 3 years ago

Environment

Steps to Reproduce

  1. Add a new onboarding task
  2. Include all of the details about the device, IP, username, password, platform etc...

Expected Behavior

The device is successfully added since I specify all of the parameters and I am able to SSH into the device with the exact same username and password directly.

Observed Behavior

This is what actually happens when I run it... OnboardException: fail-login: ERROR: Authentication to device failed. Common causes of this problem are: 1. Invalid username and password 2. Incorrect SSH-key file 3. Connecting to the wrong device Device settings: autodetect 172.16.2.200:22 Authentication failed

Pzharyuk commented 3 years ago

image

Here's a picture of the job.

Small correction...

When I only specify the ip and let NAPALM to figure out the rest, I get the OnboardException: fail-login: ERROR: Authentication to device failed. Common causes of this problem are: 1. Invalid username and password 2. Incorrect SSH-key file 3. Connecting to the wrong device Device settings: autodetect 172.16.2.200:22 Authentication failed but if I specify all of the parameters I get Cannot connect to 172.16.2.200 you can see both in the image...

netvoip commented 3 years ago

I had this problem too. Solved by setting napalm driver to "nxos_ssh" since "nxos" is trying to connect to 443 port.

mzbroch commented 3 years ago

Nautobot documentation provides information about API and cli based onboarding: https://github.com/nautobot/nautobot-plugin-device-onboarding#ssh-autodetect

Auto discovery works only for SSH based platforms and napalm drivers. Other cases, like HTTPs APIs are still possible with NAPALM however require some additional steps as described in Nautobot's documentation.