rpc: Fix raid strip size method not consistent.

Fix json config file using strip_size error, and
The strip_size parameter was changed to strip_size_kb  in `bdev_raid_create`
     rpc function in order to make it more meaningful to users.

Unify the coding style in rpc help file.
      using --strip-size-kb --raid-level ... instead of --strip-size_kb.

Signed-off-by: yidong0635 <dongx.yi@intel.com>
Change-Id: I341af1034c7ea6716ff839bb524ee733c9e0cd34
Reviewed-on: https://review.spdk.io/gerrit/c/spdk/spdk/+/8401
Tested-by: SPDK CI Jenkins <sys_sgci@intel.com>
Community-CI: Mellanox Build Bot
Reviewed-by: Changpeng Liu <changpeng.liu@intel.com>
Reviewed-by: Ziye Yang <ziye.yang@intel.com>
Reviewed-by: Shuhei Matsumoto <shuhei.matsumoto.xt@hitachi.com>
Reviewed-by: Jim Harris <james.r.harris@intel.com>
This commit is contained in:
yidong0635 2021-06-17 09:17:20 +08:00 committed by Jim Harris
parent 164bfddf24
commit 928db41626
3 changed files with 5 additions and 2 deletions

View File

@ -72,6 +72,9 @@ to create a rbd bdev with an already registered Rados Cluster Object.
New RPC `bdev_rbd_get_clusters_info` was added, it allows to get the info of the registered
Rados Cluster names.
Revised a parameter `--stripe-size_kb` to `--stripe-size-kb` of `bdev_raid_create` method
provided in `scripts/rpc.py` for consistency.
### bdev
Removed ZCOPY emulation: The bdev module can be checked to see if it supports ZCOPY

View File

@ -7866,7 +7866,7 @@ Example request:
"Malloc2",
"Malloc3"
],
"strip_size": 4096
"strip_size_kb": 4
}
}
~~~

View File

@ -1724,7 +1724,7 @@ Format: 'user:u1 secret:s1 muser:mu1 msecret:ms1,user:u2 secret:s2 muser:mu2 mse
p = subparsers.add_parser('bdev_raid_create', aliases=['construct_raid_bdev'],
help='Create new raid bdev')
p.add_argument('-n', '--name', help='raid bdev name', required=True)
p.add_argument('-z', '--strip-size_kb', help='strip size in KB', type=int)
p.add_argument('-z', '--strip-size-kb', help='strip size in KB', type=int)
p.add_argument('-r', '--raid-level', help='raid level, only raid level 0 is supported', required=True)
p.add_argument('-b', '--base-bdevs', help='base bdevs name, whitespace separated list in quotes', required=True)
p.set_defaults(func=bdev_raid_create)