mkinitrd unification across distributions
 help / color / mirror / Atom feed
From: Harald Hoyer <harald-H+wXaHxf7aLQT0dZR+AlfA@public.gmane.org>
To: Colin Guthrie <colin-odJJhXpcy38dnm+yROfE0A@public.gmane.org>,
	initramfs-u79uwXL29TY76Z2rM5mHXA@public.gmane.org
Subject: Re: [PATCH 2/2] crypt: Only write udev rules to unlock when the device is added
Date: Tue, 28 Jan 2014 15:39:52 +0100	[thread overview]
Message-ID: <52E7C138.4060909@redhat.com> (raw)
In-Reply-To: <1388093183-19045-2-git-send-email-colin-odJJhXpcy38dnm+yROfE0A@public.gmane.org>

On 12/26/2013 10:26 PM, Colin Guthrie wrote:
> It seems that when the device is unlocked, it will trigger a change
> event which in turn re-writes the settled job which was diligently
> removed after it was run.
> 
> Due to the previous fix, this isn't crazy important as the triggered
> job should exit, but avoiding this in the first place is still
> desirable.
> ---
> 
> Note, I'm not sure if this is wise or not. The previous patch alone
> fixes the issue, so this is just an efficiency saving. It might be
> that this is needed - e.g. if you have any encrypted volume on top
> of some other mapped device such as RAID, so please only apply this
> patch if you are sure it will not cause regressions!!
> 
> 
> 
>  modules.d/90crypt/parse-crypt.sh | 2 +-
>  1 file changed, 1 insertion(+), 1 deletion(-)
> 
> diff --git a/modules.d/90crypt/parse-crypt.sh b/modules.d/90crypt/parse-crypt.sh
> index a6b5252..cfa6ac9 100755
> --- a/modules.d/90crypt/parse-crypt.sh
> +++ b/modules.d/90crypt/parse-crypt.sh
> @@ -10,7 +10,7 @@ if ! getargbool 1 rd.luks -d -n rd_NO_LUKS; then
>  else
>      {
>          echo 'SUBSYSTEM!="block", GOTO="luks_end"'
> -        echo 'ACTION!="add|change", GOTO="luks_end"'
> +        echo 'ACTION!="add", GOTO="luks_end"'
>      } > /etc/udev/rules.d/70-luks.rules.new
>  
>      LUKS=$(getargs rd.luks.uuid -d rd_LUKS_UUID)
> 

Hmm, dm-devices get only active on "change" :-/ So, if a crypt device is on
another dm-device, the rule would not trigger anymore.

  parent reply	other threads:[~2014-01-28 14:39 UTC|newest]

Thread overview: 11+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2013-12-26 21:26 [PATCH 1/2] crypt: Prevent asking for password multiple times if non-default crypt name is used Colin Guthrie
     [not found] ` <1388093183-19045-1-git-send-email-colin-odJJhXpcy38dnm+yROfE0A@public.gmane.org>
2013-12-26 21:26   ` [PATCH 2/2] crypt: Only write udev rules to unlock when the device is added Colin Guthrie
     [not found]     ` <1388093183-19045-2-git-send-email-colin-odJJhXpcy38dnm+yROfE0A@public.gmane.org>
2014-01-14  7:16       ` James Lee
2014-01-28 14:39       ` Harald Hoyer [this message]
     [not found]         ` <52E7C138.4060909-H+wXaHxf7aLQT0dZR+AlfA@public.gmane.org>
2014-01-28 15:41           ` Colin Guthrie
2013-12-27 13:00   ` [PATCH v2] crypt: Prevent asking for password multiple times if non-default crypt name is used Colin Guthrie
     [not found]     ` <1388149248-23146-1-git-send-email-colin-odJJhXpcy38dnm+yROfE0A@public.gmane.org>
2014-01-10 16:55       ` James Lee
     [not found]         ` <52D025F5.1050703-RWYTM8lfiZY4k1Tz1RznXQC/G2K4zDHf@public.gmane.org>
2014-01-13 15:30           ` James Lee
     [not found]             ` <52D40696.4080204-RWYTM8lfiZY4k1Tz1RznXQC/G2K4zDHf@public.gmane.org>
2014-01-17 10:32               ` Colin Guthrie
2014-01-28 14:38       ` Harald Hoyer
     [not found]         ` <52E7C0FD.1030209-H+wXaHxf7aLQT0dZR+AlfA@public.gmane.org>
2014-01-28 15:40           ` Colin Guthrie

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=52E7C138.4060909@redhat.com \
    --to=harald-h+wxahxf7alqt0dzr+alfa@public.gmane.org \
    --cc=colin-odJJhXpcy38dnm+yROfE0A@public.gmane.org \
    --cc=initramfs-u79uwXL29TY76Z2rM5mHXA@public.gmane.org \
    /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