我需要在几台机器中并行执行一个comand。这可以通过pssh来完成:pssh -h hosts.txt -l ubuntu -i echo "hello,world“。
当命令不需要参数中的主机名时,这是可以的。但是,如果命令需要主机名才能像这样运行: my_obscure_cmd -主机10.11.xxx.xx
如何使用pssh运行此命令?
任何帮助都将不胜感激。
发布于 2013-12-06 13:50:42
我怀疑您正在寻找使用每个主机特定参数启动pssh的可能性。如果是这样的话,解决方案的答案是stackoverflow.com:https://stackoverflow.com/questions/13677163/parallel-ssh-with-custom-parameters-to-each-host。
https://serverfault.com/questions/559669
复制相似问题