Bug 1819260

Summary: [RFE] enhance search filter for Storage Domains with free argument
Product: Red Hat Enterprise Virtualization Manager Reporter: Steffen Froemer <sfroemer>
Component: ovirt-engineAssignee: Eli Mesika <emesika>
Status: CLOSED ERRATA QA Contact: Petr Kubica <pkubica>
Severity: medium Docs Contact:
Priority: medium    
Version: 4.3.8CC: emarcus, emesika, lleistne, michal.skrivanek, mperina, mtessun, pelauter, tnisan
Target Milestone: ovirt-4.4.2Keywords: FutureFeature, ZStream
Target Release: 4.4.2   
Hardware: Unspecified   
OS: Unspecified   
Whiteboard:
Fixed In Version: rhv-4.4.2-2 ovirt-engine-4.4.2.1 Doc Type: Enhancement
Doc Text:
The following search filter properties for Storage Domains have been enhanced: - 'size' changed to 'free_size' - 'total_size' added to the search engine options - 'used' changed to 'used_size' For example , you can use now the following in the Storage Domains tab: "free_size > 6 GB and total_size < 20 GB"
Story Points: ---
Clone Of:
: 1870353 (view as bug list) Environment:
Last Closed: 2020-09-23 16:11:04 UTC Type: Bug
Regression: --- Mount Type: ---
Documentation: --- CRM:
Verified Versions: Category: ---
oVirt Team: Infra RHEL 7.3 requirements from Atomic Host:
Cloudforms Team: --- Target Upstream Version:
Embargoed:
Bug Depends On:    
Bug Blocks: 1870353    
Attachments:
Description Flags
Search storage domains view , marked row is used in next image for search
none
search storage domains with 'size=161' brings the row with free size none

Description Steffen Froemer 2020-03-31 15:11:50 UTC
1. Proposed title of this feature request
enhance search filter for Storage Domains with free argument

3. What is the nature and description of the request?
 To create a vm with a disk I have to determine a storage domain with enough free space. Unfortunately it is not possible to search for storage domains with a specific /free/ space, only with a specific /size/. Having such a feature would greatly improve the automation complexity. 

4. Why does the customer need this? (List the business requirements here)
* Greatly reduces complexity of ansible playbooks for creating vms
* Fast way to find bottlenecks due to mostly used storage domains

5. How would the customer like to achieve this? (List the functional requirements here)
An additional search option should be implemented to the current available list.

https://access.redhat.com/documentation/en-us/red_hat_virtualization/4.3/html-single/introduction_to_the_administration_portal/index#Searching_for_storage


6. For each functional requirement listed, specify how Red Hat and the customer can test to confirm the requirement is successfully implemented.
It could be tested using ansible with following snippet. It should return a list of possible Storage Domains

        - name: list storage domains
          ovirt_storage_domain_info:
                auth: "{{ ovirt_auth }}"
                pattern: type = nfs and free > 100
          register: sddata

        - name: show sd data
          debug:
              msg: "{{ sddata }}"


7. Is there already an existing RFE upstream or in Red Hat Bugzilla?
no


8. Does the customer have any specific timeline dependencies and which release would they like to target (i.e. RHEL5, RHEL6)?
asap


9. Is the sales team involved in this request and do they have any additional input?
no


10. List any affected packages or components.
Search Engine in Web UI


11. Would the customer be able to assist in testing this functionality if implemented?
yes

Comment 2 Eli Mesika 2020-04-16 09:15:24 UTC
Created attachment 1679277 [details]
Search storage domains view , marked row is used in next image for search

Comment 3 Eli Mesika 2020-04-16 09:16:23 UTC
Created attachment 1679278 [details]
search storage domains with 'size=161' brings the row with free size

Comment 4 Eli Mesika 2020-04-16 09:18:07 UTC
Currently the property 'size' in the search is looking for the free size and can be used as the customer requested, does this fulfill the requirement ?

Comment 5 Steffen Froemer 2020-04-20 09:50:06 UTC
(In reply to Eli Mesika from comment #4)
> Currently the property 'size' in the search is looking for the free size and
> can be used as the customer requested, does this fulfill the requirement ?

Honestly, technically it's exactly what customer is looking for, but that solution is far away from positive user acceptance.

1) In UI the Storage domain is shown with 2 different sections regarding capacity. Free space and Total space (total size of Storage Domain)
   Now the search filter provides 

2) It's not documented that 'size' filter will check against free disk space of a storage domain [1]
   ( size --> The size of the storage.)
3) There is no information about which measurement unit I have to use for correctly apply the filter. Is it based on IEC or SI units? Is it KB/KiB, MB/MiB or GB/GiB. 

Overall, it's a complete mess and I expect to have it fixed in the following way.

1) use the filter 'size' for total size.
2) introduce a new 'free' filter which is based on free storage of a storage domain. (same what the filter 'size' is doing by today)
2) document the usage and explanation, what is returned when using this filter. Also document measurement units.


[1]: https://access.redhat.com/documentation/en-us/red_hat_virtualization/4.3/html-single/introduction_to_the_administration_portal/index#Searching_for_storage

Comment 13 Petr Kubica 2020-08-31 10:47:12 UTC
Verified in ovirt-engine-4.4.2.3-0.6.el8ev.noarch

Comment 17 errata-xmlrpc 2020-09-23 16:11:04 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 (Moderate: Red Hat Virtualization security, bug fix, and enhancement update), 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-2020:3807