"can't load 'kernel'" on ZFS root

Pawel Jakub Dawidek pjd at FreeBSD.org
Wed Sep 7 09:46:25 UTC 2011


On Wed, Sep 07, 2011 at 12:20:17PM +0300, Andriy Gapon wrote:
> on 07/09/2011 10:35 Artem Belevich said the following:
> > It makes me wonder, though -- if we're probing devices anyways, why is
> > zpool.cache existence mandatory? According to the name it's a *cache*,
> > presumably to speed up zpool detection on a normal boot. Perhaps we
> > can fall back to probing all drives if zpool.cache is missing. Slower
> > boot definitely beats no booting at all.
> 
> Very good point indeed.
> 
> Pawel, Martin, do you know how the relevant code works?  I suspect that you do
> :-)  Maybe this could be improved trivially?...

The zpool.cache file contains pools that are automatically imported at
system start-up. There might be pools visible in the system that are not
suppose to be automatically imported (eg. a pool on iSCSI disks on
secondary cluster node - importing such pool automatically will corrupt
the data).

This is also not entirely true that we probe all the devices. We probe
them at boot, yes, because we don't even know where to look for
zpool.cache file, but once kernel is loaded we use info from zpool.cache
to open GEOM providers. We fall back to probing all GEOM providers if
something has changed in disk configuration and we can't find all the
vdevs (eg. disk name changed).

-- 
Pawel Jakub Dawidek                       http://www.wheelsystems.com
FreeBSD committer                         http://www.FreeBSD.org
Am I Evil? Yes, I Am!                     http://yomoli.com
-------------- next part --------------
A non-text attachment was scrubbed...
Name: not available
Type: application/pgp-signature
Size: 196 bytes
Desc: not available
Url : http://lists.freebsd.org/pipermail/freebsd-fs/attachments/20110907/0172274e/attachment.pgp


More information about the freebsd-fs mailing list