Note: This is a beta release of Red Hat Bugzilla 5.0. The data contained within is a snapshot of the live data so any changes you make will not be reflected in the production Bugzilla. Also email is disabled so feel free to test any aspect of the site that you want. File any problems you find or give feedback here.
Bug 1071217 - Misleading error message when user with ClusterAdmin role on cluster tries to add a disk to a VM without permissions on any storage domain
Summary: Misleading error message when user with ClusterAdmin role on cluster tries to...
Keywords:
Status: CLOSED ERRATA
Alias: None
Product: Red Hat Enterprise Virtualization Manager
Classification: Red Hat
Component: ovirt-engine
Version: 3.2.0
Hardware: All
OS: Linux
medium
medium
Target Milestone: ---
: 3.5.0
Assignee: Maor
QA Contact: Ori Gofen
URL:
Whiteboard: storage
Depends On:
Blocks: rhev3.5beta 1156165
TreeView+ depends on / blocked
 
Reported: 2014-02-28 10:09 UTC by Julio Entrena Perez
Modified: 2016-05-26 01:50 UTC (History)
13 users (show)

Fixed In Version: ovirt-engine-3.5.0_alpha1.1
Doc Type: Bug Fix
Doc Text:
Clone Of:
Environment:
Last Closed: 2015-02-11 17:59:07 UTC
oVirt Team: Storage
Target Upstream Version:


Attachments (Terms of Use)


Links
System ID Priority Status Summary Last Updated
Red Hat Knowledge Base (Solution) 739583 None None None Never
Red Hat Product Errata RHSA-2015:0158 normal SHIPPED_LIVE Important: Red Hat Enterprise Virtualization Manager 3.5.0 2015-02-11 22:38:50 UTC
oVirt gerrit 25830 None None None Never

Description Julio Entrena Perez 2014-02-28 10:09:16 UTC
Description of problem:
When a user with ClusterAdmin role at cluster level but no permissions on the storage domains tries to add a disk to a VM the following error message is displayed on the "Add Virtual Disk" dialogue:

"There are no active Storage Domains in the relevant Data Center"

That's false since:

- There are storage domains in the relevant datacenter and those are active.
- The reason user can't see/choose any storage domain is because he has no permissions on those.

Version-Release number of selected component (if applicable):
rhevm-backend-3.2.5-0.49.el6ev

How reproducible:
Always.

Steps to Reproduce:
1. Grant ClusterAdmin role to a user on a specific datacenter.
2. Login to webadmin portal as that user and try to add a disk to a guest in that cluster.
3.

Actual results:
User is presented with following error message:
"There are no active Storage Domains in the relevant Data-Center."

Expected results:
User is presented with an error message similar to the following one:
"Insufficient privileges. You need to have [role] permissions in order to add new virtual disks"

Additional info:
    Datacenter
        /\
       /  \
      /    \
 Cluster  Storage
          domain

User has ClusterAdmin role on the cluster but no permissions on the storage domains.

webadmin portal only displays active and accessible storage domains to the user in the Add Virtual Disk dialogue.

webadmin portal wrongly assumes that the reason for no storage domains being available is that they are not active.

Comment 1 Maor 2014-03-18 12:38:02 UTC
If we will have two different messages then the user can be aware when there are active storage domains in the Data Center and when there not any active storage domains.

I suggest to rephrase the message to also indicate permissions, as so:
"There are no authorized active Storage Domains in the relevant Data-Center."

Comment 2 Maor 2014-03-19 12:12:20 UTC
Eventually changed the message to be:
There are no active Storage Domains that you have permissions to create a disk on in the relevant Data-Center.

Comment 4 Ori Gofen 2014-08-07 13:43:41 UTC
User with cluster permissions has by default the ability to add disks to vm, can you please provide more detailed steps to reproduce, because right now,the result of the current one is successful

Comment 5 Maor 2014-08-09 18:04:16 UTC
Have you tried to add a new user and assign it *only* the ClusterAdmin role?

Comment 6 Ori Gofen 2014-08-10 12:48:41 UTC
yep,Ok now the error message is: 

"There are no active Storage Domains that you have permissions to create a disk on in the relevant Data-Center."

verified on rc1

Comment 8 errata-xmlrpc 2015-02-11 17:59:07 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://rhn.redhat.com/errata/RHSA-2015-0158.html


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