Table of Contents

Usage

Just start multi_ssh.sh - it will initialize a user config file with the defaults. Without a parameter you reach the interactive mode.

To see the parameters start multi_ssh.sh -h

_______________________________________________________________________________

 MULTI REMOTE EXECUTION WITH SSH                                         ______
________________________________________________________________________/ v0.18


A remote execution tool to run a command on multiple servers.
Its main usage is in interactive mode and command line parameters.

    Source:  <https://git-repo.iml.unibe.ch/iml-open-source/multi_ssh/>
    License: GNU GPL 3.0
    Docs:    <https://os-docs.iml.unibe.ch/multi_ssh/>

    2023-2024 Institute for Medical Education; University of Bern

SYNTAX:
    multi_ssh.sh [OPTIONS] [SERVERLIST]

OPTIONS:
    -c|--command [COMMAMD]
                 set a command for remote execution. A 2nd value
                 for the new command is optional. Without param
                 you reach an interactive mode.
                 Save config and exit.
    -h|--help    show this help and exit
    -l|--list    list servers
    -p|--profile [PROFILE]
                 set a profile for network environment
    -t|--tag [TAGNAME(s)]
                 set a tag to filter serverlist.
                 To set multiple tags quote it as a single string
                 and seperate them wih a space. Without param
                 you reach an interactive mode.
                 Save config and exit. 
PARAMETERS:
    The serverlist is a combination of servers that should
    execute the command [hostname -f].
    It can be the number of a server or a 
    A special item is ALL - it executes the command on all servers

    Without a parameter you reach the interactive mode.

EXAMPLES:
    multi_ssh.sh -c               - set a new command. Enter it on the prompt
    multi_ssh.sh -c "sudo reboot" - set a given command
    multi_ssh.sh -t "mon live"    - set filter tags "mon" and "live"
    multi_ssh.sh -l               - list servers that match all tags (AND condition)
    multi_ssh.sh 1 2 5            - run the command on 1st, 2nd and 5th server
    multi_ssh.sh monitor          - run the command on the first server that matches 'monitor'