Ray Clark
2009-Sep-24 01:54 UTC
[zfs-discuss] Checksum property change does not change pre-existing data - right?
My understanding is that if I "zfs set checksum=<different>" to change the algorithm that this will change the checksum algorithm for all FUTURE data blocks written, but does not in any way change the checksum for previously written data blocks. I need to corroborate this understanding. Could someone please point me to a document that states this? I have searched and searched and cannot find this. Thank you. -- This message posted from opensolaris.org
Mark J Musante
2009-Sep-24 02:09 UTC
[zfs-discuss] Checksum property change does not change pre-existing data - right?
On 23 Sep, 2009, at 21.54, Ray Clark wrote:> My understanding is that if I "zfs set checksum=<different>" to > change the algorithm that this will change the checksum algorithm > for all FUTURE data blocks written, but does not in any way change > the checksum for previously written data blocks. > > I need to corroborate this understanding. Could someone please > point me to a document that states this? I have searched and > searched and cannot find this.I haven''t googled for a specific doc, but I can at least tell you that your understanding is correct. If you change the checksum algorithm, that checksum is applied only to future writes. Other properties work similarly, such as compression or copies. I see that the zfs manpage (viewable here: http://docs.sun.com/app/docs/doc/816-5166/zfs-1m? a=view ) only indicates that this is true for the copies property. I guess we''ll have to update that doc. Is the word of a zfs developer sufficient? Or do you need to see it in an official piece of documentation? Regards, markm
Bob Friesenhahn
2009-Sep-24 02:32 UTC
[zfs-discuss] Checksum property change does not change pre-existing data - right?
On Wed, 23 Sep 2009, Ray Clark wrote:> My understanding is that if I "zfs set checksum=<different>" to > change the algorithm that this will change the checksum algorithm > for all FUTURE data blocks written, but does not in any way change > the checksum for previously written data blocks.This is correct. The same applies to blocksize and compression.> I need to corroborate this understanding. Could someone please > point me to a document that states this? I have searched and > searched and cannot find this.Sorry, I am not aware of a document and don''t have time to look. Bob -- Bob Friesenhahn bfriesen at simple.dallas.tx.us, http://www.simplesystems.org/users/bfriesen/ GraphicsMagick Maintainer, http://www.GraphicsMagick.org/
Roch
2009-Sep-24 08:42 UTC
[zfs-discuss] Checksum property change does not change pre-existing data - right?
Bob Friesenhahn writes: > On Wed, 23 Sep 2009, Ray Clark wrote: > > > My understanding is that if I "zfs set checksum=<different>" to > > change the algorithm that this will change the checksum algorithm > > for all FUTURE data blocks written, but does not in any way change > > the checksum for previously written data blocks. > > This is correct. The same applies to blocksize and compression. > With an important distinction. For compression,checksum a block rewrite will affect the next update to any fileblock. For the dataset recordsize property, a block rewrite on an existing multiblock file will not change the file''s block size. For Multi-record file''s, the recordsize is immutable and dissociated from the dataset recordsize setting. > > I need to corroborate this understanding. Could someone please > > point me to a document that states this? I have searched and > > searched and cannot find this. > Me neither, although it''s easy to verify that setting the checksum property on a dataset does not induce the I/O that would be required for a rewrite of the bp. -r > Sorry, I am not aware of a document and don''t have time to look. > > Bob > -- > Bob Friesenhahn > bfriesen at simple.dallas.tx.us, http://www.simplesystems.org/users/bfriesen/ > GraphicsMagick Maintainer, http://www.GraphicsMagick.org/ > _______________________________________________ > zfs-discuss mailing list > zfs-discuss at opensolaris.org > http://mail.opensolaris.org/mailman/listinfo/zfs-discuss
Darren J Moffat
2009-Sep-24 09:17 UTC
[zfs-discuss] Checksum property change does not change pre-existing data - right?
Roch wrote:> Bob Friesenhahn writes: > > On Wed, 23 Sep 2009, Ray Clark wrote: > > > > > My understanding is that if I "zfs set checksum=<different>" to > > > change the algorithm that this will change the checksum algorithm > > > for all FUTURE data blocks written, but does not in any way change > > > the checksum for previously written data blocks. > > > > This is correct. The same applies to blocksize and compression. > > > > With an important distinction. For compression,checksum a > block rewrite will affect the next update to any fileblock. > > For the dataset recordsize property, a block rewrite on an > existing multiblock file will not change the file''s block > size. For Multi-record file''s, the recordsize is immutable > and dissociated from the dataset recordsize setting. > > > > I need to corroborate this understanding. Could someone please > > > point me to a document that states this? I have searched and > > > searched and cannot find this. > > > > Me neither, although it''s easy to verify that setting the > checksum property on a dataset does not induce the I/O that > would be required for a rewrite of the bp.It is mentioned in zfs(1) for the copies property but not for checksum and compression: Changing this property only affects newly-written data. Therefore, set this property at file system creation time by using the -o copies=N option. I''ve filed a man page bug 6885203 to have similar text added for checksum and compression. -- Darren J Moffat
Chris Ridd
2009-Sep-24 15:24 UTC
[zfs-discuss] Checksum property change does not change pre-existing data - right?
On 24 Sep 2009, at 03:09, Mark J Musante wrote:> > On 23 Sep, 2009, at 21.54, Ray Clark wrote: > >> My understanding is that if I "zfs set checksum=<different>" to >> change the algorithm that this will change the checksum algorithm >> for all FUTURE data blocks written, but does not in any way change >> the checksum for previously written data blocks. >> >> I need to corroborate this understanding. Could someone please >> point me to a document that states this? I have searched and >> searched and cannot find this. > > I haven''t googled for a specific doc, but I can at least tell you > that your understanding is correct. If you change the checksum > algorithm, that checksum is applied only to future writes. Other > properties work similarly, such as compression or copies. I see > that the zfs manpage (viewable here: http://docs.sun.com/app/docs/doc/816-5166/zfs-1m?a=view > ) only indicates that this is true for the copies property. I > guess we''ll have to update that doc.It mentions something similar for the recordsize property too: --- Changing the file system''s recordsize affects only files created afterward; existing files are unaffected. --- Cheers, Chris