1 year ago
#77514
morris__
Can use more than one command in Parallel?
parallel --tag -k -j 100 sshpass -p test1!' ssh -oCheckHostIP=no -oStrictHostKeyChecking=no root@10.0.{} "awk '{print\ \$1\}' /proc/loadavg" ::: {41..46}.{1..100}
The script I used is the same as above
can parse it with awk using a cat, but you can not run it as a file in awk. How do solve it?
I want to get hostname, thread number, and load avg of the target node in parallel for one row for each host, but I tried to get it through awk.But there is not more than one command. God help me.
41.1 C-411 0.12 24
41.2 C-412 0.02 24
41.3 C-413 0.21 24
And there's one more question: in Linux, the IP band is included 10.10.{1..100}.1 In this way, is this a regular expression or what?
What do you do to implement this when you bring a host list to a file?
linux
bash
parallel-processing
sh
0 Answers
Your Answer