Question

How can I maintain a list of remote hosts to run GNU Parallel commands on, without having to specify the servers manually?

Preferably, I can have a few different groups/files with machine names/addresses in them and run GNU Parallel commands on any of those groups.

Was it helpful?

Solution

You can use the --slf FILE option to specify a file with hostnames in it. If the normal command line argument looks like -S $SERVER1,$SERVER2,$SERVER3, your file can look like:

$SERVER1,$SERVER2
$SERVER3

That is, you can have the same comma separated list on one line, each server on a new line or a mix between the two.

OTHER TIPS

Please look at --hostgroups from version 20141122. It should cover most hostgroup situations.

Licensed under: CC-BY-SA with attribution
Not affiliated with StackOverflow
scroll top