Ethernet Switches & Routers

Reply
New Contributor
Posts: 2
Registered: ‎07-16-2012

Unable to overwrite or clear $$sshpub.key on FCX Switch

Hello all,

I'm trying to overwrite a public key file on one of our FCX648S switches, but when I attempt to do so, it is coming up with the error below. Attempts to clear the public key are also unsuccessful. I've attempted the following

SSH@idf3(config)#ip ssh pub-key-file tftp 10.20.123.234 pubkeys/pkeys.txt

downloading public key file, please wait...

SSH@idf3(config)#Done.

Cannot write to ssh public key file $$sshpub.key.

ERROR: failed to write ssh client pub key to file $$sshpub.key

SSH@idf3(config)#clear public-key

SSH@idf3(config)#show dir

      1740 $$sshhost.key

       816 $$sshpub.key

         0 bootrom

   4869049 primary

   4866666 secondary

       163 stacking.boot

      7167 startup-config

      7077 startup-config.backup

   9752678 bytes 8 File(s)

  54394880 bytes free


Perhaps helpful to know is that when the public key file was first downloaded from a TFTP server, it was formatted incorrectly as follows:



SSH@idf3#copy flash console $$sshpub.key

---- BEGIN SSH2 PUBLIC KEY ----

ssh-rsa AAAAB3NzaC1yc2EAAAADAQABAAACAQCyYJNvVQIykYyjL5sPkbfavCyzetgXqd/h9mXz9E6JX31GsrtMuudTFz+lErKFpMxxmVc+SsMiX+qJhzd7T3wrUIAg4zml+brAteqb4GxHdx15UMBYqt2H091+OqfrWm5V0cv9PY/APAlmOVOXvi7KLCKLtgfU/WNQgb8ktCJg6DS6Df9AfhAHJX/DdVvyjucXdTMfH+S+j89Ae5qRsJ9dTgOC

skwUHWZ1i2QonWBDDZUOR8pJ4AiuxnmEhFaK2nnSjBZcCq/TJTJ7EilmX9+dm5VQbrqdcUXCDT7o2hLZdYjRPCKe/I9Ii5mjcg9Ll8YlQBv/hBPbLppLVHmDrTcK9DYGC6nm/zrQhPJQcGUcJPXWrWY7y2o54U0v/nURfXJWK7RMBSm2uDWtStvVofLW3YXabe2gJpKT826WHrWmAnr8Z+efrthEGQTpC3j1GfKlKNZuEitPX8ytlnyZ004Wb5ex

4dJjFY7uMHS43Myv4daP8RxiwM0bxuhcPaTHle5HmFR2je0saeOI74Rub+A5bPGTR5W2eSoqBm1oU7fsloErJvTLJAfP5DyEgn4Xw16TkGH7tuojrtmnXnt908HZVkDX05AXv6iBXsgzox1JjLrjyWFLfRwznLfdyTExt553RLmtz6d0/IZmylcmAyipL3Mll+yffXv994mrqbAw== ted@teds-Macmini.local

---- END SSH2 PUBLIC KEY ----


Any help with removing or overwriting the public key file is greatly appreciated.

Super Contributor
Posts: 1,087
Registered: ‎12-13-2009

Re: Unable to overwrite or clear $$sshpub.key on FCX Switch

Hmm not sure, would suggest you try this from the console.  Not sure it will let change the ssh key while you are SSH into the back.

If that still does not works.  then suggest you turn off SSH access and try again and reenable SSH if that works.

Thanks

Michael.

New Contributor
Posts: 2
Registered: ‎07-16-2012

Re: Unable to overwrite or clear $$sshpub.key on FCX Switch

Thanks for your help.

We let this problem sit for a while, and it resolved itself after a code upgrade to FCXS07400.bin. I'm assuming that it was the warm reload as part of the upgrade that fixed it.

Join the Community

Get quick and easy access to valuable resource designed to help you manage your Brocade Network.