[OpenIndiana-discuss] zpool export import alternate cachefile

Randy S sim.ple at live.nl
Wed Sep 26 23:00:45 UTC 2012


BTW
I have tested these steps in OI version a5 and there they do work.
Maybe a bug. As I understand, the use of the cache file speeds up the import process significantly. 
Maybe others can benefit from this info.
Rgds
Randy

> From: sim.ple at live.nl
> To: openindiana-discuss at openindiana.org
> Date: Wed, 26 Sep 2012 16:39:07 +0200
> Subject: Re: [OpenIndiana-discuss] zpool export import alternate cachefile
> 
> 
> Sir,
> 
> Thank you very much for your speedy reply!
> 
> I was under the impression that by using the cachefile (as explained on different sites) the import should be faster. That's why I kept trying with a copy of the original cachefile.
> 
> High regards,
> 
> Randy
> 
> 
> > Date: Wed, 26 Sep 2012 09:06:01 -0500
> > From: gary_mills at fastmail.fm
> > To: openindiana-discuss at openindiana.org
> > Subject: Re: [OpenIndiana-discuss] zpool export import alternate cachefile
> > 
> > On Wed, Sep 26, 2012 at 03:51:48PM +0200, Randy S wrote:
> > > 
> > > I'm experimenting with creating zpools with an alternate location for 
> > > the cachefile. Reason: I don't want certain pools to mount at boottime. I
> > >  know that you have to create a copy of the cachefile so that it won't 
> > > be removed when you export it. I followed the following procedure (done 
> > > in a vm and on real hardware)
> > 
> > You don't need a copy.  Just create the cache file during the import.
> > 
> > > 5: import the testpool back: zpool import -c /etc/cache/testpool.cache -a 
> > > 
> > > Step 5 is where it goes wrong. I allways get the message: "cannot import
> > >  'testpool': one or more devices is currently unavailable.
> > 
> > Here's an example from Solaris 10:
> > 
> >     # zpool list
> >     NAME    SIZE  ALLOC   FREE    CAP  HEALTH  ALTROOT
> >     rpool   136G  8.66G   127G     6%  ONLINE  -
> >     # ll /etc/zfs/*.cache    
> >     -rw-r--r--   1 root     root        1704 Jul 18 13:29 /etc/zfs/zpool.cache
> >     # ll /etc/zfs/clust.cache
> >     /etc/zfs/clust.cache: No such file or directory
> >     # zpool import -o cachefile=/etc/zfs/clust.cache space
> >     # zpool list
> >     NAME    SIZE  ALLOC   FREE    CAP  HEALTH  ALTROOT
> >     rpool   136G  8.66G   127G     6%  ONLINE  -
> >     space   278G   212M   278G     0%  ONLINE  -
> >     # ll /etc/zfs/*.cache
> >     -rw-r--r--   1 root     root        1824 Jul 18 17:51 /etc/zfs/clust.cache
> >     -rw-r--r--   1 root     root        1716 Jul 18 17:51 /etc/zfs/zpool.cache
> > 
> > -- 
> > -Gary Mills-		-refurb-		-Winnipeg, Manitoba, Canada-
> > 
> > _______________________________________________
> > OpenIndiana-discuss mailing list
> > OpenIndiana-discuss at openindiana.org
> > http://openindiana.org/mailman/listinfo/openindiana-discuss
>  		 	   		  
> _______________________________________________
> OpenIndiana-discuss mailing list
> OpenIndiana-discuss at openindiana.org
> http://openindiana.org/mailman/listinfo/openindiana-discuss
 		 	   		  


More information about the OpenIndiana-discuss mailing list