[geeks] recipe for Linux / iSCSI / thin provisioned space

Jonathan Patschke jp at celestrion.net
Tue Sep 14 10:44:16 CDT 2010


On Tue, 14 Sep 2010, der Mouse wrote:

>> Imagine a sparse file as the backing store for a filesystem, and
>> you'll have the idea pretty close.
>
> Oh!
>
> Why is this useful?  I can see only two ways for it to be useful: (1)
> shorter setup time, with the difference amortized over future accesses
> (the ones which are first writes to the various blocks), and (2) disk
> space overcommit.

It's mostly #2--mkfs on a thinly-provisioned volume isn't faster than it
is on an actual volume.

You usually have a better idea of how much disk space is too little versus
how much is too much.  Thin provisioning lets you play the same shell
games with disk space that we've played with memory allocation for years.
Sure, your process may -have- a 2GB memory space, but virtual memory isn't
committed until it's mmaped or alloced into place.  Similarly, your iSCSI
target may have 1GB worth of blocks, but they might not come into being
until you write to them.

When you run out of memory, you page to disk.  When you run out of
thinly-provisioned disk, hopefully your volume manager will let you attach
another one.  This avoids the problem of many consumers having gigabytes
of disk allotted to them that they don't need and cannot be reclaimed
(since so few filesystems shrink elegantly).

-- 
Jonathan Patschke | "There is more to life than increasing its speed."
Elgin, TX         |                                   --Mahatma Gandhi
USA               |



More information about the geeks mailing list