Last change
on this file since 10368 was 10269, checked in by rick, 13 years ago |
Use the API to get the list of available hosts.
|
-
Property svn:executable
set to
*
|
File size:
426 bytes
|
Rev | Line | |
---|
[9947] | 1 | #!/bin/sh
|
---|
| 2 | #
|
---|
| 3 | # Mega simple wrapper for batch control on nodes.
|
---|
| 4 | #
|
---|
| 5 | # Rick van der Zwet <info@rickvanderzwet.nl>
|
---|
| 6 | #
|
---|
| 7 |
|
---|
[10269] | 8 | HOSTS=${*:-`$(dirname $0)/gformat.py list all`}
|
---|
[9947] | 9 | PREFIX=${PREFIX:-'ip'}
|
---|
| 10 | CMD=${CMD:-'ifconfig -a'}
|
---|
| 11 |
|
---|
[10269] | 12 | echo "# WARN: Going to run at: " $HOSTS; sleep 2
|
---|
[9947] | 13 |
|
---|
| 14 | for HOST in $HOSTS; do
|
---|
[9956] | 15 | ssh -o ConnectTimeout=3 -o BatchMode=yes root@$HOST.wleiden.net. $CMD > $PREFIX-$HOST.txt &
|
---|
[9947] | 16 | done
|
---|
| 17 |
|
---|
| 18 | # Wait for all processes to complete.
|
---|
| 19 | wait
|
---|
Note:
See
TracBrowser
for help on using the repository browser.