Hi, I''m running a 3Tb RAIDZ2 array and was wondering about the zfs scrub function. This server runs as my backup server and receives an rsync every night. I was wondering if I _need_ to explicitly run a zfs scrub on my zpool periodically. There''s a lot of info on google about running a scrub but not whether it''s actually needed or under what circumstances you might run one - so I thought I''d ask the list it''s opinions on this. If zfs does a background scrub continually anyways - is there any need to manually run a scrub? I''d imagine a scrub of a 3Tb array would take quite a while (its 7200rpm SATA disks) and if I ran a scrub this would likely overlap with my nightly rsyncs causing yet more I/O. Wouldn''t this stress the disks more? If it is necessary - how often are people running a manually scrub? Once a week? month? regards D -- Douglas Walker Systems Administrator Jones Coulter Young Architects 321 Murray St, Perth WA, 6000
The big win for me in doing a periodic scrub is that in normal operation, ZFS only checks data as it''s read back form the disks. If you don''t periodically scrub, errors that happen over time won''t be caught until I next read that actual data, which might be inconvenient if it''s a long time since the initial data was written. As I have a lot of data that is pretty much only read once or twice after it''s originally written, I could have stuff going bad over time that I don''t know about. Scrubbing makes sure there is a limit on the amount of time between each ''surprise!''. :) I scrub once every month or so, depending on the system. So, in direct answer to your question, No - You don''t *need* to scrub. But - It''s better if you do. ;) My 2c. Nathan. On 10/11/08 11:38 AM, Douglas Walker wrote:> Hi, > > I''m running a 3Tb RAIDZ2 array and was wondering about the zfs scrub > function. > > This server runs as my backup server and receives an rsync every night. > > I was wondering if I _need_ to explicitly run a zfs scrub on my zpool > periodically. > > There''s a lot of info on google about running a scrub but not whether > it''s actually needed or under what circumstances you might run one - > so I thought I''d ask the list it''s opinions on this. > > If zfs does a background scrub continually anyways - is there any need > to manually run a scrub? > > I''d imagine a scrub of a 3Tb array would take quite a while (its 7200rpm > SATA disks) and if I ran a scrub this would likely overlap with my > nightly rsyncs causing yet more I/O. Wouldn''t this stress the disks more? > > If it is necessary - how often are people running a manually scrub? Once > a week? month? > > > regards > > > D >-- ////////////////////////////////////////////////////////////////// // Nathan Kroenert nathan.kroenert at sun.com // // Senior Systems Engineer Phone: +61 3 9869 6255 // // Global Systems Engineering Fax: +61 3 9869 6288 // // Level 7, 476 St. Kilda Road // // Melbourne 3004 Victoria Australia // //////////////////////////////////////////////////////////////////
On Mon, 10 Nov 2008, Douglas Walker wrote:> > I was wondering if I _need_ to explicitly run a zfs scrub on my zpool > periodically.It is a very wise idea to perform a periodic scrub of your pool. This should substantially decrease the actual risk of data loss.> If zfs does a background scrub continually anyways - is there any need > to manually run a scrub?Zfs does not do a background scrub. It only verifies data as it is read, and performs corrections if there is a redundant good copy.> If it is necessary - how often are people running a manually scrub? Once > a week? month?Hard drives don''t wear out from being used. I have cron jobs set up to scrub my drive array every night and on some USB backup drives, once a week. The only impediments to scrubbing as often as possible is that scrubbing decreases the available disk access performance during the scrub and that taking snapshots resets the scrub from the beginning. Of course there may be more power consumption during a scrub. Bob =====================================Bob Friesenhahn bfriesen at simple.dallas.tx.us, http://www.simplesystems.org/users/bfriesen/ GraphicsMagick Maintainer, http://www.GraphicsMagick.org/