[Libguestfs] [PATCH 2/3] New API: lvm_scan, deprecate vgscan (RHBZ#1602353).

Pino Toscano ptoscano at redhat.com
Thu Jul 19 08:52:23 UTC 2018


On Wednesday, 18 July 2018 15:37:24 CEST Richard W.M. Jones wrote:
> The old vgscan API literally ran vgscan.  When we switched to using
> lvmetad (in commit dd162d2cd56a2ecf4bcd40a7f463940eaac875b8) this
> stopped working because lvmetad now ignores plain vgscan commands
> without the --cache option.
> 
> We documented that vgscan would rescan PVs, VGs and LVs, but without
> activating them.
> 
> I have introduced a new API (lvm_scan) which scans or rescans PVs, VGs
> and LVs.  It has an optional activate parameter allowing activation of
> any new LVs that are found.
> 
> With lvmetad this nicely maps to the single command:
> 
>  pvscan --cache [--activate ay]
> ---

lvm_scan seems basically vgscan + activate -- wouldn't be better to just
add the "activate" optarg to vgscan? After all, if vgscan is deprecated,
and users should migrate to lvm_scan, they can just add a new optarg.

-- 
Pino Toscano
-------------- next part --------------
A non-text attachment was scrubbed...
Name: signature.asc
Type: application/pgp-signature
Size: 833 bytes
Desc: This is a digitally signed message part.
URL: <http://listman.redhat.com/archives/libguestfs/attachments/20180719/ce89faa5/attachment.sig>


More information about the Libguestfs mailing list