I sketched another example of a script for backing up the Huawei MA5800 configuration.
You need to do it in Linux, the connection is made via telnet, the same can be done for ssh, it is imperative that in the firewall of the Huawei MA5800 device itself, access to management for all services, ssh, snmp, including telnet, must be allowed only to trusted IP addresses.
#!/bin/bash ( sleep 5 echo "username ixnfo.com" sleep 5 echo "password" sleep 5 echo "enable" sleep 2 echo "backup configuration tftp 192.168.1.5 `date +%Y-%m-%d`_0201_nas_55_.zip format zip" sleep 2 echo "y" sleep 10 echo "quit" sleep 2 echo "y" ) | telnet 192.168.1.6
See also my articles:
- Installing and Configuring a TFTP Server in Ubuntu
- Using and configuring CRON
- Script to delete old files