All of lore.kernel.org
 help / color / mirror / Atom feed
From: Tomas Vanderka <tomas.vanderka@gmail.com>
To: linux-lvm@redhat.com
Cc: dm-devel@redhat.com
Subject: Re: [linux-lvm] Mounted, but idle LVM volume causes constant disk writes
Date: Tue, 04 Jun 2013 13:00:26 +0200	[thread overview]
Message-ID: <51ADC8CA.4010800@gmail.com> (raw)
In-Reply-To: <CAEp_DRC=xOm-yWLGR27PnsuLPTTXcPMnKLSmk+iS1VLDG0hKtw@mail.gmail.com>

On 06/04/2013 07:46 AM, Bostjan Skufca wrote:
> Hello,
> 
> If LVM2 volume is mounted (ext4 fs), why is there constant write activity to the devices below (sw raid in this case) despite not using the mounted volume at all?
> 
> I am seing this on multiple hosts. On this particular one I am seeing around 20 writes per second on average, but they occur in batches of around 50-90 writeIOps on every
> 3-4 seconds. If I mount the same filesystem (ext4) on sw raid1 without LVM in between, I see the expected 0 write IOps when not using the filesystem.
> 

Just out of curiosity I looked at my systems and I don't see any such IO, even for mounted FS.

You can try running following commands to log writes and where are they comming from (show the result via dmesg)

echo 1 > /proc/sys/vm/block_dump; sleep 10; echo 0 > /proc/sys/vm/block_dump;

By doing so I noticed dm-thin writing to my otherwise unused dm thin pool every second. After looking at the code in dm-thin.c, it looks like the kernel is periodically
commiting metadata every second even if there was no IO to the pool in the time period. I think process_deferred_bios function should probably check if anything changed
before commiting metadata unconditionally when 1s timer is up. Looks like dm-cache-target.c is doing it right.

t.

      parent reply	other threads:[~2013-06-04 11:00 UTC|newest]

Thread overview: 4+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2013-06-04  5:46 [linux-lvm] Mounted, but idle LVM volume causes constant disk writes Bostjan Skufca
2013-06-04 10:59 ` Greg Zapp
2013-06-04 15:29   ` Bostjan Skufca
2013-06-04 11:00 ` Tomas Vanderka [this message]

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=51ADC8CA.4010800@gmail.com \
    --to=tomas.vanderka@gmail.com \
    --cc=dm-devel@redhat.com \
    --cc=linux-lvm@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.