On Thu, May 7, 2009 at 11:24 AM, Alastair Neil <ajn...@gmail.com> wrote:

>
>
> On Tue, Apr 28, 2009 at 2:41 PM, Richard Elling 
> <richard.ell...@gmail.com>wrote:
>
>> Alastair Neil wrote:
>>
>>>
>>>
>>> On Tue, Apr 28, 2009 at 12:44 PM, Richard Elling <
>>> richard.ell...@gmail.com <mailto:richard.ell...@gmail.com>> wrote:
>>>
>>>
>>>
>>>    Alastair Neil wrote:
>>>
>>>
>>>
>>>        On Mon, Apr 27, 2009 at 6:54 PM, Robert Milkowski
>>>        <mi...@task.gda.pl <mailto:mi...@task.gda.pl>
>>>        <mailto:mi...@task.gda.pl <mailto:mi...@task.gda.pl>>> wrote:
>>>        >
>>>        > Hello Alastair,
>>>        >
>>>        > Monday, April 27, 2009, 10:18:50 PM, you wrote:
>>>        >
>>>        > Seems or did you confirm it with mount or df command?
>>>        >
>>>        > Do you mount it manually then?
>>>        >
>>>        >
>>> http://milek.blogspot.com
>>>        >
>>>
>>>        This is a sample of one of the failures.  Clearly the
>>>        filesystem gets created and  the subsequent mount fails
>>>        because of a copy of files from the skeleton directory to the
>>>        expected home directory that basically creates a file in place
>>>        of where the system expects a mountpoint directory.
>>>
>>>
>>>    In the script that copies the files, test for the directory and
>>>    wait in a loop.
>>>    You shouldn't have to wait more than a second or two.
>>>    -- richard
>>>
>>>
>>> I could do that but 1 second on each zfs create adds almost 4.5 hours to
>>> the time required to run the script.
>>>
>>
>> Use a subshell and put it in the background.
>> -- richard
>
>
>
> Finally got clear of our building move and have had time to try this.  I
> have done as you expected so hopefully this will run without issues.  I'll
> let you know how it goes.
>

A follow up.  With the post "zfs create" stuff split into a background
subshell I can get the script to run correctly.  I needed to add a check to
see if the file system is mounted:

zfs_is_mounted () {
>     ${ZFS} get -H mounted ${1} | ${GREP} "mounted.yes" 2>&1 > /dev/null
>     return $?
> }
>


if there is a more elegant way of checking this then please let me know.

The crux here is the abysmal scaling of zfs.  When the script starts it can
create a new filesystem every 3 seconds.  after a day of running and with
6200 filesystem created it now takes more than 30 seconds to create each
filesystem.  I shudder to think what the performace will be once I actually
share these filesystems.
_______________________________________________
zfs-discuss mailing list
zfs-discuss@opensolaris.org
http://mail.opensolaris.org/mailman/listinfo/zfs-discuss

Reply via email to