mirror of
https://github.com/vdsm/virtual-dsm.git
synced 2025-06-09 01:47:32 +08:00
MONPORT
This commit is contained in:
parent
501e3ce778
commit
4e5a48422c
@ -63,7 +63,7 @@ _graceful_shutdown(){
|
||||
echo $(($(cat ${_QEMU_SHUTDOWN_COUNTER})+1)) > ${_QEMU_SHUTDOWN_COUNTER}
|
||||
|
||||
# Try to connect to qemu
|
||||
if echo 'info version'| nc -q 1 -w 1 localhost "${QEMU_MONPORT:-7100}">/dev/null; then
|
||||
if echo 'info version'| nc -q 1 -w 1 localhost "${QEMU_MONPORT}" > /dev/null; then
|
||||
|
||||
sleep 1
|
||||
#echo "Shutting down, waiting... ($(cat ${_QEMU_SHUTDOWN_COUNTER})/${QEMU_POWERDOWN_TIMEOUT})"
|
||||
@ -73,11 +73,11 @@ _graceful_shutdown(){
|
||||
|
||||
echo
|
||||
echo "Quitting..."
|
||||
echo 'quit' | nc -q 1 -w 1 localhost "${QEMU_MONPORT:-7100}">/dev/null || true
|
||||
echo 'quit' | nc -q 1 -w 1 localhost "${QEMU_MONPORT}" > /dev/null || true
|
||||
|
||||
return
|
||||
}
|
||||
|
||||
_trap _graceful_shutdown SIGTERM SIGHUP SIGINT SIGABRT SIGQUIT
|
||||
|
||||
KVM_MON_OPTS="-monitor telnet:localhost:${QEMU_MONPORT:-7100},server,nowait,nodelay"
|
||||
KVM_MON_OPTS="-monitor telnet:localhost:${QEMU_MONPORT},server,nowait,nodelay"
|
||||
|
Loading…
x
Reference in New Issue
Block a user