Print this page
4188 assertion failed in dmu_tx_hold_free(): dn_datablkshift != 0
Reviewed by: George Wilson <george.wilson@delphix.com>
Reviewed by: Christopher Siden <christopher.siden@delphix.com>

@@ -633,13 +633,20 @@
                 int shift = dn->dn_datablkshift + dn->dn_indblkshift -
                     SPA_BLKPTRSHIFT;
                 uint64_t start = off >> shift;
                 uint64_t end = (off + len) >> shift;
 
-                ASSERT(dn->dn_datablkshift != 0);
                 ASSERT(dn->dn_indblkshift != 0);
 
+                /*
+                 * dnode_reallocate() can result in an object with indirect
+                 * blocks having an odd data block size.  In this case,
+                 * just check the single block.
+                 */
+                if (dn->dn_datablkshift == 0)
+                        start = end = 0;
+
                 zio = zio_root(tx->tx_pool->dp_spa,
                     NULL, NULL, ZIO_FLAG_CANFAIL);
                 for (uint64_t i = start; i <= end; i++) {
                         uint64_t ibyte = i << shift;
                         err = dnode_next_offset(dn, 0, &ibyte, 2, 1, 0);