10-21-2011
07:33 AM
- last edited on
03-25-2019
01:28 PM
by
ciscomoderator
Hello,
I tried to establish an preshared SSH key at an Nexus 7K using the procedure for Nx5K (because I didnt found for 7k)
But I always get an "invalid SSH key format" after binding the user to the key.
SCNexus7KA(config)# username admin sshkey bootflash:/pem1024.pub
invalid SSH key format
SCNexus7KA(config)# username admin sshkey bootflash:/pem2048.pub
invalid SSH key format
...
the same error with providing the key as LINE
finaly I checked it with using exact the same key as seen in this documentation and the system still returns:
"invalid SSH key format"
What is the right procudure and key-format to establish an preshared SSH key connection with Nexus 7K?
thx, Steffen
11-15-2011 08:22 PM
Have you looked at these documents?
http://www.cisco.com/en/US/docs/switches/datacenter/sw/4_1/nx-os/security/configuration/guide/sec_ssh.html#wp1060683
http://www.cisco.com/en/US/docs/switches/datacenter/sw/5_x/nx-os/configuration_examples/configuration/guide/Cisco_Nexus_7000_Series_NX-OS_Configuration_Examples_Release_5.x_chapter4.html#task_1060807
http://www.cisco.com/en/US/docs/switches/datacenter/sw/4_1/nx-os/security/configuration/guide/sec_ssh.html
Sent from Cisco Technical Support iPhone App
12-01-2011 05:58 AM
Problem is solved, it was at NX5K as well. Its mainly caused by a documentation bug:
2) Bind the sshkey to an existing nexus user. Take care that you exactly use the
first 2 words of the generated pubkey, allthough the key consists of 3 words:
Nexus7KA(config)# username admin sshkey ssh-rsa AAAAB3Nz...
Nexus7KA(config)# sh user-account admin
user:admin
this user account has no expiry date
roles:network-operator
ssh public key: ssh-rsa AAAAB3Nz....
Important hint: In the Cisco-SSH documentation you will see:
"username User1 sshkey ssh-rsa
AAAAB3Nz..."
That is no new-line. It is a blanc:
"ssh-rsa AAAAB3Nz…"
and caused by an unfortunate accident with auto wrap at the most important part
of the documentation.
Steffen
Gesendet: Mittwoch, 16. November 2011 05:23
An: Neuser, Steffen
Betreff: - Re: Nexus 7K, getting invalid SSH key format allways
Home<>>
Re: Nexus 7K, getting invalid SSH key format allways
created by anikas<> in Other Data Center Subjects - View the full discussion<>>>
Discover and save your favorite ideas. Come back to expert answers, step-by-step guides, recent topics, and more.
New here? Get started with these tips. How to use Community New member guide