← 返回命令列表

Linux command

ssh-para 命令

网络

需要网络或远程资源。

常用示例

Run a command on multiple hosts

ssh-para -H [host1] [host2] [host3] -- echo connection ok

Mass patch with 20 parallel jobs

ssh-para -p 20 -f [hostlist.txt] -- 'sudo yum update -y'

Execute a local script on remote hosts

ssh-para -p 20 -f [hosts.txt] -s [./myscript] -a status

说明

ssh-para enables executing commands and scripts across multiple remote servers simultaneously with interactive real-time output monitoring. It supports pausing, resuming, and aborting jobs, killing stuck connections, configurable parallelism, and log generation. Requires SSH key-based authentication.

参数

-p _N_
Number of parallel SSH connections.
-H _HOSTS_
Space-separated list of target hosts.
-f _FILE_
File containing target hostnames, one per line.
-s _SCRIPT_
Local script to execute on remote hosts.
-a _ARGS_
Arguments to pass to the script.

FAQ

What is the ssh-para command used for?

ssh-para enables executing commands and scripts across multiple remote servers simultaneously with interactive real-time output monitoring. It supports pausing, resuming, and aborting jobs, killing stuck connections, configurable parallelism, and log generation. Requires SSH key-based authentication.

How do I run a basic ssh-para example?

Run `ssh-para -H [host1] [host2] [host3] -- echo connection ok` in a terminal, then adjust file names, paths, flags, or remote targets for your system.

What does -p _N_ do in ssh-para?

Number of parallel SSH connections.