Fix restore completion detection in appvm/qubes_core
This commit is contained in:
parent
62487c0f1e
commit
f3561b7aad
@ -35,13 +35,8 @@ start()
|
|||||||
(read a b c d ; xenstore-write device/qubes_used_mem $c)
|
(read a b c d ; xenstore-write device/qubes_used_mem $c)
|
||||||
# we're still running in DispVM template
|
# we're still running in DispVM template
|
||||||
echo "Waiting for save/restore..."
|
echo "Waiting for save/restore..."
|
||||||
# WARNING: Nergalism!
|
|
||||||
# Apparently it has been determined that DomU kernel
|
|
||||||
# dmesg's "using vcpu" after restore
|
|
||||||
while ! dmesg -c | grep "using vcpu" ; do usleep 10 ; done
|
|
||||||
# we're now after restore in a new instance of a DispVM
|
|
||||||
# ... wait until qubes_restore.c (in Dom0) recreates VM-specific keys
|
# ... wait until qubes_restore.c (in Dom0) recreates VM-specific keys
|
||||||
while ! xenstore-read qubes_vm_type 2>/dev/null ; do
|
while ! xenstore-read qubes_restore_complete 2>/dev/null ; do
|
||||||
usleep 10
|
usleep 10
|
||||||
done
|
done
|
||||||
echo Back to life.
|
echo Back to life.
|
||||||
|
@ -336,6 +336,7 @@ void setup_xenstore(int domid, char *name)
|
|||||||
snprintf(val, sizeof(val), "10.%s.255.254", netvm_id);
|
snprintf(val, sizeof(val), "10.%s.255.254", netvm_id);
|
||||||
write_xs_single(xs, domid, "qubes_secondary_dns", val);
|
write_xs_single(xs, domid, "qubes_secondary_dns", val);
|
||||||
write_xs_single(xs, domid, "qubes_vm_type", "AppVM");
|
write_xs_single(xs, domid, "qubes_vm_type", "AppVM");
|
||||||
|
write_xs_single(xs, domid, "qubes_restore_complete", "True");
|
||||||
xs_daemon_close(xs);
|
xs_daemon_close(xs);
|
||||||
|
|
||||||
}
|
}
|
||||||
|
Loading…
Reference in New Issue
Block a user