Cyril Plisko wrote:
On 11/1/06, Dick Davies <[EMAIL PROTECTED]> wrote:
On 01/11/06, Dick Davies <[EMAIL PROTECTED]> wrote:
> And we'll be able to use sparse zvols
> for this too (can't think why we couldn't, but it'd be dead handy)?

Thinking about this, we won't be able to (without some changes) -
I think a target is zero-filled before going online
(educated guess: it takes 5 minutes to 'online' a target,
and it consumes virtually no space in the parent zvol if compression is on),
so a sparse zvol would exhaust zpool space.

Looking at the code it doesn't seem like the backing store being zeroed.
In case of regular file a single sector (512 byte) of uninitialized data from
stack (bad practice ?) is written to the very end of the file. And in case
of character device it isn't written at all. zvol should fall into char device
category. See mgmt_create.c::setup_disk_backing()

In another email I indicated that the routine create_lun_common() was where the initialization was done and that I didn't check for a character device. The code already does check for character devices and ignores them.

Or did I miss something ?

I too must be missing something. I can't imagine why it would take 5 minutes to online a target. A ZVOL should automatically be brought online since now initialization is required.


--
----
Rick McNeal

A good friend will come and bail you out of jail...but, a true
friend will be sitting next to you saying, "Damn...that was fun!"
_______________________________________________
zfs-discuss mailing list
zfs-discuss@opensolaris.org
http://mail.opensolaris.org/mailman/listinfo/zfs-discuss

Reply via email to