Skip to content

ndctl create-namespace should support percentages #199

Open
@sscargal

Description

@sscargal

It would be very useful to support namespace creation using a percentage value of the total region capacity in addition to the current method that supports size as bytes. It saves the user having to perform calculations that can be complex when determining alignment, interleave width, etc. ndctl already performs input argument validation checks when creating namespaces, so we could use the existing functionality and expose it to the user.

Examples:

  • ndctl create-namespace –size 50% --region 0 // Create a single namespace in region 0 using 50% of the total capacity
  • ndctl create-namespace –size 50% --continue // Keep creating namespaces of size 50% until we run out of space in all regions (2 namespaces per region)
  • ndctl create-namespace –size 25%,50%,20%,5% --region 0 // Create 4 namespaces in region 0 using the percentages provided

A new --pct option could be implemented instead of reusing --size

Metadata

Metadata

Assignees

No one assigned

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions