Unless your software or your own scripts treat local and received ZFS properties as equal, you should probably set the values of the received properties again. Here’s a one-liner to do it all for you.

zfs get -Ho name,property,value -s received all | awk '{printf "zfs set %s=%s %s\n",$2,$3,$1}' | sh

For a running system you may want to omit the mountpoints, only to deal with them the next time the system goes to single user mode.

zfs get -Ho name,property,value -s received all | awk '\!/mountpoint/{printf "zfs set %s=%s %s\n",$2,$3,$1}' | sh

The one-liner above assumes your current shell is csh. Remove the backslash ahead of the exclamation mark for Bourne style shells.

Leave a Reply

Your email address will not be published.

You may use these HTML tags and attributes:

<a href="" title=""> <abbr title=""> <acronym title=""> <b> <blockquote cite=""> <cite> <code> <del datetime=""> <em> <i> <q cite=""> <s> <strike> <strong>