linux-lvm.redhat.com archive mirror
 help / color / mirror / Atom feed
From: Julian Andres Klode <julian.klode@canonical.com>
To: Zdenek Kabelac <zkabelac@redhat.com>
Cc: LVM general discussion and development <linux-lvm@redhat.com>
Subject: Re: [linux-lvm] [PATCH] Detect systemd at run-time in 69-dm-lvm-metad.rules
Date: Wed, 31 Jul 2019 11:39:20 +0200	[thread overview]
Message-ID: <20190731093920.pdu3zvxlo7i55gda@jak-t480s> (raw)
In-Reply-To: <01707c6d-1fe3-f52e-47de-b8b13502fd0c@redhat.com>

On Wed, Jul 31, 2019 at 11:21:10AM +0200, Zdenek Kabelac wrote:
> Dne 30. 07. 19 v 17:12 Julian Andres Klode napsal(a):
> > On Tue, Jul 30, 2019 at 05:02:44PM +0200, Zdenek Kabelac wrote:
> > > Dne 25. 07. 19 v 20:49 Julian Andres Klode napsal(a):
> > > > systems might have systemd as their normal init systems, but
> > > > might not be using it in their initramfs; or like Debian, support
> > > > different init systems.
> > > > 
> > > > Detect whether we are running on systemd by checking for /run/systemd/system
> > > > and then change the behavior accordingly.
> > > > 
> > > 
> > > 
> > > Wouldn't it be better to simply disable compiling/using lvmetad on such systems ?
> > 
> > I don't see how this has anything to do with lvmetad. There is no lvmetad
> > anymore.
> 
> The whole point of 'service' for 'pvscan' is to postone activation of DM
> devices outside of udev rule processing.
> 
> So whatever is replacing systemd service in your's systemd-less system must
> provide similar functionality.
> 
> There is currently no way to accept autoactivation capability within
> udev-rule processing.

This has nothing to do with the part of the message you are replying too, and
is nonsense. The code to run pvscan directly is shipped, the change just moves
the decision whether to do that from compile-time to run-time.

> 
> > > HEAD of 2.03 already dropped lvmetad anyway.
> > > 
> > > Do you need any sort of autoactivation in ramdisk ?
> > 
> > Of course we need the PV to be scanned automatically so we can then find
> > the root partition. The root device finding is event-based, we have a tool
> > that listens to udev and waits for 30s for the device to appear, and relies
> > on the events being triggered correctly.
> 
> There is nothing for finding - if you pass root LV into your ramdisk the
> proper command to activate such LV  is   'lvchange -ay vgname/lvname'
> 
> Dracut uses pretty 'navive' algorithm to run such command with whenever any
> new device is found - it's added into lvm2 filters of visible device - once
> it succeeds - it can proceed....
> For the 'initramdisk' functionality this is IMHO good enough.
> (Although there are several very ugly hacks in this code we would like to drop...)

That's a nasty hack.

-- 
debian developer - deb.li/jak | jak-linux.org - free software dev
ubuntu core developer                              i speak de, en

  parent reply	other threads:[~2019-07-31  9:39 UTC|newest]

Thread overview: 12+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2019-07-25 18:49 [linux-lvm] [PATCH] Detect systemd at run-time in 69-dm-lvm-metad.rules Julian Andres Klode
2019-07-30 15:02 ` Zdenek Kabelac
2019-07-30 15:12   ` Julian Andres Klode
2019-07-31  9:21     ` Zdenek Kabelac
2019-07-31  9:33       ` Julian Andres Klode
2019-07-31 10:16         ` Zdenek Kabelac
2019-07-31 10:51           ` Gionatan Danti
2019-07-31 11:12             ` Zdenek Kabelac
2019-07-31  9:39       ` Julian Andres Klode [this message]
2019-07-31 10:22         ` Zdenek Kabelac
2019-07-31 10:41           ` Julian Andres Klode
2019-07-31 11:09             ` Zdenek Kabelac

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=20190731093920.pdu3zvxlo7i55gda@jak-t480s \
    --to=julian.klode@canonical.com \
    --cc=linux-lvm@redhat.com \
    --cc=zkabelac@redhat.com \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).