how to run multiple command in single line pssh?

1.1k views Asked by At

I want to run multiple command like command1, command2 , command3 in single line how to do?

i tried following

pssh -Pi --user XXXX -h host.txt  -x "-oStrictHostKeyChecking=no" ls date 

i am getting following error

Stderr: ls: cannot access date: No such file or directory
1

There are 1 answers

0
Mahesh Hegde On BEST ANSWER

Following worked for me after trying few combinations

pssh -Pi --user XXXX -h host.txt  -x "-oStrictHostKeyChecking=no" ls;date;