git.svenne.dk
/
public
/
kvm-scripts.git
/ blob
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
|
commitdiff
|
tree
history
|
raw
|
HEAD
first version
[public/kvm-scripts.git]
/
stop.sh
1
#!/bin/bash
2
if [ $# -lt 1 ] ; then
3
echo "$0 <machine-conf>"
4
exit
5
fi
6
if [ ! -f $1 ] ; then
7
echo "<machine conf> does not exists at $1";
8
exit
9
fi
10
. $1
11
if [ ! -f _pids/$NAME ] ; then
12
echo "machine $NAME is not running";
13
exit
14
fi
15
echo "system_powerdown" | socat - TCP:localhost:$MONPORT
16
rm _pids/$NAME