Many times we need to ssh remote servers to run specific linux commands manually. If you have to run it quite often and run the same command on multiple servers doing it manually becomes hectic. Below is sample code which you can use to create a shell script (In Linux) or a Batch program (In Windows).
1. The first file is the executable batch file- I have wrote it for windows but it can be written in shell script for Linux as well.
2. The second file - "sample-dispatcher-update-config-commands.cmd" - lists all the commands that you want to run as a group.
1. The first file is the executable batch file- I have wrote it for windows but it can be written in shell script for Linux as well.
2. The second file - "sample-dispatcher-update-config-commands.cmd" - lists all the commands that you want to run as a group.
No comments:
Post a Comment