Bladeren bron

qubes/vm: disconnect from old QubesDB when going to start new instance

QubesDB daemon no longer remove socket created by new instance, so one
part of VM restart race condition is solved. The only remaining part is
to ensure that we really connect to the new instance, instead of talking
to the old one (soon to be terminated).

Fixes QubesOS/qubes-issues#1694
Marek Marczykowski-Górecki 7 jaren geleden
bovenliggende
commit
8f443547fb
1 gewijzigde bestanden met toevoegingen van 3 en 2 verwijderingen
  1. 3 2
      qubes/vm/qubesvm.py

+ 3 - 2
qubes/vm/qubesvm.py

@@ -1173,9 +1173,10 @@ class QubesVM(qubes.vm.mix.net.NetVMMixin, qubes.vm.BaseVM):
         :raises OSError: when starting fails.
         '''
 
-        self.log.info('Starting Qubes DB')
+        # drop old connection to QubesDB, if any
+        self._qdb_connection = None
 
-        # FIXME #1694 #1241
+        self.log.info('Starting Qubes DB')
         try:
             self.start_daemon([
                 qubes.config.system_path["qubesdb_daemon_path"],