Testing Parity Z Raid. Removed drive & no notifications?

Status
Not open for further replies.

RichTJ99

Patron
Joined
Sep 12, 2013
Messages
384
Hi,

I have a HP N40L microserver with 4x 2tb drives. I setup a zraid 1 when I set it up so it gave me about 6tb of storage. I then copied 5.95 tb of data to the drive (videos, etc) all copies of data that can safely be destroyed.

This morning, I shut down the server, removed one of the drives & booted it back up. I didnt get an email notification (which is setup), I logged into the webgui & it didnt mention that the raid array was missing a disk.

When I dug deeper into the view volumes, I do see that it says degraded. I just thought that Freenas would have notified me that I lost a drive. Is it supposed to do that?

I am planning on taking another 2TB drive, putting it in, rebuilding, then removing another drive & putting the original one I removed back in, merely to test how well its rebuilding, etc.

Thanks,
Rich
 

cyberjock

Inactive Account
Joined
Mar 25, 2012
Messages
19,526
Sigh... another one of these threads.

Search for "zfsd" and you'll see responses to this question.
 

RichTJ99

Patron
Joined
Sep 12, 2013
Messages
384
Thanks, I guess the short answer is that Freenas doesnt do that by default, yet. It sounds like there is a script you can run to check the disk status. Is there a newb guide to doing it & getting it working since it is a common request?
 

Dusan

Guru
Joined
Jan 29, 2013
Messages
1,165
Hold it! You do not need zfsd to get warnings. zfs status -x will show DEGRADED status almost immediately. The FreeNAS alerter (alert.py) that drives the alert light in the GUI runs zfs status -x every 5 minutes. Also, the alerter is able and does send emails for CRITICAL messages (test it, remove root password and you will get a warning e-mail). However! I just discovered a bug in how alert.py parses the output of zfs status. The bug causes it to parse everything else than HEALTY as UNKNOWN. UNKNOWN is a WARNING and will only trigger a yellow alert light -- there is no email sent for WARNINGs.
The good news is that the fix is simple and William already merged my pull request (https://github.com/freenas/freenas/pull/30), so next FreeNAS will email you when your pool DEGRADEs.
 

Dusan

Guru
Joined
Jan 29, 2013
Messages
1,165
I tested the fix in a VM and a DEGRADED pool now triggers a red warning light + you receive a warning email within 5 minutes. :)
 

RichTJ99

Patron
Joined
Sep 12, 2013
Messages
384
Do you have any way I could add the fix into my freenas? If you don't mind spoon feeding me!

Or is there some sort of nightly build?
 

survive

Behold the Wumpus
Moderator
Joined
May 28, 2011
Messages
875
Hi RichTJ99,

All you should have to do is edit the alerts.py file on your usb key.

Just mount the key read-write with "mountrw /" & edit /usr/local/www/freenasUI/tools/alert.py

You can find the exact line & what you need to add in Dusan's github commit above.

-Will
 

RichTJ99

Patron
Joined
Sep 12, 2013
Messages
384
So I just add ", re.M)"

Can I do this within the Webgui? If not, do I vi into the file itself?
 

survive

Behold the Wumpus
Moderator
Joined
May 28, 2011
Messages
875
Hi RichTJ99,

That's what I did.....

-Will
 
Status
Not open for further replies.
Top