6 ms·
I'd recommend ZFS for working with these kind of arrays; scrub is a command that's easy to regularly schedule, and will only use idle I/O bandwidth (helps that
by lmm 13y ago
I'd recommend ZFS for working with these kind of arrays; scrub is a command that's easy to regularly schedule, and will only use idle I/O bandwidth (helps that the RAID functionality is integrated with the whole filesystem).
If you have an infrequent scrub policy and hit bad sectors on rebuild, it can detect checksum failures and mark specific files as corrupted, rather than declaring all your disks defective. Traditional linux md raid behaviour is particularly bad in this regard: if you have a raid6 configuration and haven't been scrubbing, and then have a single disk failure, all your disks will have a few random isolated bad sectors (i.e. sectors that will URE when you attempt to read them) on, but since you still have one disk's worth of parity it's possible to recover all your data with no downtime (and with ZFS raidz2 this is what would happen). But with md raid as soon as you hit those bad sectors during the rebuild it will consider those drives as failing and kick them out of the array, and since all your drives have at least one bad sector on that means it's impossible to recover the array.
- xb95 13y agoWell, scrubbing with md is pretty easy, too. That said, ZFS sounds great, and I've been meaning to learn it sometime. The big thing holding me off has been just -- well, how much time I've put into learning md and such, and how I would find it hard to justify going back to not knowing much (since this is my livelihood). If you have any tips on "read this, it's a good intro" stuff (slanted to Linux, as that's my cuppa), I'd welcome them.
- lmm 13y agoI'm no expert, just a satisfied user; I got into it from the FreeBSD side, and followed their tutorials, but I don't know how well they'd apply to Linux. In general I like the Gentoo and Arch wikis, particularly for slightly lower-level things like this - even if one is using a different distribution, they tend to take the time and explain the concepts in a way that's mostly distribution-independent. I will say that ZFS felt very coherent and even - dare I say it - easy. I was worried that merging layers that I'm used to thinking of as separate would mean a loss of control, but I was able to put together all the layouts I wanted. The various commands with a single interface felt a lot like using lvm2 - different tools but under a unifying structure with the same parameters - and a lot of what it does is lvm-like. So my best tip is to approach it more as an LVM that can also do raid-like functionality and be mounted directly, rather than as a raid system that includes volume management. Sorry if that's not terribly helpful - as I said, I'm not an expert, but I wanted to at least give you some kind of reply.
- markeganfuller 13y ago+1 for the Arch wiki. Despite being a distro wiki they have very nice in depth and distro-independent pages. I use Debian but regularly read through the Arch wiki when trying to do new stuff.
- ars 13y ago> and will only use idle I/O bandwidth You should also be doing a nightly SMART disk test, and that too will also only use idle I/O bandwidth. All my servers do a short test nightly, and a long (i.e. read the entire disk) weekly (during the lowest usage period for each site). On linux install smartmontools then add -s (S/../.././08|L/../../6/00) to /etc/smartd.conf (adjust the hour and dow for your needs). This will both schedule the tests and keep an eye on them to make sure if there are any errors you will be told about it. (Use the test email command at least once and check!) (Make sure the hour when you schedule the two tests doesn't overlap - if one test is in progress the other won't run, so you may end up never running the long test if you do it wrong - although smartd will tell you about it if that happens.)
- pja 13y agoLike ZFS, Btrfs will scrub the filesystem on request too. Worth considering.
- tjoff 13y agoJust as all hardware and all software RAID solutions as well. Although, unlike btrfs, ZFS and a lot of other RAID solutions are considered safe for production use. (while I'm a huge fan of btrfs I've already been waiting many years for it to become stable and the wait is far from over...)
- pja 13y agoTBH, it's probably good enough at this point in time. ext3 didn't really become 'stable' until Rusty stopped developing it and moved on to ext4 :)
- tjoff 13y agoIt's a bit different with a file system that still undergoes heavy development of basic features... http://www.anchor.com.au/blog/2013/04/the-btrfs-backup-experiment/ http://www.anchor.com.au/blog/2013/04/the-btrfs-backup-exper... Just don't use btrfs where a failure is going to hurt.
- pja 13y agoThat blog post seems remarkably positive to me: "We thrashed this filesystem and pushed some little used features really hard & found a few showstopper bugs that crop up for our use case. We lost no data & discovered a RAID array error that hadn't been picked up before. In summary, btrfs is great, but we can't use it yet."
- tjoff 13y agoYes, it was better than what I would expect. But it completely baffles me that anyone saying that that article seems remarkably positive at the same time as saying btrfs is stable...