On Tue, Sep 27, 2005 at 05:23:41PM +0800, KC (PacificNet) wrote: > Hi Heinz, > > I want to write a script the when the harddisk have a problem then it would > send emial to me. I use the dmraid -s cmd to get the status and using the > following script to send a emial alert to me. > > emailList=kc.wong@xxxxxxxxxxxxxx > > check=`dmraid -s | grep "status : ok"` > echo $check > /tmp/raidcheck > if [ "$check" = "" ] > then > dmraid -s | mail -s "shksa raid's 71h status is not ok" $emailList > > > the script can work when i execute once. but the script callnot work when I > execute as cron job. > */5 * * * * sh /script/checkHD.sh > > I find the the parameter cannot get parameter. Can u help me? I assume that PATH isn't defined properly to execute dmraid. Find out by redirecting checkHD.sh stderr to a file. Regards, Heinz > > Thanks > KC > > ----- Original Message ----- > From: "Heinz Mauelshagen" <mauelshagen@xxxxxxxxxx> > To: "KC (PacificNet)" <kc.wong@xxxxxxxxxxxxxx> > Cc: <mauelshagen@xxxxxxxxxx>; <ataraid-list@xxxxxxxxxx> > Sent: Friday, September 16, 2005 6:15 PM > Subject: Re: rebuild the harddisk > > > > On Fri, Sep 16, 2005 at 06:07:29PM +0800, KC (PacificNet) wrote: > > > Hi Heinz > > > > > > How can i subscrib the mail list ar? > > > > You can access the archive at > > > > https://listman.redhat.com/archives/ataraid-list/ > > > > Heinz > > > > > > > > Thanks > > > KC > > > ----- Original Message ----- > > > From: "Heinz Mauelshagen" <mauelshagen@xxxxxxxxxx> > > > To: "KC (PacificNet)" <kc.wong@xxxxxxxxxxxxxx> > > > Cc: <ataraid-list@xxxxxxxxxx>; <Mauelshagen@xxxxxxxxxx> > > > Sent: Friday, September 16, 2005 5:50 PM > > > Subject: Re: rebuild the harddisk > > > > > > > > > > > > > > KC, > > > > > > > > you need to use the Silicon Image BIOS to rebuild the set today. > > > > A dmraid extension to cover this will be added in the future. > > > > > > > > Make sure, that sdb is actually sane (iw, run badblocks on it) or > replace > > > it. > > > > > > > > Regards, > > > > Heinz > > > > > > > > On Fri, Sep 16, 2005 at 11:52:02AM +0800, KC (PacificNet) wrote: > > > > > Dear all, > > > > > > > > > > When one of the harddisk need to rebuild. What is the command to > rebuild > > > it? > > > > > > > > > > > > > > > /dev/sda: sil, "sil_afaiagafdcfabgja", mirror, ok, 240119680 > sectors, > > > data@ 0 > > > > > /dev/sdb: sil, "sil_afaiagafdcfabgja", mirror, broken, 240119680 > > > sectors, data@ 0 > > > > > > > > > > ----- Original Message ----- > > > > > From: KC (PacificNet) > > > > > To: ataraid-list@xxxxxxxxxx > > > > > Sent: Friday, September 16, 2005 11:47 AM > > > > > Subject: rebuild the harddisk > > > > > > > > > > > > > > > Dear all, > > > > > > > > > > When one of the harddisk need to rebuild. What is the command to > > > rebuild it? > > > > > > > > > > > > > > > /dev/sda: sil, "sil_afaiagafdcfabgja", mirror, ok, 240119680 > sectors, > > > data@ 0 > > > > > /dev/sdb: sil, "sil_afaiagafdcfabgja", mirror, broken, 240119680 > > > sectors, data@ 0 > > > > > > > > > > > > > > > Thanks > > > > > KC =-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=- Heinz Mauelshagen Red Hat GmbH Consulting Development Engineer Am Sonnenhang 11 Cluster and Storage Development 56242 Marienrachdorf Germany Mauelshagen@xxxxxxxxxx +49 2626 141200 FAX 924446 =-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=- _______________________________________________ Ataraid-list@xxxxxxxxxx https://www.redhat.com/mailman/listinfo/ataraid-list