1

Summary: Is a ZFS send/receive always to receive an exact replication of the sending dataset - matching dataset properties included - or is it possible to receive into a newly created dataset with different properties (recordsize, compression etc) that the receiving data (after checksum verification etc.) can then write in to.

For example, if I receive a (non-incremental) dataset whose objects were initially written with a recordsize=128K, and receive into a dataset newly created by zfs receive but that either specifies the option -o recordsize=1M or inherits from a parent dataset with an current value of recordsize=1M, will the objects in my new dataset be written with a recordsize of 1M, or must it be that the objects are written as an exact "replica" of the receiving dataset?

zfs get recordsize tank/files   # returns: 128K

# Set parent of receiving dataset to 1M
zfs set recordsize=1M freezer   

# Also set at receive time    
zfs send tank/files@transfer | zfs receive -o recordsize=1M freezer/files     

My question is essentially:

# Query recordsize of objects as written in freezer
???

I understand that checking the recordsize of the new dataset isn't itself an answer as this would just report what the dataset property is currently set to, it doesn't itself say anything about the recordsize for any previous writes. I've tried to examine the objects directly with something like

zdb -dd freezer

but my zfs version (on FreeBSD 9) seems not to accept this.

man zfs suggests that only 'set-once' properties must match (casesensitivity, normalization, utf8only), but it's not clear to me how objects are written in the general case. I've also checked docs/google but can't seem to get an explicit answer on this behaviour without getting into studying zfs internals.

1 Answer 1

1

In short - no. Recordsize cannot be changed by send/receive operation. Some of the other options can, but not recordsize.

You must log in to answer this question.

Not the answer you're looking for? Browse other questions tagged .