[Libguestfs] [PATCH v2] lib: add support for disks with 4096 bytes sector size

Richard W.M. Jones rjones at redhat.com
Tue Feb 11 17:27:51 UTC 2020


On Tue, Feb 11, 2020 at 06:16:25PM +0200, Nikolay Ivanets wrote:
> вт, 11 лют. 2020 о 17:20 Richard W.M. Jones <rjones at redhat.com> пише:
> >
> > I pushed this with some trailing whitespace fixes, and I dropped the
> > change to tmp/.gitignore since the test does clean up after itself.  I
> > also fixed test-qemu-drive-with-blocksize-libvirt.sh so it doesn't
> > actually open /dev/sda etc on the host (don't run tests as root!)
> 
> Thanks!
> 
> > However ...
> >
> > We already use blocksize as an optional parameter to mkfs.  While they
> > don't directly conflict, it is confusing.  Is there a reason we
> > shouldn't call this new parameter "sectorsize"?
> >
> > We can change the parameter name any time up til we make the next
> > stable release.
> 
> But mkfs has 'sectorsize' optional parameter as well. :-)
> Here are my thoughts:
> 1. Our 'blocksize' parameter is related to disks and it's using everywhere in
> context of disks.  It hardly can confuse users with mkfs' blocksize which is
> related to a file system.
> 2. Under the hood this parameter is tied to physical/logical block size so it
> named accordingly.

OK fair enough.  I didn't spot that it had "sectorsize" too.
Let's leave it alone.

Rich.

-- 
Richard Jones, Virtualization Group, Red Hat http://people.redhat.com/~rjones
Read my programming and virtualization blog: http://rwmj.wordpress.com
virt-builder quickly builds VMs from scratch
http://libguestfs.org/virt-builder.1.html




More information about the Libguestfs mailing list