Bug 1467828 - Provisioned host automatically selects Blank template and has no storage
Summary: Provisioned host automatically selects Blank template and has no storage
Keywords:
Status: CLOSED ERRATA
Alias: None
Product: Red Hat Satellite
Classification: Red Hat
Component: Compute Resources - RHEV
Version: 6.3.0
Hardware: Unspecified
OS: Unspecified
medium
medium
Target Milestone: Unspecified
Assignee: orabin
QA Contact: Sanket Jagtap
URL:
Whiteboard:
Depends On:
Blocks:
TreeView+ depends on / blocked
 
Reported: 2017-07-05 09:13 UTC by Sanket Jagtap
Modified: 2019-09-26 17:29 UTC (History)
6 users (show)

Fixed In Version:
Doc Type: If docs needed, set a value
Doc Text:
Clone Of:
Environment:
Last Closed: 2018-02-21 16:32:37 UTC
Target Upstream Version:
Embargoed:


Attachments (Terms of Use)
Host created has no storage (38.92 KB, image/png)
2017-07-05 09:13 UTC, Sanket Jagtap
no flags Details
VM tab while creating the host (56.10 KB, image/png)
2017-07-05 09:14 UTC, Sanket Jagtap
no flags Details


Links
System ID Private Priority Status Summary Last Updated
Foreman Issue Tracker 20284 0 None None None 2017-07-12 09:15:20 UTC

Description Sanket Jagtap 2017-07-05 09:13:28 UTC
Created attachment 1294518 [details]
Host created has no storage

Description of problem:


Version-Release number of selected component (if applicable):
Satellite 6.3.0

How reproducible:
Always

Steps to Reproduce:
1.Create a compute Profile, with all related options except template option(do not select it)
2.Create a Host using the same compute profile 
3.Go to the created host and check the VM tab
4.Blank template is selected, while host was provisioned

Actual results:
Selection of blank template ,overrides the storage config's from the compute resource
Host is provisioned with no storage

Expected results:
Blank template should not be selected
Host should be provisioned 

Additional info:

Comment 1 Sanket Jagtap 2017-07-05 09:14:19 UTC
Created attachment 1294519 [details]
VM tab while creating the host

Comment 3 orabin 2017-07-12 09:15:18 UTC
Created redmine issue http://projects.theforeman.org/issues/20284 from this bug

Comment 4 Ivan Necas 2017-07-12 15:46:02 UTC
We ware able to reproduce the issue this way:

1. when creating compute profile, first select the template (the storage volumes get populated), then unselect the template (the storage volumes
stay there and they are enabled).
2. save the compute profile
3. use it for provisioning

Results: no storage

Expected: the storage gets set

We were not able to reproduce the behaviour with the template being set even when
the it was not set in the compute profile.

Could you confirm it's possible the reproducer steps I've described are what you've seen as well. Additionally, could you share output of this API call
(update the ids of compute_resources and compute profiles accordingly)

  /api/compute_resources/1/compute_profiles/1

Comment 5 Satellite Program 2017-07-14 08:14:52 UTC
Moving this bug to POST for triage into Satellite 6 since the upstream issue http://projects.theforeman.org/issues/20284 has been resolved.

Comment 6 Sanket Jagtap 2017-08-09 14:32:53 UTC
I was able to reproduce this , with both the approaches from comment #1 and #4

Created using Comment #1
https://sat/api/compute_resources/2/compute_profiles/3 

{"created_at":"2017-08-07 21:57:04 +0530","updated_at":"2017-08-07 21:57:04 +0530","id":3,"name":"3-Large","compute_attributes":[{"id":2,"name":"1 Cores and 2 GB memory","compute_resource_id":2,"compute_resource_name":"rhevm1","provider_friendly_name":"RHEV","compute_profile_id":3,"compute_profile_name":"3-Large","vm_attrs":{"cluster":"00000001-0001-0001-0001-00000000022f","template":"","cores":"1","memory":"2147483648","interfaces_attributes":{"1502288635150":{"name":"nic1","network":"737353a9-dff8-44d7-bd64-de9c9edd6fda"}},"volumes_attributes":{"1502288655271":{"size_gb":"10","storage_domain":"69642628-4697-41c7-b9df-4f6791dd20c8","id":"","preallocate":"0","bootable":"true"}}}}]}

Created using Comment #4
https://sat/api/compute_resources/2/compute_profiles/2
{"created_at":"2017-08-07 21:57:04 +0530","updated_at":"2017-08-07 21:57:04 +0530","id":2,"name":"2-Medium","compute_attributes":[{"id":1,"name":"1 Cores and 1 GB memory","compute_resource_id":2,"compute_resource_name":"rhevm1","provider_friendly_name":"RHEV","compute_profile_id":2,"compute_profile_name":"2-Medium","vm_attrs":{"cluster":"00000001-0001-0001-0001-00000000022f","template":"","cores":"1","memory":"1073741824","interfaces_attributes":{"1502288289556":{"name":"nic1","network":"737353a9-dff8-44d7-bd64-de9c9edd6fda"}},"volumes_attributes":{"1502288299920":{"size_gb":"10","storage_domain":"69642628-4697-41c7-b9df-4f6791dd20c8","id":"","preallocate":"0","bootable":"true"}}}}]}

Comment 7 Sanket Jagtap 2017-10-24 19:41:13 UTC
Build : satellite 6.3.0 snap 21


Steps 
1. when creating compute profile, first select the template (the storage volumes get populated), then unselect the template (the storage volumes
stay there and they are enabled).
2. Removed the storage volumes
3. Added custom storage size
3. save the compute profile
4. use it for provisioning

Box was provisioned successfully


There is a no storage attached to created box  if, The same storage volumes are used as per step 1

"when creating compute profile, first select the template (the storage volumes get populated), then unselect the template (the storage volumes
stay there and they are enabled)."

Is this desired, are we supposed to delete the volume and add a new?

Comment 8 orabin 2017-10-29 06:18:33 UTC
If we unselect the template then the storage that was added for it should also get removed.
It used to keep it and enable it so selecting and unselecting would create more and more volumes.

Comment 12 Sanket Jagtap 2017-10-30 17:09:57 UTC
Marking this a verified.


Note: Be sure to remove storage volumes added due to selecting/unselecting templates.
See BZ: https://bugzilla.redhat.com/show_bug.cgi?id=1498408

Comment 13 Bryan Kearney 2018-02-21 16:32:37 UTC
Since the problem described in this bug report should be resolved in a recent advisory, it has been closed with a resolution of ERRATA.

For information on the advisory, and where to find the updated files, follow the link below.

If the solution does not work for you, open a new bug report.

https://access.redhat.com/errata/RHSA-2018:0336


Note You need to log in before you can comment on or make changes to this bug.