Bug 1423468
| Summary: | the quota value of datacenter - verify for sane values | ||
|---|---|---|---|
| Product: | [oVirt] ovirt-engine | Reporter: | Tony Wang <Sline798> |
| Component: | Frontend.WebAdmin | Assignee: | Tony Wang <Sline798> |
| Status: | CLOSED CURRENTRELEASE | QA Contact: | Artyom <alukiano> |
| Severity: | low | Docs Contact: | |
| Priority: | unspecified | ||
| Version: | 4.1.1.2 | CC: | bugs, dfediuck, lveyde, Sline798, tnisan |
| Target Milestone: | ovirt-4.1.2 | Keywords: | Triaged |
| Target Release: | 4.1.2 | Flags: | rule-engine:
ovirt-4.1+
rule-engine: planning_ack+ dfediuck: devel_ack+ mavital: testing_ack+ |
| Hardware: | Unspecified | ||
| OS: | Unspecified | ||
| Whiteboard: | |||
| Fixed In Version: | Doc Type: | No Doc Update | |
| Doc Text: |
undefined
|
Story Points: | --- |
| Clone Of: | Environment: | ||
| Last Closed: | 2017-05-23 08:12:37 UTC | Type: | Bug |
| Regression: | --- | Mount Type: | --- |
| Documentation: | --- | CRM: | |
| Verified Versions: | Category: | --- | |
| oVirt Team: | SLA | RHEL 7.3 requirements from Atomic Host: | |
| Cloudforms Team: | --- | Target Upstream Version: | |
| Embargoed: | |||
|
Description
Tony Wang
2017-02-17 11:47:40 UTC
Tony, Audit should only warn (as opposed to enforcing mode). Can you please provide the engine log? When i do this operation, the engine log:
2017-02-20 19:43:11,751+08 INFO [org.ovirt.engine.core.bll.RunVmCommand] (default task-2) [5656603e-294b-4bc7-afee-0c36bc00b5b6] Lock Acquired to object 'EngineLock:{exclusiveLocks='[22cd3033-06b0-4469-8236-a2f484dd6420=<VM, ACTION_TYPE_FAILED_OBJECT_LOCKED>]', sharedLocks='null'}'
2017-02-20 19:43:11,778+08 INFO [org.ovirt.engine.core.vdsbroker.IsVmDuringInitiatingVDSCommand] (default task-2) [5656603e-294b-4bc7-afee-0c36bc00b5b6] START, IsVmDuringInitiatingVDSCommand( IsVmDuringInitiatingVDSCommandParameters:{runAsync='true', vmId='22cd3033-06b0-4469-8236-a2f484dd6420'}), log id: 1e6fdfa5
2017-02-20 19:43:11,779+08 INFO [org.ovirt.engine.core.vdsbroker.IsVmDuringInitiatingVDSCommand] (default task-2) [5656603e-294b-4bc7-afee-0c36bc00b5b6] FINISH, IsVmDuringInitiatingVDSCommand, return: false, log id: 1e6fdfa5
2017-02-20 19:43:11,802+08 WARN [org.ovirt.engine.core.bll.RunVmCommand] (default task-2) [5656603e-294b-4bc7-afee-0c36bc00b5b6] Validation of action 'RunVm' failed for user admin@internal-authz. Reasons: VAR__ACTION__RUN,VAR__TYPE__VM
2017-02-20 19:43:11,803+08 INFO [org.ovirt.engine.core.bll.RunVmCommand] (default task-2) [5656603e-294b-4bc7-afee-0c36bc00b5b6] Lock freed to object 'EngineLock:{exclusiveLocks='[22cd3033-06b0-4469-8236-a2f484dd6420=<VM, ACTION_TYPE_FAILED_OBJECT_LOCKED>]', sharedLocks='null'}'
Here are some of my conclusions:
The basic reason: Use the IntegerValidation validate Long type value in EditQuotaClusterModel and EditQuotaStorageModel.
In the IntegerValidation, the validate(Object value) method need the value's type is Integer, but the LongEntityModelTextBoxEditor will provide a Long type value. Use IntegerValidation validate Long type value will cause some mistakes.
Such as, the value 0 can pass the Validatioin, but in the QuotaManager, the checkQuotaClusterLimits(...) need the vCUPs > 0 and MemorySize > 0.
Thanks for your contribution Tony! Verified on rhevm-4.1.2-0.1.el7.noarch UI does not allow to set memory 0 to the quota Message: "This field must contain a number greater than or equal to 1" |