Anyone ever done this before? Trying to use plink.exe to execute a commands.txt file remotely and pull the running config. Unfortunately using the -m argument and specifying a simple command.txt file like this:
Command
plink.exe -ssh -2 -l test -pw password 192.168.1.1 -batch -m command.txt
Contents of command.txt
enable
EnablePassword
show run
Causes the thing to throw an error (invalid autocommand) because it executes all of it as one big command. Every piece of documentation I can find on the commands batch files just shows a simple text file with the various commands on separate lines.
If this technique wont work how do you folks usually automate config backups? I was leaning towards a script because it's free. I know there are paid tools out there that will do it for you. Also need to be able to execute in an environment where we may not be able to actually install and configure an app.