+++ This bug was initially created as a clone of Bug #1053733 +++
+++ This bug was initially created as a clone of Bug #960934 +++
When extending a disk no validation that the domain has enough free space is made.
The space requirements:
(Note that even though the disk may contain data, the EXTENDED part does not have any new data except for pre-allocation considerations):
| File Domain | Block Domain
-----|-------------------------------------|-------------
qcow | no additional validation required |no additional validation required
| (header is already allocated) |(header is already allocated)
-----|-------------------------------------|-------------
raw | preallocated: |new capacity - old capacity
| new capacity - old capacity |
| thin (sparse): no additional |
| validation |
Tested the following:
On block:
1) Tried to extend a thin-provision disk from 7G to 57G on a storage domain that has 48G free space - SUCCEEDED.
2) Tried to extend a preallocated disk from 3G to 40G on a storage domain that has 38G free space - FAILED - blocked with a CDA failure message
On file:
1) Tried to extend a thin-provision disk from 3 to 25G on a storage domain that has 14G free space - SUCCEEDED.
2) Tried to extend a preallocated disk from 2G to 25G on a storage domain that has 14G free space - FAILED - blocked with a CDA failure message
Verified using RHEV3.4-AV3