Why "mdadm --monitor --program" sometimes only gives 2 command-line arguments to the program?

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



Hi all,

I need to monitor my RAID and if it fails, I'd like to call my-script to
deal with the failure.

I did: 
mdadm --monitor --program my-script --delay 60 /dev/md1

And then, I simulate a failure with
mdadm --manage --set-faulty /dev/md1 /dev/sda2
mdadm /dev/md1 --remove /dev/sda2

I hope the mdadm monitor function can pass all three command-line
arguments to my-script, including the name of the event, the name of the
md device and the name of a related device if relevant.

But my-script doesn't get the third one, which should be /dev/sda2. Is
this not "relevant"?

If I really need to know it's /dev/sda2 that fails, what can I do?

Thanks.


-- 
View this message in context: http://www.nabble.com/Why-%22mdadm---monitor---program%22-sometimes-only-gives-2-command-line-arguments-to-the-program--tp14642331p14642331.html
Sent from the linux-raid mailing list archive at Nabble.com.

-
To unsubscribe from this list: send the line "unsubscribe linux-raid" in
the body of a message to majordomo@xxxxxxxxxxxxxxx
More majordomo info at  http://vger.kernel.org/majordomo-info.html

[Index of Archives]     [Linux RAID Wiki]     [ATA RAID]     [Linux SCSI Target Infrastructure]     [Linux Block]     [Linux IDE]     [Linux SCSI]     [Linux Hams]     [Device Mapper]     [Device Mapper Cryptographics]     [Kernel]     [Linux Admin]     [Linux Net]     [GFS]     [RPM]     [git]     [Yosemite Forum]


  Powered by Linux