Change in ovirt-engine[master]: engine: vm doesn't boot from cd when CD set in "edit" (#8568...

tjelinek at redhat.com tjelinek at redhat.com
Tue Oct 2 11:37:45 UTC 2012


Tomas Jelinek has submitted this change and it was merged.

Change subject: engine: vm doesn't boot from cd when CD set in "edit" (#856806)
......................................................................


engine: vm doesn't boot from cd when CD set in "edit" (#856806)

https://bugzilla.redhat.com/856806

Virtual Machines tab -> select VM -> Edit -> Boot Options ->
select CD
Than setup boot order to First device: CD, second NONE.

The result is, that the VM will not boot from the CD attached.

The problem was in RunVmCommand.AttachCd() which did set up the
correct CD path only, when the
getVm().getboot_sequence() == BootSequence.CD

The problem is, that this condition is only true, when the
boot sequence is first the Hard Disk (C), than the CD (D).
The condition should be, that when it contains CD (D).

Solved by adding the BootSequence.containsSubsequence method
(the tests in BootSequenceTest) which checks if the specific
sequence is a subsequence of the sequence.

Change-Id: I61d39f8559bcffdc154b0b2c01d5303cf2ff1e1a
Signed-off-by: Tomas Jelinek <tjelinek at redhat.com>
---
M backend/manager/modules/bll/src/main/java/org/ovirt/engine/core/bll/RunVmCommand.java
M backend/manager/modules/common/src/main/java/org/ovirt/engine/core/common/businessentities/BootSequence.java
A backend/manager/modules/common/src/test/java/org/ovirt/engine/core/common/businessentities/BootSequenceTest.java
3 files changed, 115 insertions(+), 17 deletions(-)

Approvals:
  Tomas Jelinek: Verified
  Roy Golan: Looks good to me, approved


--
To view, visit http://gerrit.ovirt.org/8077
To unsubscribe, visit http://gerrit.ovirt.org/settings

Gerrit-MessageType: merged
Gerrit-Change-Id: I61d39f8559bcffdc154b0b2c01d5303cf2ff1e1a
Gerrit-PatchSet: 4
Gerrit-Project: ovirt-engine
Gerrit-Branch: master
Gerrit-Owner: Tomas Jelinek <tjelinek at redhat.com>
Gerrit-Reviewer: Roy Golan <rgolan at redhat.com>
Gerrit-Reviewer: Tomas Jelinek <tjelinek at redhat.com>



More information about the Engine-commits mailing list