Storage Performance Development Kit (SPDK)
 help / color / mirror / Atom feed
From: wuzhouhui <wuzhouhui14 at mails.ucas.ac.cn>
To: spdk@lists.01.org
Subject: Re: [SPDK] The size of lvol_bdev is smaller than expected
Date: Sat, 28 Sep 2019 02:06:07 +0000	[thread overview]
Message-ID: <3c4bbefe.36e6a.164db3174a6.Coremail.wuzhouhui14@mails.ucas.ac.cn> (raw)
In-Reply-To: FF7FC980937D6342B9D289F5F3C7C2625B6FE1F1@SHSMSX103.ccr.corp.intel.com

[-- Attachment #1: Type: text/plain, Size: 3812 bytes --]

Fine, I tried latest SPDK in branch master and the issue don't occured.
Maybe you can reproduce this issue in v18.04.1

Thanks.

> -----原始邮件-----
> 发件人: "Liu, Changpeng" <changpeng.liu(a)intel.com>
> 发送时间: 2018-07-27 16:57:47 (星期五)
> 收件人: "Storage Performance Development Kit" <spdk(a)lists.01.org>
> 抄送: 
> 主题: Re: [SPDK] The size of lvol_bdev is smaller than expected
> 
> Hi Zhouhui,
> 
> I tried your parameters and the code looks good to me.
> 
> Please see attached results from my test server. I also used 4TiB P4500.
> 
>   {
>     "num_blocks": 975799296,
>     "uuid": "fa72086a-8f74-45f1-ab0d-8a4d805ba0ea",
>     "aliases": [
>       "lvs_0/lbd_0"
>     ],
>     "claimed": false,
>     "driver_specific": {
>       "lvol": {
>         "base_bdev": "Nvme0n1",
>         "clone": false,
>         "snapshot": false,
>         "lvol_store_uuid": "37c1d411-a1f0-4483-b14d-a7bdea264a28",
>         "thin_provision": false
>       }
>     },
>     "supported_io_types": {
>       "reset": true,
>       "nvme_admin": false,
>       "unmap": true,
>       "read": true,
>       "write_zeroes": true,
>       "write": true,
>       "flush": false,
>       "nvme_io": false
>     },
>     "qos_ios_per_sec": 0,
>     "block_size": 4096,
>     "product_name": "Logical Volume",
>     "name": "fa72086a-8f74-45f1-ab0d-8a4d805ba0ea"
> }
> 
> > -----Original Message-----
> > From: SPDK [mailto:spdk-bounces(a)lists.01.org] On Behalf Of wuzhouhui
> > Sent: Friday, July 27, 2018 4:07 PM
> > To: spdk(a)lists.01.org
> > Subject: [SPDK] The size of lvol_bdev is smaller than expected
> > 
> > I using all clusters of lvol_store to create a single lvol_bdev,
> > but the size is smaller than expected. The expected size should
> > be 3.7 TB, but 1.7 TB in reality. Following is my procedure:
> > 1. Start vhost app:
> >     ./app/vhost -m 0x3 -S /var/tmp
> > 2. Create nvme_bdev:
> >     ./rpc.py construct_nvme_bdev -b nvme0 -t pcie -a "0000:31:00.0"
> > The 0000:31:00.0 is the Intel SSD DC P4500, 3.7 TB in total.
> > 3. Create lvol_store:
> >     ./rpc.py construct_lvol_store nvme0n1 lvs0
> > After created, the total free cluster is 952929:
> >     ./rpc.py get_lvol_stores
> > [
> >   {
> >     "uuid": "88d3072e-a0e6-4020-9bdd-cd0fd300ec23",
> >     "base_bdev": "nvme0n1",
> >     "free_clusters": 952929,
> >     "cluster_size": 4194304,
> >     "total_data_clusters": 952929,
> >     "block_size": 4096,
> >     "name": "lvs0"
> >   }
> > ]
> > 4. I use all free clusters of lvs0 to create a single lvol_bdev:
> >     ./rpc.py construct_lvol_bdev -l lvs0 lv0 3811716
> > The value "3811716" is comming from "952929 * 4"
> > 5. Check the size of lvs0/lv0:
> >     ./rpc.py get_bdevs
> > Accoring to the lvs0/lv0's "num_blocks" and "block_size", the size of
> > lvs0/lv0 is 1.7 TB, not 3.7 TB.
> > 6. After I delete lvs0/lv0:
> >     ./rpc.py destroy_lvol_bdev lvs0/lv0
> > There is still some clusters not freed, but there is no other lvol_bdevs
> > exists:
> >     ./rpc.py get_lvol_stores
> > [
> >   {
> >     "uuid": "88d3072e-a0e6-4020-9bdd-cd0fd300ec23",
> >     "base_bdev": "nvme0n1",
> >     "free_clusters": 428641,
> >     "cluster_size": 4194304,
> >     "total_data_clusters": 952929,
> >     "block_size": 4096,
> >     "name": "lvs0"
> >   }
> > ]
> > 
> > SPDK version: 18.04.1
> > OS: CentSO 7.4
> > SSD: Intel SSD DC P4500
> > 
> > Is this a bug?
> > _______________________________________________
> > SPDK mailing list
> > SPDK(a)lists.01.org
> > https://lists.01.org/mailman/listinfo/spdk
> _______________________________________________
> SPDK mailing list
> SPDK(a)lists.01.org
> https://lists.01.org/mailman/listinfo/spdk

             reply	other threads:[~2019-09-28  2:06 UTC|newest]

Thread overview: 4+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2019-09-28  2:06 wuzhouhui [this message]
  -- strict thread matches above, loose matches on Subject: below --
2019-09-28  2:06 [SPDK] The size of lvol_bdev is smaller than expected wuzhouhui
2018-07-27 16:10 Harris, James R
2018-07-27  8:57 Liu, Changpeng

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=3c4bbefe.36e6a.164db3174a6.Coremail.wuzhouhui14@mails.ucas.ac.cn \
    --to=spdk@lists.01.org \
    /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