volume size is virtual disk size not physical size, so uploaded volume should 
use virtual size


Project: http://git-wip-us.apache.org/repos/asf/cloudstack/repo
Commit: http://git-wip-us.apache.org/repos/asf/cloudstack/commit/354d259d
Tree: http://git-wip-us.apache.org/repos/asf/cloudstack/tree/354d259d
Diff: http://git-wip-us.apache.org/repos/asf/cloudstack/diff/354d259d

Branch: refs/heads/vmware-storage-motion
Commit: 354d259d5513c3788e43ee4662984bd69e07b629
Parents: 56535a7
Author: Anthony Xu <anthony...@citrix.com>
Authored: Wed May 29 15:37:13 2013 -0700
Committer: Anthony Xu <anthony...@citrix.com>
Committed: Wed May 29 15:37:13 2013 -0700

----------------------------------------------------------------------
 .../storage/download/DownloadMonitorImpl.java      |    2 +-
 1 files changed, 1 insertions(+), 1 deletions(-)
----------------------------------------------------------------------


http://git-wip-us.apache.org/repos/asf/cloudstack/blob/354d259d/server/src/com/cloud/storage/download/DownloadMonitorImpl.java
----------------------------------------------------------------------
diff --git a/server/src/com/cloud/storage/download/DownloadMonitorImpl.java 
b/server/src/com/cloud/storage/download/DownloadMonitorImpl.java
index 220cbff..663ab4a 100755
--- a/server/src/com/cloud/storage/download/DownloadMonitorImpl.java
+++ b/server/src/com/cloud/storage/download/DownloadMonitorImpl.java
@@ -552,7 +552,7 @@ public class DownloadMonitorImpl extends ManagerBase 
implements  DownloadMonitor
                        //Create usage event
             long size = -1;
             if(volumeHost!=null){
-                size = volumeHost.getPhysicalSize();
+                size = volumeHost.getSize();
                 volume.setSize(size);
                 this._volumeDao.update(volume.getId(), volume);
             }

Reply via email to