All of lore.kernel.org
 help / color / mirror / Atom feed
From: Zdenek Kabelac <zkabelac@redhat.com>
To: lvm-devel@redhat.com
Subject: [PATCH] Fix RHBZ 754198 (multiple dmeventd snapshot extensions)
Date: Fri, 18 Nov 2011 18:14:35 +0100	[thread overview]
Message-ID: <4EC6927B.4000402@redhat.com> (raw)
In-Reply-To: <87y5vdwydx.fsf@aldalome.int.mornfall.net.>

Dne 18.11.2011 10:52, Petr Rockai napsal(a):
> Hi,
>
> Alasdair G Kergon<agk@redhat.com>  writes:
>
>>     (new_size = old_size + amount_to_extend_by)>
>> 	old_size_in_use + ((100 + autoextend_percent) - autoextend_threshold) / (100+autoextend_percent) * (old_size + amount_to_extend_by)
>>
>> IOW we scale the parameters based on the amount currently in use.
>>
>> For example:
>>
>>      snapshot_autoextend_threshold = 70
>>      snapshot_autoextend_percent = 20
>
> [snip] This is all great, but completely besides the point. So let me
> stress the point once more:
>
> - snapshot DSO monitors a snapshot, getting its status line every 10
>    seconds or so
> - the DSO has *no access* to the policy variables, because it does not
>    (and can not) read lvm.conf

The formula above should be placed inside lvresize (_adjust_policy_params()).

It's advantage was to resize in a way - the it should avoid the need of
quick subsequent (i.e. more then autoextend_percent - so if you fill
snapshot very fast, there should be some reserve to catch up within
next 10s check.

> The problem:
>
> - to check whether anything needs to happen, lvextend needs to be
>    executed (this is *expensive*, even if it decides no action needs to
>    happen)
>
> - if nothing needed to happen, we don't need to call lvextend until the
>    utilisation has grown; *but* we don't know whether anything happened
>    (without ENO_ACTION_NEEDED that is)

But you still call dmeventd_lvm2_run() - which is the most expensive
operation here - so I do not exactly see what do you actually safe here
i.e. if the resize will not happen because according to policy it's not
yet needed - then I do not see any difference ?

Zdenek



  reply	other threads:[~2011-11-18 17:14 UTC|newest]

Thread overview: 17+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2011-11-15 22:00 [PATCH] Fix RHBZ 754198 (multiple dmeventd snapshot extensions) Petr Rockai
2011-11-15 22:23 ` Milan Broz
     [not found]   ` <20111116000020.GA3294@agk-dp.fab.redhat.com>
2011-11-16  9:30     ` Petr Rockai
2011-11-16  9:44       ` Zdenek Kabelac
2011-11-16 10:28       ` Alasdair G Kergon
2011-11-16  1:20 ` Alasdair G Kergon
2011-11-16  9:41   ` Petr Rockai
2011-11-16 10:59     ` Alasdair G Kergon
2011-11-16 13:07       ` Alasdair G Kergon
2011-11-18  9:52         ` Petr Rockai
2011-11-18 17:14           ` Zdenek Kabelac [this message]
2011-11-18 19:46             ` Petr Rockai
2011-11-18 19:56               ` Alasdair G Kergon
2011-11-18 20:28                 ` Petr Rockai
2011-11-18 21:19                   ` Petr Rockai
2011-11-18 20:48               ` Zdenek Kabelac
2011-11-18 20:53                 ` Alasdair G Kergon

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=4EC6927B.4000402@redhat.com \
    --to=zkabelac@redhat.com \
    --cc=lvm-devel@redhat.com \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.