09-07-2011 05:17 AM - edited 07-03-2021 08:40 PM
Hi,
Is there a way to schedule automatic configuration uploads (backups) on WLCs? It should be done without using WCS.
Thank you in advance.
Regards,
Andras
The solution has been added in the following document;-
https://supportforums.cisco.com/docs/DOC-21757
Solved! Go to Solution.
09-07-2011 01:03 PM
There is a way to do this using expect scripts
See my post at https://supportforums.cisco.com/message/3438495#3438495
you can use cron to call the shell script that calls the commands expect file.
commands expect script for backing up configs. Change the script upload variables for your environment
#!/usr/bin/expect
set router [ lindex $argv 0]
set username [ lindex $argv 1]
set password [ lindex $argv 2]
spawn ssh $router
#log_user 0
set timeout 10
expect "(yes/no)?" {
send "yes\r"; exp_continue }
expect "User:"
send -- "$username\r"
expect "assword:"
send -- "$password\r"
expect "Controller"
send -- "transfer upload datatype config\r"
expect "Controller"
send -- "transfer upload mode tftp\r"
expect "Controller"
send -- "transfer upload serverip
expect "Controller"
send -- "transfer upload start\r"
# some wlc config commands require yes/no verification
expect "(y/N)"
send -- "y\r"
expect "Controller"
send "logout\r"
expect "(y/N)"
send -- "n\r"
expect eof
09-07-2011 05:50 AM
hmmmm... i am not aware of such stuff without using WCS... u can go for SNMP WALK using any freeware SNMP stuffs from the net..
Regards
Surendra
02-25-2016 09:31 PM
Hi Sir,
How to take back up of
Model: AIR-CT2504-25-K9Z Ask file path & file name Which name I will asign for back up..
Any one name or perticuller please suggest
09-07-2011 01:03 PM
There is a way to do this using expect scripts
See my post at https://supportforums.cisco.com/message/3438495#3438495
you can use cron to call the shell script that calls the commands expect file.
commands expect script for backing up configs. Change the script upload variables for your environment
#!/usr/bin/expect
set router [ lindex $argv 0]
set username [ lindex $argv 1]
set password [ lindex $argv 2]
spawn ssh $router
#log_user 0
set timeout 10
expect "(yes/no)?" {
send "yes\r"; exp_continue }
expect "User:"
send -- "$username\r"
expect "assword:"
send -- "$password\r"
expect "Controller"
send -- "transfer upload datatype config\r"
expect "Controller"
send -- "transfer upload mode tftp\r"
expect "Controller"
send -- "transfer upload serverip
expect "Controller"
send -- "transfer upload start\r"
# some wlc config commands require yes/no verification
expect "(y/N)"
send -- "y\r"
expect "Controller"
send "logout\r"
expect "(y/N)"
send -- "n\r"
expect eof
01-03-2012 12:29 AM
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