From: Mike Snitzer <snitzer@redhat.com>
To: CJ Kucera <pez@apocalyptech.com>
Cc: linux-lvm@redhat.com
Subject: Re: [linux-lvm] Questions about issue_discards
Date: Fri, 7 Dec 2012 09:18:27 -0500 [thread overview]
Message-ID: <20121207141827.GA7469@redhat.com> (raw)
In-Reply-To: <20121206222535.GA2668@apocalyptech.com>
On Thu, Dec 06 2012 at 5:25pm -0500,
CJ Kucera <pez@apocalyptech.com> wrote:
> Hello, list!
>
> I've started to play around with SSD drives and was curious about a
> couple aspects of the issue_discards configuration option.
>
> 1) The lvm.conf comments note that when enabled, it'll still only
> (obviously) issue discards to storage which happens to support it. Is
> there a way of querying block devices to find out if they support the
> feature?
lvm will only issue discards if the underlying device has non-zero
discard_granularity and discard_max_bytes, to check:
cat /sys/block/<dev>/queue/discard_granularity
cat /sys/block/<dev>/queue/discard_max_bytes
(replace <dev> accordingly, e.g. sda)
> 2) Would a change to the issue_discards parameter be picked up
> automatically by the running kernel? The lvm.conf manpage mentions that
> it remembers the timestamp of the file "between commands" and will apply
> changes then, but it almost sounds like that'd be mostly for things like
> the device scanning list, etc.
lvm.conf's issue_discards doesn't have any affect on the kernel (or
underlying device's) discard capabilities. It only controls whether
discards are issued by lvm for certain lvm operations (like when an LV
is removed).
prev parent reply other threads:[~2012-12-07 14:18 UTC|newest]
Thread overview: 3+ messages / expand[flat|nested] mbox.gz Atom feed top
2012-12-06 22:25 [linux-lvm] Questions about issue_discards CJ Kucera
2012-12-07 1:29 ` James Downs
2012-12-07 14:18 ` Mike Snitzer [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=20121207141827.GA7469@redhat.com \
--to=snitzer@redhat.com \
--cc=linux-lvm@redhat.com \
--cc=pez@apocalyptech.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 a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).