The Wayback Machine - https://web.archive.org/web/20110823190119/http://opensolaris.org/jive/thread.jspa?messageID=417776

OpenSolaris

Collectives Discussions Documentation Download Source Browser

Home » OpenSolaris Forums » zfs » zfs-discuss

Thread: Adding new disks and ditto block behaviour

Welcome, Guest Help
Login Login
Guest Settings Guest Settings
Reply to this Thread Reply to this Thread Search Forum Search Forum Back to Thread List Back to Thread List

Permlink Replies: 3 - Last Post: Sep 18, 2009 6:48 AM by: sqeaky
sqeaky

Posts: 3
From:

Registered: 9/17/09
Adding new disks and ditto block behaviour
Posted: Sep 17, 2009 9:45 AM
To: OpenSolaris » discuss
Cc: Communities » zfs » zfs-discuss
  Click to reply to this thread Reply

I have machine that had 2x 1TB drives in it. They were in the same zpool and that entire zpool is set to "copies=2". From what I understand this will store all my data twice, and if the SPA is doing its job right it will store the copies on different disks and store the checksum for any given block on the other disk.

I filled this with data. So I added a 1.5 TB drive to the pool. Where will my ditto blocks and checksums go? Will it migrate data from the other drives automatically? Will it migrate data if I scrub or re-silver? will it never migrate data and just store all the new blocks and checksums on the new drive?

I am interested in making sure that a single drive failure will not cause loss of data, what should I do if anything?

cgaspar

Posts: 86
From:

Registered: 9/14/05
Re: [zfs-discuss] Adding new disks and ditto block behaviour
Posted: Sep 17, 2009 10:17 AM   in response to: sqeaky

  Click to reply to this thread Reply

Joe Toppi wrote:
> I have machine that had 2x 1TB drives in it. They were in the same zpool and
> that entire zpool is set to "copies=2". From what I understand this will
> store all my data twice, and if the SPA is doing its job right it will store
> the copies on different disks and store the checksum for any given block on
> the other disk.
>
> I filled this with data. So I added a 1.5 TB drive to the pool. Where will my
> ditto blocks and checksums go? Will it migrate data from the other drives
> automatically? Will it migrate data if I scrub or re-silver? will it never
> migrate data and just store all the new blocks and checksums on the new
> drive?
>
> I am interested in making sure that a single drive failure will not cause
> loss of data, what should I do if anything?

Use mirrors, raidz1, or raidz2. copies=2 will _not_ help you in case of drive
failure, as the pool will refuse to import.

--
Carson
_______________________________________________
zfs-discuss mailing list
zfs-discuss at opensolaris dot org
http://mail.opensolaris.org/mailman/listinfo/zfs-discuss


bfriesen

Posts: 1,250
From: US

Registered: 8/19/08
Re: [zfs-discuss] Adding new disks and ditto block behaviour
Posted: Sep 17, 2009 6:12 PM   in response to: sqeaky

  Click to reply to this thread Reply

On Thu, 17 Sep 2009, Joe Toppi wrote:

> I filled this with data. So I added a 1.5 TB drive to the pool.
> Where will my ditto blocks and checksums go? Will it migrate data
> from the other drives automatically? Will it migrate data if I scrub
> or re-silver? will it never migrate data and just store all the new
> blocks and checksums on the new drive?

Zfs does not automatically migrate data just because you added more
drives. Scrub will only migrate failing data blocks. Resilver
clones a failing disk. When a vdev becomes very full, more writes
will be directed to the empty devices.

If you have enough free disk space to store everything you had before,
plus lots of space to spare, you could try creating a new filesystem
in the pool and using zfs send to send from the existing filesystem to
the new filesystem, and then destroy the old filesystem once you are
satisified with the new one. This would only work if there is
considerably more free space than existing data and the result will
still be lop-sided.

If you have a whole lot of reliable storage space elsewhere, you could
use zfs send to send to a file in that other storage space, destroy
the old filesystem, and then recreate it with your zfs send file.

Bob
--
Bob Friesenhahn
bfriesen at simple dot dallas dot tx dot us, http://www.simplesystems.org/users/bfriesen/
GraphicsMagick Maintainer, http://www.GraphicsMagick.org/
_______________________________________________
zfs-discuss mailing list
zfs-discuss at opensolaris dot org
http://mail.opensolaris.org/mailman/listinfo/zfs-discuss


sqeaky

Posts: 3
From:

Registered: 9/17/09
Re: [zfs-discuss] Adding new disks and ditto block behaviour
Posted: Sep 18, 2009 6:48 AM   in response to: bfriesen

  Click to reply to this thread Reply

Yeah, after I learned that ditto blocks don't protect against failed
drives, I started working on a plan to move to raidz. I couldn't find
any good documentation on setting multiple filesystems systems in one
pool, though I know it is possible. I think I have enough storage to
work this together somehow, but I think I need to read more and plan
more.

Thanks for your response

On Thu, Sep 17, 2009 at 8:12 PM, Bob Friesenhahn
<bfriesen at simple dot dallas dot tx dot us> wrote:
> On Thu, 17 Sep 2009, Joe Toppi wrote:
>
>> I filled this with data. So I added a 1.5 TB drive to the pool. Where will
>> my ditto blocks and checksums go? Will it migrate data from the other drives
>> automatically? Will it migrate data if I scrub or re-silver? will it never
>> migrate data and just store all the new blocks and checksums on the new
>> drive?
>
> Zfs does not automatically migrate data just because you added more drives.
>  Scrub will only migrate failing data blocks.  Resilver clones a failing
> disk.  When a vdev becomes very full, more writes will be directed to the
> empty devices.
>
> If you have enough free disk space to store everything you had before, plus
> lots of space to spare, you could try creating a new filesystem in the pool
> and using zfs send to send from the existing filesystem to the new
> filesystem, and then destroy the old filesystem once you are satisified with
> the new one.  This would only work if there is considerably more free space
> than existing data and the result will still be lop-sided.
>
> If you have a whole lot of reliable storage space elsewhere, you could use
> zfs send to send to a file in that other storage space, destroy the old
> filesystem, and then recreate it with your zfs send file.
>
> Bob
> --
> Bob Friesenhahn
> bfriesen at simple dot dallas dot tx dot us, http://www.simplesystems.org/users/bfriesen/
> GraphicsMagick Maintainer,    http://www.GraphicsMagick.org/
>



--
- Joe Toppi
(402) 714-7539
toppij at gmail dot com
http://www.assuredts.com/toppij/
_______________________________________________
zfs-discuss mailing list
zfs-discuss at opensolaris dot org
http://mail.opensolaris.org/mailman/listinfo/zfs-discuss





Terms of Use | Privacy | Trademarks | Copyright Policy | Site Guidelines
Your use of this web site or any of its content or software indicates your agreement to be bound by these Terms of Use.
© 2010, Oracle Corporation and/or its affiliates

Oracle Logo