Bug 1228244

Summary: Need double space on ISCSI volume, when run re-depoy of exist vm
Product: [oVirt] ovirt-hosted-engine-setup Reporter: Artyom <alukiano>
Component: Plugins.BlockAssignee: Simone Tiraboschi <stirabos>
Status: CLOSED WONTFIX QA Contact: Ilanit Stein <istein>
Severity: high Docs Contact:
Priority: unspecified    
Version: 1.2.4CC: bugs, ecohen, gklein, lsurette, sbonazzo, tnisan, ylavi
Target Milestone: ---   
Target Release: ---   
Hardware: x86_64   
OS: Linux   
Whiteboard: integration
Fixed In Version: Doc Type: Bug Fix
Doc Text:
Story Points: ---
Clone Of: Environment:
Last Closed: 2015-09-29 07:39:28 UTC Type: Bug
Regression: --- Mount Type: ---
Documentation: --- CRM:
Verified Versions: Category: ---
oVirt Team: --- RHEL 7.3 requirements from Atomic Host:
Cloudforms Team: --- Target Upstream Version:
Embargoed:
Bug Depends On:    
Bug Blocks: 1199907    
Attachments:
Description Flags
setup log none

Description Artyom 2015-06-04 13:22:32 UTC
Created attachment 1034717 [details]
setup log

Description of problem:
We have possibility to continue deployment with exist vm, how described in bug https://bugzilla.redhat.com/show_bug.cgi?id=1199907, but in time of first deploy on ISCSI volume we reserve some specific space let's say 25Gb, and when we run redeploy we again check if storage have enough free space and it not have because we already reserved 25Gb.

Version-Release number of selected component (if applicable):
ovirt-hosted-engine-setup-1.2.4-2.el7ev.noarch

How reproducible:
Always

Steps to Reproduce:
1. Created volume of 50GB
2. Run hosted-engine --deploy and set disk size to 25GB
3. Stop deployment after engine installation stage(Ctrl+D)
4. Run hosted-engine --deploy --config-append=generated_answer_file(like described in bug https://bugzilla.redhat.com/show_bug.cgi?id=1199907)

Actual results:
Deployment failed with message that not enough disk space:
InsufficientSpaceError: Error: the VG on block device has capacity of          only 20 GiB while 25 GiB is required for the image
It possible to avoid problem, if to set in config file storage space less than 

Expected results:
I believe we need to pass storage disk space checking if we continue previous deployment and storage already exist, and deployment must success

Additional info:
Problematic part of code:
if int(
                self.environment[
                    ohostedcons.StorageEnv.IMAGE_SIZE_GB
                ]
            ) > available_gb:
                raise ohosteddomains.InsufficientSpaceError(
                    _(
                        'Error: the VG on block device has capacity of only '
                        '{available_gb} GiB while '
                        '{image_gb} GiB is required for the image'
                    ).format(
                        available_gb=available_gb,
                        image_gb=self.environment[
                            ohostedcons.StorageEnv.IMAGE_SIZE_GB
                        ],
                    )
                )

Comment 1 Simone Tiraboschi 2015-09-29 07:39:28 UTC
Stop support of redeploy feature under 3.6 according to https://bugzilla.redhat.com/show_bug.cgi?id=1238709#c2