Re: [libvirt] backing file chains, -blockdev, and storage file autodetection

2020-01-09 Thread Peter Krempa
On Thu, Jan 09, 2020 at 14:47:22 +, Martin Wilck wrote: > On Thu, 2020-01-09 at 14:34 +, Daniel P. Berrangé wrote: [...] > > > > - Run qemu-img rebase to set the backing_fmt > > > > or > > > > - Update the guest XML to set the format value > > > > or > > > > - Update the /etc/lib

Re: [libvirt] backing file chains, -blockdev, and storage file autodetection

2020-01-09 Thread Daniel P . Berrangé
On Thu, Jan 09, 2020 at 02:47:22PM +, Martin Wilck wrote: > On Thu, 2020-01-09 at 14:34 +, Daniel P. Berrangé wrote: > > > > IIUC there are three scenarios at play here > > > > 1. qcow2 file, first level raw backing > > 2. qcow2 file, first level qcow2 backing, no backing > > 3. qcow2

Re: [libvirt] backing file chains, -blockdev, and storage file autodetection

2020-01-09 Thread Martin Wilck
On Wed, 2020-01-08 at 15:49 +, Daniel P. Berrangé wrote: > > I wonder if there's any scope for improving qemu-img here so that it > can 'do the right thing', or at least issue a warning if the suer > doesn't set a backing format. Yes, someone should send a patch that would make qemu-img prin

Re: [libvirt] backing file chains, -blockdev, and storage file autodetection

2020-01-09 Thread Martin Wilck
On Thu, 2020-01-09 at 14:34 +, Daniel P. Berrangé wrote: > > IIUC there are three scenarios at play here > > 1. qcow2 file, first level raw backing > 2. qcow2 file, first level qcow2 backing, no backing > 3. qcow2 file, first level qcow2 backing, with second level backing > > Historicall

Re: [libvirt] backing file chains, -blockdev, and storage file autodetection

2020-01-09 Thread Peter Krempa
On Thu, Jan 09, 2020 at 14:34:08 +, Daniel Berrange wrote: > On Wed, Jan 08, 2020 at 03:46:59PM +0100, Peter Krempa wrote: > > On Wed, Jan 08, 2020 at 13:34:14 +, Martin Wilck wrote: > > > The recent change in libvirt to pass storage arguments to qemu via > > > "-blockdev", explicity passi

Re: [libvirt] backing file chains, -blockdev, and storage file autodetection

2020-01-09 Thread Daniel P . Berrangé
On Wed, Jan 08, 2020 at 03:46:59PM +0100, Peter Krempa wrote: > On Wed, Jan 08, 2020 at 13:34:14 +, Martin Wilck wrote: > > The recent change in libvirt to pass storage arguments to qemu via > > "-blockdev", explicity passing backing file chain information rather > > than relying on qemu to fi

Re: [libvirt] backing file chains, -blockdev, and storage file autodetection

2020-01-08 Thread Peter Krempa
On Wed, Jan 08, 2020 at 15:34:02 +, Martin Wilck wrote: > Hi Peter, > > On Wed, 2020-01-08 at 15:46 +0100, Peter Krempa wrote: > > On Wed, Jan 08, 2020 at 13:34:14 +, Martin Wilck wrote: [...] > > You are right in cases when the backing image is always a backing > > image. > > > > That

Re: [libvirt] backing file chains, -blockdev, and storage file autodetection

2020-01-08 Thread Daniel P . Berrangé
On Wed, Jan 08, 2020 at 03:34:02PM +, Martin Wilck wrote: > Hi Peter, > > On Wed, 2020-01-08 at 15:46 +0100, Peter Krempa wrote: > > On Wed, Jan 08, 2020 at 13:34:14 +, Martin Wilck wrote: > > > The recent change in libvirt to pass storage arguments to qemu via > > > "-blockdev", explicit

Re: [libvirt] backing file chains, -blockdev, and storage file autodetection

2020-01-08 Thread Martin Wilck
Hi Peter, On Wed, 2020-01-08 at 15:46 +0100, Peter Krempa wrote: > On Wed, Jan 08, 2020 at 13:34:14 +, Martin Wilck wrote: > > The recent change in libvirt to pass storage arguments to qemu via > > "-blockdev", explicity passing backing file chain information > > rather > > than relying on qe

Re: [libvirt] backing file chains, -blockdev, and storage file autodetection

2020-01-08 Thread Peter Krempa
On Wed, Jan 08, 2020 at 13:34:14 +, Martin Wilck wrote: > The recent change in libvirt to pass storage arguments to qemu via > "-blockdev", explicity passing backing file chain information rather > than relying on qemu to figure it out, has bitten me quite painfully. I'm sorry for causing thi

[libvirt] backing file chains, -blockdev, and storage file autodetection

2020-01-08 Thread Martin Wilck
The recent change in libvirt to pass storage arguments to qemu via "-blockdev", explicity passing backing file chain information rather than relying on qemu to figure it out, has bitten me quite painfully. I've had the habit for years to use qcow2 with backing chains without specifying the backing