ssh_exec_many
Run the same shell command on several of your servers at once and return each server's output and exit code. Use it to compare or check a fleet (disk space, versions, a service's state) in one call instead of one call per server. Up to 10 servers, run in parallel; the same time limit as ssh_exec (60 seconds by default, 'timeout' up to 300). Name the servers in 'hosts', or give 'tag' to run on every server that has those tags or groups (from hosts_list, e.g. ["distro:ubuntu", "prod"]). For long work use job_start on each server instead.
Tool call template
Replace each placeholder with a value matching the input schema. Only required parameters are included; add optional parameters as needed.
{
"id": 1,
"jsonrpc": "2.0",
"method": "tools/call",
"params": {
"arguments": {
"command": "<command>"
},
"name": "ssh_exec_many"
}
}Input Schema
| Name | Required | Description | Default |
|---|---|---|---|
| tag | No | Instead of 'hosts': every server with all of these tags or groups (at most 10) | |
| hosts | No | Server ids (or exact names) from hosts_list | |
| command | Yes | Shell command to execute on each server | |
| timeout | No | Max seconds to wait per server (default 60, at most 300) | |
| timeoutSeconds | No | Same as 'timeout' (older name). |