public inbox for gentoo-user@lists.gentoo.org
 help / color / mirror / Atom feed
* [gentoo-user] why does Udisks require Lvm2 ?
@ 2019-06-22 21:41 Philip Webb
  2019-06-22 21:55 ` Neil Bothwick
  0 siblings, 1 reply; 21+ messages in thread
From: Philip Webb @ 2019-06-22 21:41 UTC (permalink / raw
  To: Gentoo User

I was going to update Udisks from 2.1.8 to 2.8.2
& then saw why I hadn't updated it previously :

  root:526 ~>  emerge -pv udisks
  These are the packages that would be merged, in order:
  emerge: there are no ebuilds built with USE flags to satisfy ">=sys-libs/libblockdev-2.19[cryptsetup,lvm?,vdo?]".
  !!! One of the following packages is required to complete your request:
  - sys-libs/libblockdev-2.20-r2::gentoo (Change USE: +cryptsetup)
  (dependency required by "sys-fs/udisks-2.8.2::gentoo" [ebuild])
  (dependency required by "udisks" [argument])
  
so I tried :

  root:528 ~> USE="cryptsetup" emerge -pvt udisks
  These are the packages that would be merged, in reverse order:
  [ebuild     U  ] sys-fs/udisks-2.8.2:2::gentoo [2.1.8:2::gentoo] USE="-acl (-cryptsetup%) -debug -elogind% (-gptfdisk%) -introspection -lvm% -nls% (-selinux) -systemd -vdo%" 1,552 KiB
  [ebuild  N     ]  sys-libs/libblockdev-2.20-r2::gentoo  USE="-bcache cryptsetup -device-mapper -dmraid -doc -escrow -kbd -lvm -test -vdo" PYTHON_SINGLE_TARGET="-python2_7 -python3_5 python3_6 (-python3_7)" PYTHON_TARGETS="python2_7 -python3_5 python3_6 (-python3_7)" 331 KiB
  [ebuild  N     ]   sys-fs/cryptsetup-2.1.0:0/12::gentoo  USE="-argon2 -gcrypt -kernel -libressl -luks1_default -nettle -nls openssl -pwquality -reencrypt -static -static-libs udev -urandom" 10,413 KiB
  [ebuild  N     ]    sys-fs/lvm2-2.02.184-r4::gentoo  USE="-device-mapper-only -lvm2create_initrd readline -sanlock (-selinux) -static -static-libs -systemd -thin udev" 2,328 KiB
  [ebuild  N     ]   dev-libs/libbytesize-1.4::gentoo  USE="-doc -test" PYTHON_TARGETS="python2_7 -python3_5 python3_6 (-python3_7)" 80 KiB
  [nomerge       ] sys-fs/cryptsetup-2.1.0:0/12::gentoo  USE="-argon2 -gcrypt -kernel -libressl -luks1_default -nettle -nls openssl -pwquality -reencrypt -static -static-libs udev -urandom" 
  [ebuild  N     ]  dev-libs/json-c-0.13.1-r1:0/4::gentoo  USE="-doc -static-libs" ABI_X86="-32 (64) (-x32)" 625 KiB
  [nomerge       ] sys-fs/lvm2-2.02.184-r4::gentoo  USE="-device-mapper-only -lvm2create_initrd readline -sanlock (-selinux) -static -static-libs -systemd -thin udev" 
  [ebuild  N     ]  dev-libs/libaio-0.3.110::gentoo  USE="-static-libs -test" ABI_X86="-32 (64) (-x32)" 42 KiB

I don't use LVM nor do I want to install 'lvm2' :
can anyone suggest why is it required ?

-- 
========================,,============================================
SUPPORT     ___________//___,   Philip Webb
ELECTRIC   /] [] [] [] [] []|   Cities Centre, University of Toronto
TRANSIT    `-O----------O---'   purslowatchassdotutorontodotca



^ permalink raw reply	[flat|nested] 21+ messages in thread

* Re: [gentoo-user] why does Udisks require Lvm2 ?
  2019-06-22 21:41 [gentoo-user] why does Udisks require Lvm2 ? Philip Webb
@ 2019-06-22 21:55 ` Neil Bothwick
  2019-06-22 22:34   ` Grant Taylor
  2019-06-22 23:35   ` [gentoo-user] " Philip Webb
  0 siblings, 2 replies; 21+ messages in thread
From: Neil Bothwick @ 2019-06-22 21:55 UTC (permalink / raw
  To: gentoo-user

[-- Attachment #1: Type: text/plain, Size: 2319 bytes --]

On Sat, 22 Jun 2019 17:41:03 -0400, Philip Webb wrote:

>   root:528 ~> USE="cryptsetup" emerge -pvt udisks
>   These are the packages that would be merged, in reverse order:
>   [ebuild     U  ] sys-fs/udisks-2.8.2:2::gentoo [2.1.8:2::gentoo]
> USE="-acl (-cryptsetup%) -debug -elogind% (-gptfdisk%) -introspection
> -lvm% -nls% (-selinux) -systemd -vdo%" 1,552 KiB [ebuild  N     ]
> sys-libs/libblockdev-2.20-r2::gentoo  USE="-bcache cryptsetup
> -device-mapper -dmraid -doc -escrow -kbd -lvm -test -vdo"
> PYTHON_SINGLE_TARGET="-python2_7 -python3_5 python3_6 (-python3_7)"
> PYTHON_TARGETS="python2_7 -python3_5 python3_6 (-python3_7)" 331 KiB
> [ebuild  N     ]   sys-fs/cryptsetup-2.1.0:0/12::gentoo  USE="-argon2
> -gcrypt -kernel -libressl -luks1_default -nettle -nls openssl
> -pwquality -reencrypt -static -static-libs udev -urandom" 10,413 KiB
> [ebuild  N     ]    sys-fs/lvm2-2.02.184-r4::gentoo
> USE="-device-mapper-only -lvm2create_initrd readline -sanlock
> (-selinux) -static -static-libs -systemd -thin udev" 2,328 KiB [ebuild
> N     ]   dev-libs/libbytesize-1.4::gentoo  USE="-doc -test"
> PYTHON_TARGETS="python2_7 -python3_5 python3_6 (-python3_7)" 80 KiB
> [nomerge       ] sys-fs/cryptsetup-2.1.0:0/12::gentoo  USE="-argon2
> -gcrypt -kernel -libressl -luks1_default -nettle -nls openssl
> -pwquality -reencrypt -static -static-libs udev -urandom" [ebuild
> N     ]  dev-libs/json-c-0.13.1-r1:0/4::gentoo  USE="-doc -static-libs"
> ABI_X86="-32 (64) (-x32)" 625 KiB [nomerge       ]
> sys-fs/lvm2-2.02.184-r4::gentoo  USE="-device-mapper-only
> -lvm2create_initrd readline -sanlock (-selinux) -static -static-libs
> -systemd -thin udev" [ebuild  N     ]  dev-libs/libaio-0.3.110::gentoo
> USE="-static-libs -test" ABI_X86="-32 (64) (-x32)" 42 KiB
> 
> I don't use LVM nor do I want to install 'lvm2' :
> can anyone suggest why is it required ?

The indentation shows that is is a hard dependency of cryptsetup, which
is backed up by reading the ebuild. I expect that it needs the
device-maper functionality provided by lvm, in which case you can set the
device-mapper-only USE flag to avoid installing the full lvm suite.


-- 
Neil Bothwick

The trouble with life is that you are halfway through it before you
realize it's a "do it yourself" thing.

[-- Attachment #2: OpenPGP digital signature --]
[-- Type: application/pgp-signature, Size: 833 bytes --]

^ permalink raw reply	[flat|nested] 21+ messages in thread

* Re: [gentoo-user] why does Udisks require Lvm2 ?
  2019-06-22 21:55 ` Neil Bothwick
@ 2019-06-22 22:34   ` Grant Taylor
  2019-06-23  9:20     ` Neil Bothwick
  2019-06-22 23:35   ` [gentoo-user] " Philip Webb
  1 sibling, 1 reply; 21+ messages in thread
From: Grant Taylor @ 2019-06-22 22:34 UTC (permalink / raw
  To: gentoo-user

On 6/22/19 3:55 PM, Neil Bothwick wrote:
> The indentation shows that is is a hard dependency of cryptsetup, which
> is backed up by reading the ebuild. I expect that it needs the
> device-maper functionality provided by lvm, in which case you can set the
> device-mapper-only USE flag to avoid installing the full lvm suite.

Why isn't device-mapper it's own package‽  One which LVM depends on.

Multi-Path (as in dm-multipath) can easily be used without LVM.


^ permalink raw reply	[flat|nested] 21+ messages in thread

* Re: [gentoo-user] why does Udisks require Lvm2 ?
  2019-06-22 21:55 ` Neil Bothwick
  2019-06-22 22:34   ` Grant Taylor
@ 2019-06-22 23:35   ` Philip Webb
  1 sibling, 0 replies; 21+ messages in thread
From: Philip Webb @ 2019-06-22 23:35 UTC (permalink / raw
  To: gentoo-user

190622 Neil Bothwick wrote:
> On Sat, 22 Jun 2019 17:41:03 -0400, Philip Webb wrote:
>>   root:528 ~> USE="cryptsetup" emerge -pvt udisks
     ...
>> [ebuild  N     ]    sys-fs/lvm2-2.02.184-r4::gentoo
>> USE="-device-mapper-only -lvm2create_initrd readline -sanlock
>> (-selinux) -static -static-libs -systemd -thin udev" 2,328 KiB ...
>> I don't use LVM nor do I want to install 'lvm2' :
>> can anyone suggest why is it required ?
> I expect that it needs the device-maper functionality provided by lvm,
> in which case you can set the device-mapper-only USE flag
> to avoid installing the full lvm suite.

Ok, that looks reasonable : I'll try it.

-- 
========================,,============================================
SUPPORT     ___________//___,   Philip Webb
ELECTRIC   /] [] [] [] [] []|   Cities Centre, University of Toronto
TRANSIT    `-O----------O---'   purslowatchassdotutorontodotca



^ permalink raw reply	[flat|nested] 21+ messages in thread

* Re: [gentoo-user] why does Udisks require Lvm2 ?
  2019-06-22 22:34   ` Grant Taylor
@ 2019-06-23  9:20     ` Neil Bothwick
  2019-06-23 16:01       ` Mick
  2019-06-23 22:35       ` Peter Humphrey
  0 siblings, 2 replies; 21+ messages in thread
From: Neil Bothwick @ 2019-06-23  9:20 UTC (permalink / raw
  To: gentoo-user

[-- Attachment #1: Type: text/plain, Size: 852 bytes --]

On Sat, 22 Jun 2019 16:34:08 -0600, Grant Taylor wrote:

> On 6/22/19 3:55 PM, Neil Bothwick wrote:
> > The indentation shows that is is a hard dependency of cryptsetup,
> > which is backed up by reading the ebuild. I expect that it needs the
> > device-maper functionality provided by lvm, in which case you can set
> > the device-mapper-only USE flag to avoid installing the full lvm
> > suite.  
> 
> Why isn't device-mapper it's own package‽  One which LVM depends on.

No idea, but I'd guess it's got something to do with not reinventing the
wheel. From a maintenance point of view, a USE flag would be less effort
than two packages.

> Multi-Path (as in dm-multipath) can easily be used without LVM.

Which is why the USE flag exists, to avoid installing LVM.


-- 
Neil Bothwick

If I save time, when do I get it back?

[-- Attachment #2: OpenPGP digital signature --]
[-- Type: application/pgp-signature, Size: 833 bytes --]

^ permalink raw reply	[flat|nested] 21+ messages in thread

* Re: [gentoo-user] why does Udisks require Lvm2 ?
  2019-06-23  9:20     ` Neil Bothwick
@ 2019-06-23 16:01       ` Mick
  2019-06-23 22:35       ` Peter Humphrey
  1 sibling, 0 replies; 21+ messages in thread
From: Mick @ 2019-06-23 16:01 UTC (permalink / raw
  To: gentoo-user

[-- Attachment #1: Type: text/plain, Size: 962 bytes --]

On Sunday, 23 June 2019 10:20:58 BST Neil Bothwick wrote:
> On Sat, 22 Jun 2019 16:34:08 -0600, Grant Taylor wrote:
> > On 6/22/19 3:55 PM, Neil Bothwick wrote:
> > > The indentation shows that is is a hard dependency of cryptsetup,
> > > which is backed up by reading the ebuild. I expect that it needs the
> > > device-maper functionality provided by lvm, in which case you can set
> > > the device-mapper-only USE flag to avoid installing the full lvm
> > > suite.
> > 
> > Why isn't device-mapper it's own package‽  One which LVM depends on.
> 
> No idea, but I'd guess it's got something to do with not reinventing the
> wheel. From a maintenance point of view, a USE flag would be less effort
> than two packages.
> 
> > Multi-Path (as in dm-multipath) can easily be used without LVM.
> 
> Which is why the USE flag exists, to avoid installing LVM.

Yes, provided USE="-thin" is set, which is enabled by default.
-- 
Regards,

Mick

[-- Attachment #2: This is a digitally signed message part. --]
[-- Type: application/pgp-signature, Size: 833 bytes --]

^ permalink raw reply	[flat|nested] 21+ messages in thread

* Re: [gentoo-user] why does Udisks require Lvm2 ?
  2019-06-23  9:20     ` Neil Bothwick
  2019-06-23 16:01       ` Mick
@ 2019-06-23 22:35       ` Peter Humphrey
  2019-06-24  0:12         ` Neil Bothwick
  1 sibling, 1 reply; 21+ messages in thread
From: Peter Humphrey @ 2019-06-23 22:35 UTC (permalink / raw
  To: gentoo-user

On Sunday, 23 June 2019 10:20:58 BST Neil Bothwick wrote:
> On Sat, 22 Jun 2019 16:34:08 -0600, Grant Taylor wrote:
> > On 6/22/19 3:55 PM, Neil Bothwick wrote:
> > > The indentation shows that is is a hard dependency of cryptsetup,
> > > which is backed up by reading the ebuild. I expect that it needs the
> > > device-maper functionality provided by lvm, in which case you can set
> > > the device-mapper-only USE flag to avoid installing the full lvm
> > > suite.
> > 
> > Why isn't device-mapper it's own package‽  One which LVM depends on.
> 
> No idea, but I'd guess it's got something to do with not reinventing the
> wheel. From a maintenance point of view, a USE flag would be less effort
> than two packages.
> 
> > Multi-Path (as in dm-multipath) can easily be used without LVM.
> 
> Which is why the USE flag exists, to avoid installing LVM.

But it's not supported.

-- 
Regards,
Peter.





^ permalink raw reply	[flat|nested] 21+ messages in thread

* Re: [gentoo-user] why does Udisks require Lvm2 ?
  2019-06-23 22:35       ` Peter Humphrey
@ 2019-06-24  0:12         ` Neil Bothwick
  2019-06-24  7:36           ` Peter Humphrey
  0 siblings, 1 reply; 21+ messages in thread
From: Neil Bothwick @ 2019-06-24  0:12 UTC (permalink / raw
  To: gentoo-user

[-- Attachment #1: Type: text/plain, Size: 816 bytes --]

On Sun, 23 Jun 2019 23:35:33 +0100, Peter Humphrey wrote:

> > > Why isn't device-mapper it's own package‽  One which LVM depends
> > > on.  
> > 
> > No idea, but I'd guess it's got something to do with not reinventing
> > the wheel. From a maintenance point of view, a USE flag would be less
> > effort than two packages.
> >   
> > > Multi-Path (as in dm-multipath) can easily be used without LVM.  
> > 
> > Which is why the USE flag exists, to avoid installing LVM.  
> 
> But it's not supported.

In what way. I've just tried emerging lvm2 with USE="device-mapper-only
-thin" and it installed the device-mapper stiff but none of the lvm
executables, which seems to be exactly what is wanted.


-- 
Neil Bothwick

If Yoda so strong in force is, why words in right order he cannot put?

[-- Attachment #2: OpenPGP digital signature --]
[-- Type: application/pgp-signature, Size: 833 bytes --]

^ permalink raw reply	[flat|nested] 21+ messages in thread

* Re: [gentoo-user] why does Udisks require Lvm2 ?
  2019-06-24  0:12         ` Neil Bothwick
@ 2019-06-24  7:36           ` Peter Humphrey
  2019-06-24  7:46             ` Neil Bothwick
  0 siblings, 1 reply; 21+ messages in thread
From: Peter Humphrey @ 2019-06-24  7:36 UTC (permalink / raw
  To: gentoo-user

On Monday, 24 June 2019 01:12:07 BST Neil Bothwick wrote:
> On Sun, 23 Jun 2019 23:35:33 +0100, Peter Humphrey wrote:
> > > > Why isn't device-mapper it's own package‽  One which LVM depends
> > > > on.
> > > 
> > > No idea, but I'd guess it's got something to do with not reinventing
> > > the wheel. From a maintenance point of view, a USE flag would be less
> > > effort than two packages.
> > > 
> > > > Multi-Path (as in dm-multipath) can easily be used without LVM.
> > > 
> > > Which is why the USE flag exists, to avoid installing LVM.
> > 
> > But it's not supported.
> 
> In what way. I've just tried emerging lvm2 with USE="device-mapper-only
> -thin" and it installed the device-mapper stiff but none of the lvm
> executables, which seems to be exactly what is wanted.

use.local.desc:sys-fs/lvm2:device-mapper-only - Build only device-mapper and 
not the rest of LVM2 (UNSUPPORTED)

-- 
Regards,
Peter.





^ permalink raw reply	[flat|nested] 21+ messages in thread

* Re: [gentoo-user] why does Udisks require Lvm2 ?
  2019-06-24  7:36           ` Peter Humphrey
@ 2019-06-24  7:46             ` Neil Bothwick
  2019-06-24  8:40               ` Peter Humphrey
  2019-06-24 13:32               ` [gentoo-user] " »Q«
  0 siblings, 2 replies; 21+ messages in thread
From: Neil Bothwick @ 2019-06-24  7:46 UTC (permalink / raw
  To: gentoo-user

[-- Attachment #1: Type: text/plain, Size: 848 bytes --]

On Mon, 24 Jun 2019 08:36:50 +0100, Peter Humphrey wrote:

> > > > Which is why the USE flag exists, to avoid installing LVM.  
> > > 
> > > But it's not supported.  
> > 
> > In what way. I've just tried emerging lvm2 with
> > USE="device-mapper-only -thin" and it installed the device-mapper
> > stiff but none of the lvm executables, which seems to be exactly what
> > is wanted.  
> 
> use.local.desc:sys-fs/lvm2:device-mapper-only - Build only
> device-mapper and not the rest of LVM2 (UNSUPPORTED)

Aha!

So the choice is between an unsupported configuration or installing a
handful of binaries that you will never use. Unless space was an issue,
there's about 6NB difference, I'd go with the latter, although
UNSUPPORTED != DOESNOTWORK


-- 
Neil Bothwick

I've got a Mickey Mouse PC with a Goofy operating system.

[-- Attachment #2: OpenPGP digital signature --]
[-- Type: application/pgp-signature, Size: 833 bytes --]

^ permalink raw reply	[flat|nested] 21+ messages in thread

* Re: [gentoo-user] why does Udisks require Lvm2 ?
  2019-06-24  7:46             ` Neil Bothwick
@ 2019-06-24  8:40               ` Peter Humphrey
  2019-06-24 12:00                 ` Mick
  2019-06-24 15:59                 ` Grant Taylor
  2019-06-24 13:32               ` [gentoo-user] " »Q«
  1 sibling, 2 replies; 21+ messages in thread
From: Peter Humphrey @ 2019-06-24  8:40 UTC (permalink / raw
  To: gentoo-user

On Monday, 24 June 2019 08:46:55 BST Neil Bothwick wrote:

> So the choice is between an unsupported configuration or installing a
> handful of binaries that you will never use. Unless space was an issue,
> there's about 6NB difference, I'd go with the latter, although
> UNSUPPORTED != DOESNOTWORK

Yes, I've done the same on two boxes that have no need of lvm. It does seem 
wasteful though.

I forget the detail now, but a recent-ish version of sys-fs/cryptsetup found 
it needed a hard dependency on some of the code in lvm2. It seems to me that 
we have here an opportunity for redesign of certain packages. ("We" the 
community, that is.)

On this box, which does need lvm for RAID-1 on two SSDs:

$ equery d lvm2
 * These packages depend on lvm2:
app-emulation/virtualbox-6.0.8 (lvm ? sys-fs/lvm2)
net-fs/nfs-utils-2.4.1 (nfsv41 ? sys-fs/lvm2)
sys-block/gparted-0.33.0 (dmraid ? >=sys-fs/lvm2-2.02.45)
sys-block/parted-3.2_p25 (device-mapper ? >=sys-fs/lvm2-2.02.45)
sys-fs/cryptsetup-2.1.0 (sys-fs/lvm2[static-libs(+)])
                        (sys-fs/lvm2)
sys-fs/e2fsprogs-1.45.2 (cron ? sys-fs/lvm2[-device-mapper-only(-)])
sys-fs/udisks-2.8.3 (lvm ? sys-fs/lvm2)
sys-libs/libblockdev-2.22 (device-mapper ? sys-fs/lvm2)
                          (dmraid ? sys-fs/lvm2)
                          (lvm ? sys-fs/lvm2)

Other than sys-fs/cryptsetup, those are all conditional dependencies.

-- 
Regards,
Peter.





^ permalink raw reply	[flat|nested] 21+ messages in thread

* Re: [gentoo-user] why does Udisks require Lvm2 ?
  2019-06-24  8:40               ` Peter Humphrey
@ 2019-06-24 12:00                 ` Mick
  2019-06-24 15:59                 ` Grant Taylor
  1 sibling, 0 replies; 21+ messages in thread
From: Mick @ 2019-06-24 12:00 UTC (permalink / raw
  To: gentoo-user

[-- Attachment #1: Type: text/plain, Size: 2066 bytes --]

On Monday, 24 June 2019 09:40:07 BST Peter Humphrey wrote:
> On Monday, 24 June 2019 08:46:55 BST Neil Bothwick wrote:
> > So the choice is between an unsupported configuration or installing a
> > handful of binaries that you will never use. Unless space was an issue,
> > there's about 6NB difference, I'd go with the latter, although
> > UNSUPPORTED != DOESNOTWORK
> 
> Yes, I've done the same on two boxes that have no need of lvm. It does seem
> wasteful though.
> 
> I forget the detail now, but a recent-ish version of sys-fs/cryptsetup found
> it needed a hard dependency on some of the code in lvm2. It seems to me
> that we have here an opportunity for redesign of certain packages. ("We"
> the community, that is.)
> 
> On this box, which does need lvm for RAID-1 on two SSDs:
> 
> $ equery d lvm2
>  * These packages depend on lvm2:
> app-emulation/virtualbox-6.0.8 (lvm ? sys-fs/lvm2)
> net-fs/nfs-utils-2.4.1 (nfsv41 ? sys-fs/lvm2)
> sys-block/gparted-0.33.0 (dmraid ? >=sys-fs/lvm2-2.02.45)
> sys-block/parted-3.2_p25 (device-mapper ? >=sys-fs/lvm2-2.02.45)
> sys-fs/cryptsetup-2.1.0 (sys-fs/lvm2[static-libs(+)])
>                         (sys-fs/lvm2)
> sys-fs/e2fsprogs-1.45.2 (cron ? sys-fs/lvm2[-device-mapper-only(-)])
> sys-fs/udisks-2.8.3 (lvm ? sys-fs/lvm2)
> sys-libs/libblockdev-2.22 (device-mapper ? sys-fs/lvm2)
>                           (dmraid ? sys-fs/lvm2)
>                           (lvm ? sys-fs/lvm2)
> 
> Other than sys-fs/cryptsetup, those are all conditional dependencies.

Also to mention, the installation following adjustment of the USE flags 
completes like so:
============================================
* Messages for package sys-fs/lvm2-2.02.184-r4:

 * Make sure the "lvm" init script is in the runlevels:
 * # rc-update add lvm boot
 * 
 * Make sure to enable lvmetad in /etc/lvm/lvm.conf if you want
 * to enable lvm autoactivation and metadata caching.
>>> Auto-cleaning packages...
==========================

There is no lvm init script left in my system:

# rc-update -s -v | grep -i lvm
# 

-- 
Regards,

Mick

[-- Attachment #2: This is a digitally signed message part. --]
[-- Type: application/pgp-signature, Size: 833 bytes --]

^ permalink raw reply	[flat|nested] 21+ messages in thread

* [gentoo-user] Re: why does Udisks require Lvm2 ?
  2019-06-24  7:46             ` Neil Bothwick
  2019-06-24  8:40               ` Peter Humphrey
@ 2019-06-24 13:32               ` »Q«
  2019-06-24 14:51                 ` Neil Bothwick
  1 sibling, 1 reply; 21+ messages in thread
From: »Q« @ 2019-06-24 13:32 UTC (permalink / raw
  To: gentoo-user

On Mon, 24 Jun 2019 08:46:55 +0100
Neil Bothwick <neil@digimed.co.uk> wrote:

> On Mon, 24 Jun 2019 08:36:50 +0100, Peter Humphrey wrote:
> 
> > > > > Which is why the USE flag exists, to avoid installing LVM.    
> > > > 
> > > > But it's not supported.    
> > > 
> > > In what way. I've just tried emerging lvm2 with
> > > USE="device-mapper-only -thin" and it installed the device-mapper
> > > stiff but none of the lvm executables, which seems to be exactly
> > > what is wanted.    
> > 
> > use.local.desc:sys-fs/lvm2:device-mapper-only - Build only
> > device-mapper and not the rest of LVM2 (UNSUPPORTED)  
> 
> Aha!
> 
> So the choice is between an unsupported configuration or installing a
> handful of binaries that you will never use. Unless space was an
> issue, there's about 6NB difference, I'd go with the latter, although
> UNSUPPORTED != DOESNOTWORK

My guess is that 'unsupported' in this case means upstream won't bother
to make sure the partial installation will continue to work.  If it
ever does break, I'd expect the Gentoo maintainers to force the flag
off.





^ permalink raw reply	[flat|nested] 21+ messages in thread

* Re: [gentoo-user] Re: why does Udisks require Lvm2 ?
  2019-06-24 13:32               ` [gentoo-user] " »Q«
@ 2019-06-24 14:51                 ` Neil Bothwick
  0 siblings, 0 replies; 21+ messages in thread
From: Neil Bothwick @ 2019-06-24 14:51 UTC (permalink / raw
  To: gentoo-user

[-- Attachment #1: Type: text/plain, Size: 1002 bytes --]

On Mon, 24 Jun 2019 08:32:51 -0500, »Q« wrote:

> > > use.local.desc:sys-fs/lvm2:device-mapper-only - Build only
> > > device-mapper and not the rest of LVM2 (UNSUPPORTED)    
> > 
> > Aha!
> > 
> > So the choice is between an unsupported configuration or installing a
> > handful of binaries that you will never use. Unless space was an
> > issue, there's about 6MB difference, I'd go with the latter, although
> > UNSUPPORTED != DOESNOTWORK  
> 
> My guess is that 'unsupported' in this case means upstream won't bother
> to make sure the partial installation will continue to work.  If it
> ever does break, I'd expect the Gentoo maintainers to force the flag
> off.

Agreed, it basically means it works for now but no guarantees in the
future, which should make it reasonably safe to enable the flag now.
Although I'd be wary of doing that if the OS is installed on an
encrypted filesystem.


-- 
Neil Bothwick

If at first you don't succeed you'll get lots of advice.

[-- Attachment #2: OpenPGP digital signature --]
[-- Type: application/pgp-signature, Size: 833 bytes --]

^ permalink raw reply	[flat|nested] 21+ messages in thread

* Re: [gentoo-user] why does Udisks require Lvm2 ?
  2019-06-24  8:40               ` Peter Humphrey
  2019-06-24 12:00                 ` Mick
@ 2019-06-24 15:59                 ` Grant Taylor
  2019-06-24 17:00                   ` Peter Humphrey
  1 sibling, 1 reply; 21+ messages in thread
From: Grant Taylor @ 2019-06-24 15:59 UTC (permalink / raw
  To: gentoo-user

On 6/24/19 2:40 AM, Peter Humphrey wrote:
> Yes, I've done the same on two boxes that have no need of lvm. It does 
> seem wasteful though.

Probably.

I dislike the fact that other things that need device mapper have to 
drag LVM along, or apply (what I call) a device-mapper-only /hack/.

I feel like device-mapper should be it's own package that other things 
depend on; LVM, RAID (mdadm, et al.), multi-path, LUKS (cryptsetup).

> I forget the detail now, but a recent-ish version of sys-fs/cryptsetup 
> found it needed a hard dependency on some of the code in lvm2.

Did you apply (what I call) the device-mapper-only /hack/.  Or was LVM 
pulled in for device-mapper?

> It seems to me that we have here an opportunity for redesign of certain 
> packages. ("We" the community, that is.)

Agreed.

> On this box, which does need lvm for RAID-1 on two SSDs:

Do you /need/ LVM?  Or is it extra that comes with device-mapper?



-- 
Grant. . . .
unix || die


^ permalink raw reply	[flat|nested] 21+ messages in thread

* Re: [gentoo-user] why does Udisks require Lvm2 ?
  2019-06-24 15:59                 ` Grant Taylor
@ 2019-06-24 17:00                   ` Peter Humphrey
  2019-06-24 17:47                     ` Neil Bothwick
  2019-06-24 18:12                     ` Mick
  0 siblings, 2 replies; 21+ messages in thread
From: Peter Humphrey @ 2019-06-24 17:00 UTC (permalink / raw
  To: gentoo-user

On Monday, 24 June 2019 16:59:08 BST Grant Taylor wrote:
> On 6/24/19 2:40 AM, Peter Humphrey wrote:
> > Yes, I've done the same on two boxes that have no need of lvm. It does
> > seem wasteful though.
> 
> Probably.
> 
> I dislike the fact that other things that need device mapper have to
> drag LVM along, or apply (what I call) a device-mapper-only /hack/.
> 
> I feel like device-mapper should be its own package that other things
> depend on; LVM, RAID (mdadm, et al.), multi-path, LUKS (cryptsetup).

Yes, and that would fit the Unix tradition of doing one thing, and well. It 
should also be applied to crypt-setup and its friends.

> > I forget the detail now, but a recent-ish version of sys-fs/cryptsetup
> > found it needed a hard dependency on some of the code in lvm2.
> 
> Did you apply (what I call) the device-mapper-only /hack/.  Or was LVM
> pulled in for device-mapper?

I didn't know about the hack at the time. I'm hazy about this now, memory not 
being what it was, but I think I was trying to get rid of encryption apps as 
well as lvm on a box that doesn't use either and never will. I'm stuck with 
having both, willy-nilly. As Neil said, though, you could say it's only a 
matter of disk space - until someone finds a vulnerability in them and uses it 
on me.  :(

> > It seems to me that we have here an opportunity for redesign of certain
> > packages. ("We" the community, that is.)
> 
> Agreed.
> 
> > On this box, which does need lvm for RAID-1 on two SSDs:
> Do you /need/ LVM?  Or is it extra that comes with device-mapper?

No, I do actually use lvm to base a raid-1 file system on. I haven't 
considered raid-1 without lvm; is that feasible?

-- 
Regards,
Peter.





^ permalink raw reply	[flat|nested] 21+ messages in thread

* Re: [gentoo-user] why does Udisks require Lvm2 ?
  2019-06-24 17:00                   ` Peter Humphrey
@ 2019-06-24 17:47                     ` Neil Bothwick
  2019-06-24 18:22                       ` Grant Taylor
  2019-06-24 18:12                     ` Mick
  1 sibling, 1 reply; 21+ messages in thread
From: Neil Bothwick @ 2019-06-24 17:47 UTC (permalink / raw
  To: gentoo-user

[-- Attachment #1: Type: text/plain, Size: 1117 bytes --]

On Mon, 24 Jun 2019 18:00:29 +0100, Peter Humphrey wrote:

> > I feel like device-mapper should be its own package that other things
> > depend on; LVM, RAID (mdadm, et al.), multi-path, LUKS (cryptsetup).  
> 
> Yes, and that would fit the Unix tradition of doing one thing, and
> well. It should also be applied to crypt-setup and its friends.

Indeed, all it needs is someone willing to do the work. Now if LVM had
been written by Lennart Poettering, there would be a stampede of
volunteers to do this, witness eudev.

> > > On this box, which does need lvm for RAID-1 on two SSDs:  
> > Do you /need/ LVM?  Or is it extra that comes with device-mapper?  
> 
> No, I do actually use lvm to base a raid-1 file system on. I haven't 
> considered raid-1 without lvm; is that feasible?

Of course it is, a RAID1 device is just a block device on which you can
put any filesystem you like. RAID and LVM are complementary technologies
that work well together, but neither needs the others (apart from the
device-mapper bit).


-- 
Neil Bothwick

The road to HAL is paved with good intentions.

[-- Attachment #2: OpenPGP digital signature --]
[-- Type: application/pgp-signature, Size: 833 bytes --]

^ permalink raw reply	[flat|nested] 21+ messages in thread

* Re: [gentoo-user] why does Udisks require Lvm2 ?
  2019-06-24 17:00                   ` Peter Humphrey
  2019-06-24 17:47                     ` Neil Bothwick
@ 2019-06-24 18:12                     ` Mick
  2019-06-24 18:28                       ` Grant Taylor
  1 sibling, 1 reply; 21+ messages in thread
From: Mick @ 2019-06-24 18:12 UTC (permalink / raw
  To: gentoo-user

[-- Attachment #1: Type: text/plain, Size: 1621 bytes --]

On Monday, 24 June 2019 18:00:29 BST Peter Humphrey wrote:
> On Monday, 24 June 2019 16:59:08 BST Grant Taylor wrote:

> > > On this box, which does need lvm for RAID-1 on two SSDs:
> > Do you /need/ LVM?  Or is it extra that comes with device-mapper?
> 
> No, I do actually use lvm to base a raid-1 file system on. I haven't
> considered raid-1 without lvm; is that feasible?

Almost totally.  They two are separate functions with synergistic interaction.  
RAID 1 offers redundancy by mirroring data between two block devices.  LVM 
offers a flexible partitioning scheme where you can add space, move, snapshot, 
etc. data using a logical software layer to manage their storage across 
partitions and physical disks.  I've put together RAID 1 disks with no LVM and 
used LVM with no RAID.

NOTE: To confuse things you can instead use LVM's built in 'RAID 
functionality' - see below.

I recall reading somewhere that SSDs are better used with LVM's natively 
configured RAID functionality, rather than a separate RAID layer, which in a 
mirrored RAID it will cause accelerated wear due to the way RAID metadata are 
mirrored between block devices.  I don't think I've ever used LVM's RAID 
capability, but it would probably boil down to running:

lvcreate --mirrors 1 --type raid 1 -n LV_myRAID VG_blah-blah

Others more knowledgeable in these technologies could chime in to correct me 
no doubt.

PS.  LVM-RAID uses the kernel's mdraid, but with less tools to manage the RAID 
configuration than mdadm offers:

https://unix.stackexchange.com/questions/150644/raiding-with-lvm-vs-mdraid-pros-and-cons
-- 
Regards,

Mick

[-- Attachment #2: This is a digitally signed message part. --]
[-- Type: application/pgp-signature, Size: 833 bytes --]

^ permalink raw reply	[flat|nested] 21+ messages in thread

* Re: [gentoo-user] why does Udisks require Lvm2 ?
  2019-06-24 17:47                     ` Neil Bothwick
@ 2019-06-24 18:22                       ` Grant Taylor
  2019-06-24 19:04                         ` Neil Bothwick
  0 siblings, 1 reply; 21+ messages in thread
From: Grant Taylor @ 2019-06-24 18:22 UTC (permalink / raw
  To: gentoo-user

On 6/24/19 11:47 AM, Neil Bothwick wrote:
> Of course it is, a RAID1 device is just a block device on which you can 
> put any filesystem you like. RAID and LVM are complementary technologies 
> that work well together, but neither needs the others (apart from the 
> device-mapper bit).

Eh.  LVM can require RAID (multiple devices) without actually using MD 
outside of LVM.

LVM can do RAID inside of LVM (I think this is fairly atypically done). 
But it does mean that you can turn physical disks (or better partitions) 
into Physical Volumes for LVM and then create different Logical Volumes 
with different RAID properties.

I once had a LV w/ RAID 0 striping across multiple PVs with another LV 
with RAID 5 for redundancy, in the same PVs.

This LVM functionality does require RAID (multiple device) support as 
that's what's used /inside/ (read: under the hood) of LVM.



-- 
Grant. . . .
unix || die


^ permalink raw reply	[flat|nested] 21+ messages in thread

* Re: [gentoo-user] why does Udisks require Lvm2 ?
  2019-06-24 18:12                     ` Mick
@ 2019-06-24 18:28                       ` Grant Taylor
  0 siblings, 0 replies; 21+ messages in thread
From: Grant Taylor @ 2019-06-24 18:28 UTC (permalink / raw
  To: gentoo-user

On 6/24/19 12:12 PM, Mick wrote:
> LVM-RAID uses the kernel's mdraid,

Yep.

You can get device mapper command(s) to show the internal / under the 
hood MD devices.

I feel like what LVM does to mirror (RAID 1) devices is complex.  You 
end up with non-obvious LVs that are then raided together to create 
another virtual block device that is what you see as the LV.

There are options about where and how metadata is mirrored.  Some of 
which is stored in the VG and others is stored in another small hidden 
LV specifically for this purpose.  Which itself can be configured to 
have multiple copies.

At least that's how I remember things from about five years ago.

> but with less tools to manage the RAID configuration than mdadm offers:

That's because the standard LVM tools make calls to the kernel to manage 
things.  I never /needed/ anything other than the LVM tools to 
administer LVM RAID.  But I think that you can find the expected things 
under device mapper et al. if you know where to go look.

When I say "hidden", it seems as if the traditional LVM tools simply 
don't expose LVs with specific naming patterns unless you go looking for 
them.  Much like dot files are ""hidden by default, but there if you 
know where and how to look.



-- 
Grant. . . .
unix || die


^ permalink raw reply	[flat|nested] 21+ messages in thread

* Re: [gentoo-user] why does Udisks require Lvm2 ?
  2019-06-24 18:22                       ` Grant Taylor
@ 2019-06-24 19:04                         ` Neil Bothwick
  0 siblings, 0 replies; 21+ messages in thread
From: Neil Bothwick @ 2019-06-24 19:04 UTC (permalink / raw
  To: gentoo-user

[-- Attachment #1: Type: text/plain, Size: 669 bytes --]

On Mon, 24 Jun 2019 12:22:09 -0600, Grant Taylor wrote:

> > Of course it is, a RAID1 device is just a block device on which you
> > can put any filesystem you like. RAID and LVM are complementary
> > technologies that work well together, but neither needs the others
> > (apart from the device-mapper bit).  
> 
> Eh.  LVM can require RAID (multiple devices) without actually using MD 
> outside of LVM.

Can require, not does require. It is perfectly possible to use LVM on a
single disk. There are situations where you use the two together, but no
requirement to do so in all use cases.


-- 
Neil Bothwick

Top Oxymorons Number 35: Legally drunk

[-- Attachment #2: OpenPGP digital signature --]
[-- Type: application/pgp-signature, Size: 833 bytes --]

^ permalink raw reply	[flat|nested] 21+ messages in thread

end of thread, other threads:[~2019-06-24 19:05 UTC | newest]

Thread overview: 21+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2019-06-22 21:41 [gentoo-user] why does Udisks require Lvm2 ? Philip Webb
2019-06-22 21:55 ` Neil Bothwick
2019-06-22 22:34   ` Grant Taylor
2019-06-23  9:20     ` Neil Bothwick
2019-06-23 16:01       ` Mick
2019-06-23 22:35       ` Peter Humphrey
2019-06-24  0:12         ` Neil Bothwick
2019-06-24  7:36           ` Peter Humphrey
2019-06-24  7:46             ` Neil Bothwick
2019-06-24  8:40               ` Peter Humphrey
2019-06-24 12:00                 ` Mick
2019-06-24 15:59                 ` Grant Taylor
2019-06-24 17:00                   ` Peter Humphrey
2019-06-24 17:47                     ` Neil Bothwick
2019-06-24 18:22                       ` Grant Taylor
2019-06-24 19:04                         ` Neil Bothwick
2019-06-24 18:12                     ` Mick
2019-06-24 18:28                       ` Grant Taylor
2019-06-24 13:32               ` [gentoo-user] " »Q«
2019-06-24 14:51                 ` Neil Bothwick
2019-06-22 23:35   ` [gentoo-user] " Philip Webb

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox