Skip site navigation (1)Skip section navigation (2)
Date:      Wed, 22 Jan 2014 14:01:40 -0800
From:      Chris Stankevitz <chrisstankevitz@gmail.com>
To:        Dan Nelson <dnelson@allantgroup.com>
Cc:        freebsd-questions@freebsd.org
Subject:   Re: ZFS: pool vs FS
Message-ID:  <CAPi0pstg7X1Y43K_21usCPzn3nDvtaLiMcnV=AS2yNGUT5neMA@mail.gmail.com>
In-Reply-To: <20140122204828.GA6033@dan.emsphone.com>
References:  <CAPi0psvd++LdTf_STaAytnNSrwMWsj3dhM8Mho=Wb-XbAWojZw@mail.gmail.com> <20140122204828.GA6033@dan.emsphone.com>

Next in thread | Previous in thread | Raw E-Mail | Index | Archive | Help
On Wed, Jan 22, 2014 at 12:48 PM, Dan Nelson <dnelson@allantgroup.com> wrote:
> "zpool create" does create a filesystem

Dan,

Thank you.  I suspected this was the case (the FreeBSD handbook
certainly implies this).  Now that we have that out of the way I can
ask my real question:

Can you identify the concept I am missing as evidenced by this failure:

===

# truncate -s 100m disk1
# truncate -s 100m disk2
# zpool create pool1 /root/disk1
# zpool create pool2 /root/disk2

So far so good... however, the next lines concern me.  Some people
seem to say "Wait, /pool1 is not a good filesystem to start using you
need to uze 'zfs create' first".  However your comment leads me to
believe that /pool1 is okay to start using right away.

# echo asdf > /pool1/file.txt
# zfs snapshot pool1@123

Let's try to replicate:

# zfs send pool1@123 | zfs recv pool2
cannot receive new filesystem stream: destination 'pool2' exists
must specify -F to overwrite it

Okay we have a problem.  This is the heart of my misunderstanding.
But I'll try to power through:

# zfs send pool1@123 | zfs recv -F pool2
# zfs list -t snapshot
NAME        USED  AVAIL  REFER  MOUNTPOINT
pool1@123  18.5K      -  31.5K  -
pool1@124      0      -  31.5K  -
pool2@123      0      -  31.5K  -

So far so good.  And let's try another replication:

# echo qwer > /pool1/file.txt
# zfs snapshot pool1@124
# zfs send pool1@124 | zfs recv pool2
cannot receive new filesystem stream: destination 'pool2' exists
must specify -F to overwrite it
# zfs send pool1@124 | zfs recv -F pool2
cannot receive new filesystem stream: destination has snapshots (eg. pool2@123)
must destroy them to overwrite it

# echo Okay I do not understand what is happening.

Thank you,

Chris



Want to link to this message? Use this URL: <http://docs.FreeBSD.org/cgi/mid.cgi?CAPi0pstg7X1Y43K_21usCPzn3nDvtaLiMcnV=AS2yNGUT5neMA>