Group: comp.os.linux.hardware


Subject: Hardware RAID -- how to know when a disk is bad
From: Ignoramus19538
Date: 11/1/2007 10:29:51 AM
If I have a linux system with a hardware raid... (RAID 5). The point of this, as you know is to preserve the data when one disk goes bad. I want to know as soon as possible when a disk is bad, so that I can replace it before any other disks die. How can I check that with linux, programmatically, in scripts? if /usr/bin/is-raid-bad /dev/raid; then echo Raid is bad, replace drive ASAP | Mail -s EMERGENCY root fi obviously there is no program /usr/bin/is-raid-bad, bus is there something out there that I could use? thanks i

Subject: Hardware RAID -- how to know when a disk is bad
From: Keith Keller
Date: 11/1/2007 3:13:31 PM
On 2007-11-01, Ignoramus19538 <ignoramus19538@NOSPAM.19538.invalid> wrote: > If I have a linux system with a hardware raid... (RAID 5). The point > of this, as you know is to preserve the data when one disk goes bad. > > I want to know as soon as possible when a disk is bad, so that I can > replace it before any other disks die. > > How can I check that with linux, programmatically, in scripts? > > if /usr/bin/is-raid-bad /dev/raid; then > echo Raid is bad, replace drive ASAP | Mail -s EMERGENCY root > fi > > obviously there is no program /usr/bin/is-raid-bad, bus is there > something out there that I could use? As others have already mentioned, it depends on the controller. Check the manufacturer's web site to see if they have software. 3ware definitely does; Adaptec does for at least some of their cards. --keith -- kkeller-usenet@wombat.san-francisco.ca.us (try just my userid to email me) AOLSFAQ=http://www.therockgarden.ca/aolsfaq.txt see X- headers for PGP signature information

Subject: Hardware RAID -- how to know when a disk is bad
From: Ignoramus19538
Date: 11/1/2007 7:58:55 PM
On 2007-11-01, Henrik Carlqvist <Henrik.Carlqvist@deadspam.com> wrote: > Ignoramus19538 <ignoramus19538@NOSPAM.19538.invalid> wrote: >> If I have a linux system with a hardware raid... (RAID 5). The point >> of this, as you know is to preserve the data when one disk goes bad. >> >> I want to know as soon as possible when a disk is bad, so that I can >> replace it before any other disks die. > > Most hardware raid systems tell you this by some red LED, a buzzer or > maybe you can see it from a terminal program connected to a serial port on > the raid system. The computer will be unattended in a server room. LEDs are of no help. > >> How can I check that with linux, programmatically, in scripts? > > This depends completely on your hardware. > > Another thing to consider is to run RAID 5 with one or more hot spare > disks, or if you are really careful you might even want to run RAID 6 > instead. But again, support for hot spare disks and RAID 6 depends on your > hardware. I was hoping that there is something simple. i

Subject: Hardware RAID -- how to know when a disk is bad
From: Ignoramus19538
Date: 11/1/2007 7:59:17 PM
On 2007-11-01, Keith Keller <kkeller-usenet@wombat.san-francisco.ca.us> wrote: > On 2007-11-01, Ignoramus19538 <ignoramus19538@NOSPAM.19538.invalid> wrote: >> If I have a linux system with a hardware raid... (RAID 5). The point >> of this, as you know is to preserve the data when one disk goes bad. >> >> I want to know as soon as possible when a disk is bad, so that I can >> replace it before any other disks die. >> >> How can I check that with linux, programmatically, in scripts? >> >> if /usr/bin/is-raid-bad /dev/raid; then >> echo Raid is bad, replace drive ASAP | Mail -s EMERGENCY root >> fi >> >> obviously there is no program /usr/bin/is-raid-bad, bus is there >> something out there that I could use? > > As others have already mentioned, it depends on the controller. Check > the manufacturer's web site to see if they have software. 3ware > definitely does; Adaptec does for at least some of their cards. > > This will be a 3ware controller!!! i

Subject: Hardware RAID -- how to know when a disk is bad
From: Robert Heller
Date: 11/2/2007 4:10:17 PM
At Thu, 01 Nov 2007 10:29:51 -0500 Ignoramus19538 <ignoramus19538@NOSPAM.19538.invalid> wrote: > > If I have a linux system with a hardware raid... (RAID 5). The point > of this, as you know is to preserve the data when one disk goes bad. > > I want to know as soon as possible when a disk is bad, so that I can > replace it before any other disks die. > > How can I check that with linux, programmatically, in scripts? > > if /usr/bin/is-raid-bad /dev/raid; then > echo Raid is bad, replace drive ASAP | Mail -s EMERGENCY root > fi > > obviously there is no program /usr/bin/is-raid-bad, bus is there > something out there that I could use? If you are using a DAC960 flavor controller (Mylex), the DAC960 driver provides a status 'file' under /proc/rd/... that contains this information. I've written a pair of Tcl scripts (one console-based, one GUI-based) that provide a friendly front end. http://freshmeat.net/projects/mylexui/ > > thanks > > i > -- Robert Heller -- Get the Deepwoods Software FireFox Toolbar! Deepwoods Software -- Linux Installation and Administration http://www.deepsoft.com/ -- Web Hosting, with CGI and Database heller@deepsoft.com -- Contract Programming: C/C++, Tcl/Tk