Skip to content

Commit 4e4b67c

Browse files
subhash yedugundlasubhash yedugundla
authored andcommitted
BUG-ID:CLOUDSTACK-8921
Summary: CLOUDSTACK-8921 snapshot_store_ref table should store actual size of back snapshot in secondary storage Calling SR scan to make sure size is updated correctly
1 parent 85d073b commit 4e4b67c

1 file changed

Lines changed: 5 additions & 0 deletions

File tree

plugins/hypervisors/xenserver/src/com/cloud/hypervisor/xenserver/resource/Xenserver625StorageProcessor.java

Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -348,6 +348,7 @@ protected String backupSnapshot(final Connection conn, final String primaryStora
348348
hypervisorResource.waitForTask(conn, task, 1000, wait * 1000);
349349
hypervisorResource.checkForSuccess(conn, task);
350350
dvdi = Types.toVDI(task, conn);
351+
ssSR.scan(conn);
351352
// copied = true;
352353
} finally {
353354
if (task != null) {
@@ -486,6 +487,7 @@ public Answer backupSnapshot(final CopyCommand cmd) {
486487
hypervisorResource.checkForSuccess(conn, task);
487488
final VDI backedVdi = Types.toVDI(task, conn);
488489
snapshotBackupUuid = backedVdi.getUuid(conn);
490+
snapshotSr.scan(conn);
489491
physicalSize = backedVdi.getPhysicalUtilisation(conn);
490492

491493
if (destStore instanceof SwiftTO) {
@@ -571,6 +573,9 @@ public Answer backupSnapshot(final CopyCommand cmd) {
571573
} else {
572574
newSnapshot.setParentSnapshotPath(prevBackupUuid);
573575
}
576+
s_logger.info("New snapshot details: " + newSnapshot.toString());
577+
s_logger.info("New snapshot physical utilization: "+physicalSize);
578+
574579
return new CopyCmdAnswer(newSnapshot);
575580
} catch (final Types.XenAPIException e) {
576581
details = "BackupSnapshot Failed due to " + e.toString();

0 commit comments

Comments
 (0)