[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: [Qemu-devel] Use of PreallocMode in block drivers
From: |
Stefano Garzarella |
Subject: |
Re: [Qemu-devel] Use of PreallocMode in block drivers |
Date: |
Thu, 23 May 2019 15:39:11 +0200 |
User-agent: |
NeoMutt/20180716 |
On Wed, May 22, 2019 at 06:25:17PM +0200, Markus Armbruster wrote:
> Stefano Garzarella <address@hidden> writes:
>
> > On Wed, May 8, 2019 at 1:44 PM Markus Armbruster <address@hidden> wrote:
> >>
> >> Stefano Garzarella <address@hidden> writes:
> >>
> >> > On Tue, May 07, 2019 at 08:34:51AM +0200, Markus Armbruster wrote:
> [...]
> >> >> Let me review support in drivers:
> >> >>
> >> >> * file (file-win32.c)
> >> >> * iscsi
> >> >> * nfs
> >> >> * qed
> >> >> * ssh
> >> >>
> >> >> - Reject all but PREALLOC_MODE_OFF
> >> >>
> >> >> * copy-on-read
> >> >> * luks (crypto.c)
> >> >> * raw
> >> >>
> >> >> - Pass through only
> >> >>
> >> >> * file host_cdrom host_device (file-posix.c)
> >> >>
> >> >> - Reject all but PREALLOC_MODE_OFF when shrinking and for non-regular
> >> >> files
> >> >> - Reject PREALLOC_MODE_FALLOC unless CONFIG_POSIX_FALLOCATE
> >> >> - Reject PREALLOC_MODE_METADATA
> >> >>
> >> >> * gluster
> >> >>
> >> >> - Reject all but PREALLOC_MODE_OFF when shrinking
> >> >> - Reject PREALLOC_MODE_FALLOC unless CONFIG_GLUSTERFS_FALLOCATE
> >> >> - Reject PREALLOC_MODE_FULL unless CONFIG_GLUSTERFS_ZEROFILL
> >> >> - Reject PREALLOC_MODE_METADATA
> >> >>
> >> >> * qcow2
> >> >>
> >> >> - Reject all but PREALLOC_MODE_OFF when shrinking and with a backing
> >> >> file
> >> >>
> >> >> * rbd with this patch
> >> >>
> >> >> - Reject all but PREALLOC_MODE_OFF when shrinking
> >> >> - Reject PREALLOC_MODE_METADATA and PREALLOC_MODE_FALLOC
> >> >>
> >> >> * sheepdog
> >> >>
> >> >> - Reject PREALLOC_MODE_METADATA and PREALLOC_MODE_FALLOC
> >> >> - Doesn't support shrinking
> >> >>
> >> >> * vdi
> >> >>
> >> >> - Reject PREALLOC_MODE_FALLOC and PREALLOC_MODE_FULL
> >> >> - Doesn't support shrinking
> >> >>
> >> >> * blkdebug
> >> >> * blklogwrites
> >> >> * blkverify
> >> >> * bochs
> >> >> * cloop
> >> >> * dmg
> >> >> * ftp
> >> >> * ftps
> >> >> * http
> >> >> * https
> >> >> * luks
> >> >> * nbd
> >> >> * null-aio
> >> >> * null-co
> >> >> * nvme
> >> >> * parallels
> >> >> * qcow
> >> >> * quorum
> >> >> * replication
> >> >> * throttle
> >> >> * vhdx
> >> >> * vmdk
> >> >> * vpc
> >> >> * vvfat
> >> >> * vxhs
> >> >>
> >> >> - These appear not to use PreallocMode: they don't implement
> >> >> .bdrv_co_truncate(), and either don't implement .bdrv_co_create() or
> >> >> implement it without a prealloc parameter.
> >> >>
> >> >> Looks good to me.
> >> >>
> >> >
> >> > Thanks for the analysis!
> [...]
> >> > If you agree, I can check and update the documentation of all drivers
> >> > following
> >> > your analysis.
> >>
> >> Yes, please!
> >
> >
> > Hi Markus,
> > I'm finally updating the documentation of preallocation modes
> > supported by block drivers and protocols in qapi/block-core.json.
> > As sheepdog and vdi I'm adding the supported values for each driver or
> > protocol that supports 'preallocation' parameter during the creation,
> > I'm also updating the '.help' in the QemuOptsList.
> >
> > My doubt is: where is better to put the documentation about
> > preallocation modes supported during the resize? (e.g. some drivers
> > support only PREALLOC_MODE_OFF when shrinking)
>
> As far as I can tell, no driver supports anything but PREALLOC_MODE_OFF
> when shrinking. Suggest to ignore the shrinking case for now when
> documenting.
>
Okay, I'll ignore it for now.
> I'm not sure I fully answered your question. Don't hesitate to ask for
> more advice.
Yes, your answer is what I was looking for :)
Thanks,
Stefano