Author: arkurth
Date: Thu Sep 17 19:40:20 2009
New Revision: 816351

URL: http://svn.apache.org/viewvc?rev=816351&view=rev
Log:
VCL-228
Modified Windows pre_capture() to not fail the reservation if it fails to 
delete the reservation users on the first attempt.  Added 2nd attempt to delete 
users after the pagefile reboot if the 1st attempt failed.  This should fix the 
problem where image captures fail because a file is held open in the user's 
profile.

Modified:
    incubator/vcl/trunk/managementnode/lib/VCL/Module/OS/Windows.pm

Modified: incubator/vcl/trunk/managementnode/lib/VCL/Module/OS/Windows.pm
URL: 
http://svn.apache.org/viewvc/incubator/vcl/trunk/managementnode/lib/VCL/Module/OS/Windows.pm?rev=816351&r1=816350&r2=816351&view=diff
==============================================================================
--- incubator/vcl/trunk/managementnode/lib/VCL/Module/OS/Windows.pm (original)
+++ incubator/vcl/trunk/managementnode/lib/VCL/Module/OS/Windows.pm Thu Sep 17 
19:40:20 2009
@@ -165,9 +165,9 @@
 
 =cut
 
-       if (!$self->delete_users()) {
-               notify($ERRORS{'WARNING'}, 0, "unable to delete users");
-               return 0;
+       my $deleted_users = $self->delete_users();
+       if (!$deleted_users) {
+               notify($ERRORS{'WARNING'}, 0, "unable to delete users, will try 
again after reboot");
        }
 
 =item *
@@ -322,6 +322,17 @@
 
 =item *
 
+ Delete the users assigned to this reservation if attempt before reboot failed
+
+=cut
+
+       if (!$deleted_users && !$self->delete_users()) {
+               notify($ERRORS{'WARNING'}, 0, "unable to delete users after 
reboot");
+               return 0;
+       }
+
+=item *
+
  Disable RDP access from any IP address
 
 =cut


Reply via email to