Restoring received properties on a received filesystem.

Artem Belevich art at freebsd.org
Sun Dec 25 20:22:12 UTC 2011


On Sun, Dec 25, 2011 at 11:49 AM, Johannes Totz <johannes at jo-t.de> wrote:
> On 25/12/2011 13:02, claudiu vasadi wrote:
>>
>> On Sun, Dec 25, 2011 at 1:54 PM, Johannes Totz<johannes at jo-t.de>  wrote:
>>
>> Check out zfs receive -u, it doesn't mount the receiving filesystem. zpool
>>>
>>> import -N doesn't mount your importing backup-pool.
>>>
>>>
>> True, it doesn't, but upon reboot, since the received datasets keep their
>> properties, they will be mounted (and this has the risk of potentially
>> overwriting an exiting mountpoint).
>
>
> Good point! Haven't thought about reboot, I always export my backup pool
> when I'm done with send-receive.
> Could be worked around, I guess, by disabling cache file entry and manually
> importing it from some random script...

Perhaps "zpool import/create -R /foo" (or "-o altroot=foo,
cachefile=none") is what you're looking for. It effectively gives your
pool its own name space under /foo and it does not record any info
about it in zpool cache, so on reboot the pool should remain
unimported.

--Artem


More information about the freebsd-fs mailing list