Forum Discussion
Oct 13, 2021
SCP automated backup failing.
Hi Guy's,
I am following the guide https://my.f5.com/manage/s/article/K13418 to create and automatically transfer my UCS file to our remote backup.
It creates the backup but I cannot tra...
zamroni777
Jul 09, 2024Nacreous
you can try to use /bin/expect to execute scenario of interactive shell.
then put the expect execution in icall, crontab or other scheduler.
# cat /var/tmp/script.exp
set timeout -1
spawn $env(SHELL)
match_max 100000
expect "#"
send -- "scp /var/tmp/ggg.txt myusername@myserver.com:/target/path\n"
expect "Password:"
send -- "mypassword\n"
expect "# "
send -- "exit\n"
#
#/bin/expect -f /var/tmp/script.exp
...
you can create recording of other interactive shell flow file using "/bin/autoexpect -p"
Recent Discussions
Related Content
DevCentral Quicklinks
* Getting Started on DevCentral
* Community Guidelines
* Community Terms of Use / EULA
* Community Ranking Explained
* Community Resources
* Contact the DevCentral Team
* Update MFA on account.f5.com
Discover DevCentral Connects