Bug 1524424
| Summary: | [downstream clone - 4.1.9] Localdisk hook must prevent VM from being snapshot. | ||
|---|---|---|---|
| Product: | Red Hat Enterprise Virtualization Manager | Reporter: | rhev-integ |
| Component: | ovirt-engine | Assignee: | Fred Rolland <frolland> |
| Status: | CLOSED ERRATA | QA Contact: | Kevin Alon Goldblatt <kgoldbla> |
| Severity: | high | Docs Contact: | |
| Priority: | unspecified | ||
| Version: | 4.1.7 | CC: | amureini, bazulay, ebenahar, frolland, lsurette, lveyde, ratamir, rbalakri, Rhev-m-bugs, srevivo, tnisan, ycui, ykaul, ylavi |
| Target Milestone: | ovirt-4.1.9 | Keywords: | ZStream |
| Target Release: | --- | ||
| Hardware: | x86_64 | ||
| OS: | Linux | ||
| Whiteboard: | |||
| Fixed In Version: | ovirt-engine-4.1.9 | Doc Type: | If docs needed, set a value |
| Doc Text: | Story Points: | --- | |
| Clone Of: | 1513800 | Environment: | |
| Last Closed: | 2018-01-24 14:43:33 UTC | Type: | --- |
| Regression: | --- | Mount Type: | --- |
| Documentation: | --- | CRM: | |
| Verified Versions: | Category: | --- | |
| oVirt Team: | Storage | RHEL 7.3 requirements from Atomic Host: | |
| Cloudforms Team: | --- | Target Upstream Version: | |
| Embargoed: | |||
| Bug Depends On: | 1513800 | ||
| Bug Blocks: | |||
|
Description
rhev-integ
2017-12-11 13:28:34 UTC
Missing from initial comment: [1] https://github.com/oVirt/vdsm/tree/master/vdsm_hooks/localdisk (Originally by Germano Veit Michel) Current fix is to basically collapse the chain down to the base image on the local host, then adjust the DB.
Example:
Volume AAA is the raw , local to the host, image (i.e.: /dev/ovirt-local/...)
Volume BBB is the qcow2, on nfs storage , image (i.e.: /rhev/data-center/...)
Chain is: [BBB - leaf]
[AAA - base]
Steps:
1) VM shutdown (!!!)
2) unsafe rebase of image BBB, make it point to AAA's path (so that step 3 can succeed, otherwise qemu-img commit fails to build the chain)
qemu-img rebase -f qcow2 -t none -u -b AAA -F raw BBB
3) image commit, commit BBB into AAA
qemu-img commit -f qcow2 -t none -b AAA -d -p BBB
4) metadata fix for AAA
sed -i 's/VOLTYPE=INTERNAL/VOLTYPE=LEAF/g' AAA.meta
5) Remove BBB (optional, probably safer to do later)
# rm -rf BBB*
6) Adjust images and snapshots in the DB to make VM with no snapshots and use AAA to start.
(Originally by Germano Veit Michel)
Merged for oVirt 4.2.1 (will be part of RHV 4.2 GA). Fred/Tal - the patch seems simple enough - let's please clone this and provide a fix for 4.1.9 too. (Originally by Allon Mureinik) Verified with the following code: ------------------------------------------ ovirt-engine-4.1.9-0.2.el7.noarch vdsm-4.19.44-1.el7ev.x86_64 Verified with the following scenario: ------------------------------------------ 1. Create VM with local hook 2. Create snapshot >>>>> fails with message indicating that snapshots are not supported on local hook disks Moving to VERIFIED! 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://access.redhat.com/errata/RHBA-2018:0135 BZ<2>Jira re-sync |