linux-hotplug.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
* MD removal and condition code bug
@ 2009-02-05  7:43 Harald Hoyer
  2009-02-05 11:35 ` Kay Sievers
                   ` (3 more replies)
  0 siblings, 4 replies; 5+ messages in thread
From: Harald Hoyer @ 2009-02-05  7:43 UTC (permalink / raw)
  To: linux-hotplug

Radek Vykydal <rvykydal@redhat.com> encountered a problem with md devices. If 
the raid is about to be removed a "change" and "remove" event is sent.
The "change" event has to be skipped if ATTR{md/array_state} is empty, but 
somehow the condition does not match, which might point to a bug in the 
condition code.
The following patch is needed:

< ATTR{md/array_state}="|clear|inactive", GOTO="md_end"
---
 > ATTR{md/array_state}="clear|inactive", GOTO="md_end"
 > ATTR(md/array_state}!="?*", GOTO="md_end"

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

* Re: MD removal and condition code bug
  2009-02-05  7:43 MD removal and condition code bug Harald Hoyer
@ 2009-02-05 11:35 ` Kay Sievers
  2009-02-05 11:39 ` Harald Hoyer
                   ` (2 subsequent siblings)
  3 siblings, 0 replies; 5+ messages in thread
From: Kay Sievers @ 2009-02-05 11:35 UTC (permalink / raw)
  To: linux-hotplug

On Thu, Feb 5, 2009 at 08:43, Harald Hoyer <harald@redhat.com> wrote:
> Radek Vykydal <rvykydal@redhat.com> encountered a problem with md devices.
> If the raid is about to be removed a "change" and "remove" event is sent.
> The "change" event has to be skipped if ATTR{md/array_state} is empty, but
> somehow the condition does not match, which might point to a bug in the
> condition code.
> The following patch is needed:
>
> < ATTR{md/array_state}="|clear|inactive", GOTO="md_end"
> ---
>> ATTR{md/array_state}="clear|inactive", GOTO="md_end"
>> ATTR(md/array_state}!="?*", GOTO="md_end"

A non-existent attribute makes the rule always fail. Are you sure, the
second rule will fix the issue? It should also never match, when the
attribute is no longer available. I guess, we need to add a TEST!= key
here.

Thanks,
Kay

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

* Re: MD removal and condition code bug
  2009-02-05  7:43 MD removal and condition code bug Harald Hoyer
  2009-02-05 11:35 ` Kay Sievers
@ 2009-02-05 11:39 ` Harald Hoyer
  2009-02-05 13:18 ` Harald Hoyer
  2009-02-05 13:22 ` Kay Sievers
  3 siblings, 0 replies; 5+ messages in thread
From: Harald Hoyer @ 2009-02-05 11:39 UTC (permalink / raw)
  To: linux-hotplug

Kay Sievers wrote:
> On Thu, Feb 5, 2009 at 08:43, Harald Hoyer <harald@redhat.com> wrote:
>> Radek Vykydal <rvykydal@redhat.com> encountered a problem with md devices.
>> If the raid is about to be removed a "change" and "remove" event is sent.
>> The "change" event has to be skipped if ATTR{md/array_state} is empty, but
>> somehow the condition does not match, which might point to a bug in the
>> condition code.
>> The following patch is needed:
>>
>> < ATTR{md/array_state}="|clear|inactive", GOTO="md_end"
>> ---
>>> ATTR{md/array_state}="clear|inactive", GOTO="md_end"
>>> ATTR(md/array_state}!="?*", GOTO="md_end"
> 
> A non-existent attribute makes the rule always fail. Are you sure, the
> second rule will fix the issue? It should also never match, when the
> attribute is no longer available. I guess, we need to add a TEST!= key
> here.
> 
> Thanks,
> Kay

The attribute exists, but is empty.

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

* Re: MD removal and condition code bug
  2009-02-05  7:43 MD removal and condition code bug Harald Hoyer
  2009-02-05 11:35 ` Kay Sievers
  2009-02-05 11:39 ` Harald Hoyer
@ 2009-02-05 13:18 ` Harald Hoyer
  2009-02-05 13:22 ` Kay Sievers
  3 siblings, 0 replies; 5+ messages in thread
From: Harald Hoyer @ 2009-02-05 13:18 UTC (permalink / raw)
  To: linux-hotplug

Harald Hoyer wrote:
> Kay Sievers wrote:
>> On Thu, Feb 5, 2009 at 08:43, Harald Hoyer <harald@redhat.com> wrote:
>>> Radek Vykydal <rvykydal@redhat.com> encountered a problem with md 
>>> devices.
>>> If the raid is about to be removed a "change" and "remove" event is 
>>> sent.
>>> The "change" event has to be skipped if ATTR{md/array_state} is 
>>> empty, but
>>> somehow the condition does not match, which might point to a bug in the
>>> condition code.
>>> The following patch is needed:
>>>
>>> < ATTR{md/array_state}="|clear|inactive", GOTO="md_end"
>>> ---
>>>> ATTR{md/array_state}="clear|inactive", GOTO="md_end"
>>>> ATTR(md/array_state}!="?*", GOTO="md_end"
>>
>> A non-existent attribute makes the rule always fail. Are you sure, the
>> second rule will fix the issue? It should also never match, when the
>> attribute is no longer available. I guess, we need to add a TEST!= key
>> here.
>>
>> Thanks,
>> Kay
> 
> The attribute exists, but is empty.

ok.. wrong :) actually it is missing..

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

* Re: MD removal and condition code bug
  2009-02-05  7:43 MD removal and condition code bug Harald Hoyer
                   ` (2 preceding siblings ...)
  2009-02-05 13:18 ` Harald Hoyer
@ 2009-02-05 13:22 ` Kay Sievers
  3 siblings, 0 replies; 5+ messages in thread
From: Kay Sievers @ 2009-02-05 13:22 UTC (permalink / raw)
  To: linux-hotplug

On Thu, Feb 5, 2009 at 14:18, Harald Hoyer <harald@redhat.com> wrote:
> Harald Hoyer wrote:
>> Kay Sievers wrote:
>>> On Thu, Feb 5, 2009 at 08:43, Harald Hoyer <harald@redhat.com> wrote:
>>>>
>>>> Radek Vykydal <rvykydal@redhat.com> encountered a problem with md
>>>> devices.
>>>> If the raid is about to be removed a "change" and "remove" event is
>>>> sent.
>>>> The "change" event has to be skipped if ATTR{md/array_state} is empty,
>>>> but
>>>> somehow the condition does not match, which might point to a bug in the
>>>> condition code.
>>>> The following patch is needed:
>>>>
>>>> < ATTR{md/array_state}="|clear|inactive", GOTO="md_end"
>>>> ---
>>>>>
>>>>> ATTR{md/array_state}="clear|inactive", GOTO="md_end"
>>>>> ATTR(md/array_state}!="?*", GOTO="md_end"
>>>
>>> A non-existent attribute makes the rule always fail. Are you sure, the
>>> second rule will fix the issue? It should also never match, when the
>>> attribute is no longer available. I guess, we need to add a TEST!= key
>>> here.
>>
>> The attribute exists, but is empty.
>
> ok.. wrong :) actually it is missing..

Added the fix to the rules in the udev tree, and sent Neil a mail to
update the rules file in the mdadm package.

Thanks,
Kay

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

end of thread, other threads:[~2009-02-05 13:22 UTC | newest]

Thread overview: 5+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2009-02-05  7:43 MD removal and condition code bug Harald Hoyer
2009-02-05 11:35 ` Kay Sievers
2009-02-05 11:39 ` Harald Hoyer
2009-02-05 13:18 ` Harald Hoyer
2009-02-05 13:22 ` Kay Sievers

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).