cancel
Showing results for 
Search instead for 
Did you mean: 

SCP2 from one switch to another with Public key authentication

SCP2 from one switch to another with Public key authentication

eyeV
New Contributor III
Hi everybody!

I'd like to copy configuration file (like switch.cfg) from one switch to another directly by SCP2. Can I set public key authentication between swithces? I know how to load public key to switch, but can XOS generate this public key?

I hope you get my idea.

If it impossible, can you suggest me another way to do it (TFTP or something) please?
7 REPLIES 7

StephenW
Extreme Employee
You can use SCP2 to transfer files between switches. You just need to "enable ssh2" on the CLI and a key will be created. Are you trying to do this without a password login?

Switch# scp2 flowtrack.py johndoe@192.0.2.100:flowtrack.py
Upload /config/flowtrack.py to
Keyboard-interactive authentication
Enter password for johndoe:
Connected to 192.0.2.100.
Uploading /config/flowtrack.py to /config/flowtrack.py
/config/flowtrack.py 100% 17KB 17.2KB/s 00:00
Switch#
Switch at 192.0.2.100 logs:
09/30/2015 09:05:04.28 User johndoe logout from ssh (192.0.2.200)
09/30/2015 09:05:04.21 Msg from Master : Got file flowtrack.py
09/30/2015 09:05:04.13 Msg from Master : Did password authentication for user johndoe (192.0.2.200)
09/30/2015 09:05:04.13 Login passed for user johndoe through ssh (192.0.2.200)

eyeV
New Contributor III
Some backgound about it. I have some switches in production network and one switch in cold reserve. My idea is automaticaly copy all .cfg files from switches to reserve switch to minimize recovery time in case of replacement equipment.

eyeV
New Contributor III
Yes, it works perfectly. But I'd like to do it without keyboard-interactive authentication. I'm going to execute this command remotely by cron.
GTM-P2G8KFN