bug 6904: during volume creation, we were NOT converting the size of the parent disk offering (which is in MB), to bytes. This is the size used to create the volume. I am adding the appropriate multipliers. Other flows like creating volume from snapshot etc should remain unaffected, as the parent volume created from the disk offering will be set right.

status 6904: resolved fixed
This commit is contained in:
abhishek 2010-11-03 11:10:34 -07:00
parent 703fcaffe6
commit 426e445811
1 changed files with 2 additions and 1 deletions

View File

@ -1697,7 +1697,8 @@ public class StorageManagerImpl implements StorageManager {
if ((diskOffering == null) || !DiskOfferingVO.Type.Disk.equals(diskOffering.getType())) {
throw new InvalidParameterValueException("Please specify a valid disk offering.");
}
size = diskOffering.getDiskSize();
size = (diskOffering.getDiskSize()*1024*1024);//the disk offering size is in MB, which needs to be converted into bytes
}
} else {
Long snapshotId = cmd.getSnapshotId();