Changeset 767 in ProjectBuilder


Ignore:
Timestamp:
Apr 27, 2009, 11:27:45 PM (15 years ago)
Author:
Bruno Cornec
Message:
  • Fix a bug in creation of monitoring channel for snapshot of qemu/kvm VMs
File:
1 edited

Legend:

Unmodified
Added
Removed
  • devel/pb/bin/pb

    r766 r767  
    14181418    my $all;
    14191419
    1420     pb_log(2,"DEBUG: pb_script2v($pbscript,$vtype,$pbforce)\n");
     1420    pb_log(2,"DEBUG: pb_script2v($pbscript,$vtype,$pbforce,".Dumper($vm1).",$snapme)\n");
    14211421    # Prepare the script to be executed on the VM
    14221422    # in $ENV{'PBDESTDIR'}/pbscript
     
    14681468    my $snapme = shift || 0;        # By default do not snap a VM/VE
    14691469
    1470     pb_log(2,"DEBUG: pb_launchv($vtype,$v,$create)\n");
     1470    pb_log(2,"DEBUG: pb_launchv($vtype,$v,$create,$snapme)\n");
    14711471    die "No VM/VE defined, unable to launch" if (not defined $v);
    14721472    # Keep only the first VM in case many were given
     
    15001500        if ($create == 0) {
    15011501            if ((defined $vmsnap->{$v}) && ($vmsnap->{$v} =~ /true/i)) {
    1502                 $ENV{'PBVMOPT'} .= " -snapshot";
     1502                $ENV{'PBVMOPT'} .= "-snapshot ";
    15031503            } elsif ((defined $vmsnap->{$ENV{'PBPROJ'}}) && ($vmsnap->{$ENV{'PBPROJ'}} =~ /true/i)) {
    1504                 $ENV{'PBVMOPT'} .= " -snapshot";
     1504                $ENV{'PBVMOPT'} .= "-snapshot ";
    15051505            } elsif ($pbsnap eq 1) {
    1506                 $ENV{'PBVMOPT'} .= " -snapshot";
    1507             }
    1508         } elsif ($snapme != 0) {
     1506                $ENV{'PBVMOPT'} .= "-snapshot ";
     1507            }
     1508        }
     1509        if ($snapme != 0) {
    15091510            if (($vmtype eq "kvm") || ($vmtype eq "qemu")) {
    15101511                # Configure the monitoring to automize the creation of the 'pb' snapshot
Note: See TracChangeset for help on using the changeset viewer.