public void deployVM(
     final VirtualMachine vm, final ResourceAllocation ra, final Repository vaSource)
     throws VMManagementException, NetworkNode.NetworkException {
   if (checkAllocationsPresence(ra)) {
     final VirtualAppliance va = vm.getVa();
     final StorageObject foundLocal = localDisk.lookup(va.id);
     final StorageObject foundRemote = vaSource == null ? null : vaSource.lookup(va.id);
     if (foundLocal != null || foundRemote != null) {
       vm.switchOn(ra, vaSource);
     } else {
       throw new VMManagementException("No VA available!");
     }
   } else {
     throw new VMManagementException("Tried to deploy VM with an expired resource allocation");
   }
 }