Also, there is no need to go through lofi.  You can directly add files
to a zpool:

    # mkfile -v 100m /var/tmp/disk1
    # mkfile -v 100m /var/tmp/disk2
    # zpool create pool_1and2 /var/tmp/disk1 /var/tmp/disk2

I do this in demos all the time, and it's quite handy.  And as George
pointed out, you just need to feed "zpool import" the directory name to
have it search for vdevs.


--Bill

On Wed, Sep 19, 2007 at 02:53:47AM -0400, George Wilson wrote:
> By default, 'zpool import' looks only in /dev/dsk. Since you are using 
> /dev/lofi you will need to use 'zpool import -d /dev/lofi' to import 
> your pool.
> 
> Thanks,
> George
> 
> sunnie wrote:
> > Hey, guys
> >       I just do the test for use loop device as vdev for zpool
> > Procedures as followings:
> > 1)  mkfile -v 100m disk1
> >      mkfile -v 100m disk2
> > 
> > 2)  lofiadm -a disk1 /dev/lofi
> >      lofiadm -a disk2 /dev/lofi
> > 
> > 3)  zpool create pool_1and2  /dev/lofi/1 and /dev/lofi/2
> > 
> > 4)  zpool export pool_1and2
> > 
> > 5) zpool  import pool_1and2
> > 
> > error info here:
> > bash-3.00# zpool import pool1_1and2
> > cannot import 'pool1_1and2': no such pool available
> > 
> > So, can anyone help explain some details that differ from loop devices and 
> > physical  block device?
> >  
> >  
> > This message posted from opensolaris.org
> > _______________________________________________
> > zfs-discuss mailing list
> > zfs-discuss@opensolaris.org
> > http://mail.opensolaris.org/mailman/listinfo/zfs-discuss
> _______________________________________________
> zfs-discuss mailing list
> zfs-discuss@opensolaris.org
> http://mail.opensolaris.org/mailman/listinfo/zfs-discuss
_______________________________________________
zfs-discuss mailing list
zfs-discuss@opensolaris.org
http://mail.opensolaris.org/mailman/listinfo/zfs-discuss

Reply via email to