zil on root devices?

Christ Schlacta aarcane at aarcane.org
Tue May 17 15:08:08 EDT 2011


Could the same restriction be relaxed for raid-zn and striping on 
similar grounds?

On 5/17/2011 10:36, Brian Behlendorf wrote:
> Here's what zfs_ioc_vdev_add() has to say about root intent log devices:
>
>          /*
>           * A root pool with concatenated devices is not supported.
>           * Thus, can not add a device to a root pool.
>           *
>           * Intent log device can not be added to a rootpool because
>           * during mountroot, zil is replayed, a seperated log device
>           * can not be accessed during the mountroot time.
>           *
>           * l2cache and spare devices are ok to be added to a rootpool.
>           */
>          if (spa_bootfs(spa) != 0&&  nl2cache == 0&&  nspares == 0) {
>                  nvlist_free(config);
>                  spa_close(spa, FTAG);
>                  return (EDOM);
>          }
>
> This is interesting because these look like restrictions imposed on
> Solaris because of how it boots the system.  A Linux system boots
> differently and shouldn't have these particular issues.  The Linux code
> does not use mountroot, this code in fact was removed, and we do have
> full access to the zil device.  So on first glance this looks like a
> Solaris restriction we could relax under Linux.  Commenting out the
> above check would allow you to try it at your own risk.
>



More information about the zfs-discuss mailing list