cancel
Showing results for 
Search instead for 
Did you mean: 
cancel
2219
Views
0
Helpful
2
Replies

Kron using SCP

abid1
Level 1
Level 1

Hi,

We are using kron with TFTP to send running config to the server, now we want to use SCP to send same to SCP server, need configuration guidance

 

Regards

2 Replies 2

Seb Rupik
VIP Alumni
VIP Alumni

Hi there,

Replace the cli line in your kron script with the TFTP command with the following:

cli copy run scp:<username>:<password>@<server_ip>/<device_name>_running.cfg

...update the <variable> values as required.

 

cheers,

Seb.

Hello,

 

I am not sure if kron works with interactive commands, if not, use the script below, or the EEM script at the bottom. The EEM script would run every day at midnight in the example, the kron policy obviously every Sunday at 15:00...

 

kron policy-list SaveRunningConfig
cli show running-config | redirect scp://username@ipaddress/folder/device_name.cfg
kron occurrence SaveRunSched at 15:00 Sun recurring
policy-list SaveRunningConfig

 

event manager applet SaveRunConfig
event timer cron con-entry "0 0 * * *" maxrun 9999999
action 1.0 cli command "enable"
action 2.0 cli command "copy running-config scp://username@ipaddress/folder/device_name.cfg"