All of lore.kernel.org
 help / color / mirror / Atom feed
From: Phillip Susi <psusi@cfl.rr.com>
To: dm-devel@redhat.com, "ATARAID (eg, Promise Fasttrak,
	 Highpoint 370) related discussions" <ataraid-list@redhat.com>,
	linux-lvm@redhat.com
Subject: Re: Re: LVM on dmraid breakage
Date: Fri, 03 Aug 2007 14:10:02 -0400	[thread overview]
Message-ID: <46B36F7A.2090601@cfl.rr.com> (raw)
In-Reply-To: <20070803081133.GB939@percy.comedia.it>

Luca Berra wrote:
> I really have no clue, fortunately dmraid is usually used for boot
> disks, so it should be started before udev has a chance of messing with
> devices. btw, md already does this, and redhat's initrd does this as
> well.

I don't know about redhat, but Ubuntu uses udev in the initramfs. 
Currently the boot scripts wait for udevsettle, then run dmraid and 
pvscan to search out all detected devices, then tries to mount the root 
fs, but this setup is less than ideal.  Our goal is to move towards full 
udev plug and play, where devices are detected by the kernel, processed, 
and as soon as the one(s) needed for the root have been enumerated, 
mount the root fs and run-init.

> The real solution to this is so simple.
> Just ditch the partition detection code from the kernel, and move it to
> userspace where it belongs.
> For the time being use BLKPG_DEL_PARTITION, to undo what the kernel
> should not have done.

I agree with moving the partition detection code to user space, but 
trying to undo it after the fact doesn't help because udev is already 
processing the add events.  Also you do not need to remove the 
partitions so long as pvscan understands that it shouldn't be using them.

> i'd rather not see it coupled with udev :P
> maybe i am limited, but i really fail to see how an event driven model
> could be at all useful in this cases, and i am really convinced that the
> effort needed to make i work is too high compared to possible benefits.
> The biggest question being: How do you know you have scanned all
> possible PV for a given volume group, and you have to activate it.
> Anyway i still think my proposal is sensible and adapts to the current
> paradigm of lvm2.

Udev is supposed to be the new model for enumerating devices and 
performing plug and play actions on them, rather than "ls /dev/hd?".  To 
answer your specific question, lvm would know it has enumerated all the 
required pvs because the vg information tells it how many pvs are 
supposed to be there so it can check the udevdb to see if they have all 
been added yet.  If they have, activate the vg, otherwise do nothing 
until another pv is detected.

The event driven model is useful in that it allows faster boot times ( 
don't need to detect ALL devices before activating and mounting the root 
), and allows runtime plug and play.  Where does lvm store state 
information right now?  In conf files in /etc isn't it?  Why use its own 
database for that when it could just keep the information in udevdb?
Keeping the information in udevdb makes it easily available to things 
like hal in gnome, which in turn allows things like desktop popups when 
a mirror has a drive fail, which changes the state of the vg in udevdb, 
which pushes that update to any monitoring applications.  It also allows 
lvm to share information such as whether or not the device is "claimed" 
with other components, without those components having to be 
specifically aware of lvm and mess with its conf files.  Specifically, 
both dmraid and mdraid ( nor any other future components ) do not have 
to be taught how to edit lvm's conf files to tell it not to access the 
underlying physical disks but to use the virtual devices instead.

  reply	other threads:[~2007-08-03 18:10 UTC|newest]

Thread overview: 55+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2007-08-01 20:19 LVM on dmraid breakage Phillip Susi
2007-08-01 20:29 ` Jonathan Brassow
2007-08-01 21:19   ` Phillip Susi
2007-08-01 21:44     ` Jonathan Brassow
2007-08-01 22:12       ` Chandra Seetharaman
2007-08-02  6:50 ` Luca Berra
2007-08-02  6:50   ` [linux-lvm] " Luca Berra
2007-08-02 10:45   ` Bryn M. Reeves
2007-08-02 10:45     ` [linux-lvm] " Bryn M. Reeves
2007-08-02 21:50     ` Phillip Susi
2007-08-03  0:40       ` David Robinson
2007-08-03  0:40         ` [linux-lvm] Re: [dm-devel] " David Robinson
2007-08-07 21:37         ` Alasdair G Kergon
2007-08-07 21:37           ` [linux-lvm] " Alasdair G Kergon
2007-08-08 21:00           ` Phillip Susi
2007-08-07 21:03       ` Alasdair G Kergon
2007-08-07 21:03         ` [linux-lvm] Re: [dm-devel] " Alasdair G Kergon
2007-08-08 21:04         ` Phillip Susi
2007-08-08 21:45           ` Alasdair G Kergon
2007-08-08 21:45             ` [linux-lvm] Re: [dm-devel] " Alasdair G Kergon
2007-08-09 17:27             ` Phillip Susi
2007-08-10  5:09               ` Luca Berra
2007-08-10  5:09                 ` [linux-lvm] Re: [dm-devel] " Luca Berra
2007-08-10 13:49               ` Alasdair G Kergon
2007-08-10 13:49                 ` [linux-lvm] Re: [dm-devel] " Alasdair G Kergon
2007-08-10 20:15                 ` Phillip Susi
2007-08-03  7:55     ` [linux-lvm] " Luca Berra
2007-08-02 22:04   ` Phillip Susi
2007-08-03  8:11     ` Luca Berra
2007-08-03  8:11       ` [linux-lvm] Re: [dm-devel] " Luca Berra
2007-08-03 18:10       ` Phillip Susi [this message]
2007-08-03 19:57         ` Luca Berra
2007-08-03 19:57           ` [linux-lvm] Re: [dm-devel] " Luca Berra
2007-08-03 21:30           ` Phillip Susi
2007-08-04  6:50             ` [dm-devel] " Luca Berra
2007-08-04  6:50               ` [linux-lvm] " Luca Berra
2007-08-06 14:45               ` Phillip Susi
2007-08-07  9:17                 ` Luca Berra
2007-08-07  9:17                   ` [linux-lvm] Re: [dm-devel] " Luca Berra
2007-08-07 15:58                   ` Phillip Susi
2007-08-07 22:01                   ` Alasdair G Kergon
2007-08-07 22:01                     ` [linux-lvm] Re: [dm-devel] " Alasdair G Kergon
2007-08-08 21:06                     ` Phillip Susi
2007-08-07 21:53             ` Alasdair G Kergon
2007-08-07 21:53               ` [linux-lvm] Re: [dm-devel] " Alasdair G Kergon
2007-08-07 21:50         ` Alasdair G Kergon
2007-08-07 21:50           ` [linux-lvm] Re: [dm-devel] " Alasdair G Kergon
2007-08-07 21:40       ` Alasdair G Kergon
2007-08-07 21:40         ` [linux-lvm] Re: [dm-devel] " Alasdair G Kergon
2007-08-07 21:28     ` Alasdair G Kergon
2007-08-07 21:28       ` [linux-lvm] Re: [dm-devel] " Alasdair G Kergon
2007-08-08 21:13       ` Phillip Susi
2007-08-07 21:02   ` Alasdair G Kergon
2007-08-07 21:02     ` [linux-lvm] " Alasdair G Kergon
2007-08-07 20:52 ` Alasdair G Kergon

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=46B36F7A.2090601@cfl.rr.com \
    --to=psusi@cfl.rr.com \
    --cc=ataraid-list@redhat.com \
    --cc=dm-devel@redhat.com \
    --cc=linux-lvm@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 an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.