I am planning to make a simple script for logging on to a switch & take the configuration backup!
I used to login manually & want to do this in a single command or through a script!
Anyone could help me out?
root@xxx:/home# ftp xxx.19.254.61
Connected to xxx.19.254.61.
220 xx-xx-xx-xxx-SW-2 FTP version 1.0 ready at Sat Feb 14 23:28:25 1970
Name (xxx.19.254.61:root): admin
331 Enter PASS command
Password:
230 Logged in
Remote system type is UNIX.
Using binary mode to transfer files.
ftp> get config config.cfg
local: config.cfg remote: config
200 Port command okay
150 Opening data connection for RETR config
226 File sent OK
2824 bytes received in 1.05 secs (2.6227 kB/s)
ftp> bye
221 Goodbye!
Is
heredocnot good for you?