Maybe I was confused. I know that I can take a file that is in ZFS, and
use it as a lofi device. I know that I can use a "file" as a zpool image.
What I wasn't sure of, and maybe this is where I was confused, is can I
lofi mount on *top* of a zfs filesystem. E.g.
mount -F hsfs /home/garrett/mydvd.iso /var/tmp/dvd
where /var and /home are both on ZFS.
-- Garrett
John Levon wrote:
> On Tue, Apr 29, 2008 at 04:13:58PM +0100, Ceri Davies wrote:
>
>
>>> Hmmm... I didn't realize that ZFS doesn't support lofi. That seems like
>>> a fairly severe shortcoming, particularly given the push towards ZFS
>>> root. (On a system with ZFS root, its likely there won't be *any* ufs,
>>> etc. filesystems.)
>>>
>>> Are there any plans afoot that you're aware of to address this shortcoming?
>>>
>> I don't think that sentence means what you think it means. You can
>> certainly create a lofi device backed by a file on a ZFS filesystem.
>> In fact, since you can also create a zpool on a lofi device, I think it
>> just means that you can't put a ZFS/lofi combination in vfstab.
>>
>
> Or mount a file directly. It's not a shortcoming as such, it just works
> differently. That is, the nearest ZFS equivalent of this is:
>
> thewhip:/ # zpool import -d /var/tmp
> pool: mypool
> id: 5292688193707361217
> state: ONLINE
> action: The pool can be imported using its name or numeric identifier.
> config:
>
> mypool ONLINE
> /var/tmp/mypool.img ONLINE
> thewhip:/ # zpool import -d /var/tmp mypool
> thewhip:/ # zpool list mypool
> NAME SIZE USED AVAIL CAP HEALTH ALTROOT
> mypool 123M 110K 123M 0% ONLINE -
>
> and 'zpool export' for "unmount".
>
> regards
> john
>