Created attachment 1235269 [details] engine log Description of problem: When trying to take a prestarted vm from a pool via API as a user that got userRole permission on the pool, the action fails with: Detail: [General command validation failure.] engine.log shows a very long trace for this error: 2016-12-22 08:45:14,742+02 ERROR [org.ovirt.engine.core.bll.AttachUserToVmFromPoolAndRunCommand] (default task-4) [vmpools_syncAction_b45dcdea-fa27-4e0] Error during ValidateFailure.: java.lang.NullPointerException We hit this issue on automation and I was able to re produce the bug on my 4.1 env manually. The same error doesn't occur when login with the user to user portal and starting a session on the vm from there. Version-Release number of selected component (if applicable): ovirt-engine-4.1.0-0.2.master.20161218144454.gitbaa2853.el7.centos.noarch How reproducible: always Steps to Reproduce: 1. Create a vm pool - size 1, set pre started vms in the pool to 1. 2. Add userRole permission for the pool to some user in your system, can be admin as well. 3. Wait for the prestarted vm to start. 4. Connect to API with user you gave permissions on the pool to and try to allocate a vm from the pool POST https://{engine_url}/ovirt-engine/api/vmpools/{vmpool_id}/allocatevm <action> <async>false</async> <grace_period> <expiry>10</expiry> </grace_period> </action> Actual results: Fails with: Detail: [General command validation failure.] Expected results: User starts a session on the vm and vm inherits the userRole permission for that user from the pool. Additional info: Attaching engine.log from automation run - look for: 'vmpools_syncAction_b45dcdea-fa27-4e0'
This bug report has Keywords: Regression or TestBlocker. Since no regressions or test blockers are allowed between releases, it is also being identified as a blocker for this release. Please resolve ASAP.
Verified with rhevm-4.1.0.2-0.2.el7.noarch according to the steps in description.