No relevant resource is found in the selected language.

This site uses cookies. By continuing to browse the site you are agreeing to our use of cookies. Read our privacy policy>Search

Reminder

To have a better experience, please upgrade your IE browser.

upgrade

Command Reference for Block

OceanStor Dorado V3 Series V300R002

This document is applicable to OceanStor Dorado3000 V3, Dorado5000 V3, Dorado6000 V3 and Dorado18000 V3. Based on the CLI provided by the DeviceManager, this document describes how to use various commands classified by functions and how to set the CLI and manage the storage system through these commands.
Rate and give feedback:
Huawei uses machine translation combined with human proofreading to translate this document to different languages in order to help you better understand the content of this document. Note: Even the most advanced machine translation cannot match the quality of professional translators. Huawei shall not bear any responsibility for translation accuracy and it is recommended that you refer to the English document (a link for which has been provided).
create lun

create lun

Function

The create lun command is used to create logical unit numbers (LUNs). After creating a storage pool, you must divide its storage space into one or multiple LUNs so that resources can be more appropriately allocated to application servers.

Format

create lun name=? [ number=? [ suffix_start_index=? ] | lun_id=? | lun_id_list=? [ suffix_start_index=? ] ] pool_id=? [ nas_lun=? ] capacity=? [ [ thresholds_switch=? | thresholds_percent=? ] | write_policy=? | prefetch_policy=? [ prefetch_multiple=? ] [ prefetch_value=? ] | owner_controller=? | io_priority=? | dif_switch=? | lun_type=? [ compression_enabled=? | dedup_enabled=? ] | workload_type_id=? ] [ description=? ]

create lun name=? [ number=? [ suffix_start_index=? ] | lun_id_list=? [ suffix_start_index=? ] ] copy_lun_id=? [ override_capacity=? | override_pool_id=? ] * [ description=? ]

create lun name=? remote_lun_wwn_list=? storage_pool_id=? [ write_policy=? ] [ prefetch_policy=? ] [ prefetch_multiple=? ] [ prefetch_value=? ] [ io_priority=? ] [ owner_controller=? ] [ lun_id=? ] [ dif_switch=? ] [ description=? ]

create lun name=? vvol_type=? [ number=? [ suffix_start_index=? ] ] storage_pool_id=? [ owner_controller=? ] [ lun_id=? ] [ description=? ]

Parameters

Parameter

Description

Value

name=?

Name of a LUN that you want to create.

  • The value contains 1 to 31 ASCII characters, including digits, letters, underscores (_), hyphens (-), and periods (.).
  • When LUNs are created in a batch by assigning the number=? parameter, the created LUNs will be auto-named by appending four digits starting from 0000 to each name. For example, if you specify the LUN name as LUN, the created LUNs will be auto-named LUN0000, LUN0001, and so on.
NOTE:

When LUNs are created in a batch, the length of name=? cannot exceed 27 characters.

number=?

Number of LUNs that are created in a batch. This parameter cannot be used along with the lun_id=? and lun_id_list=? parameters.

The value ranges from 2 to 500.

The default value is "1".

copy_lun_id=?

ID of a source LUN whose attributes that you want to copy. Using this parameter synchronizes the attributes of a source LUN, excluding the LUN ID and capacity, with the newly created LUN.

To obtain the value, run "show lun general".

pool_id=?

ID of a storage pool to which a created LUN belongs.

To obtain the value, run "show storage_pool general".

nas_lun=?

Whether it is a NAS LUN.

NOTE:

Dorado3000 V3 does not support this parameter.

The value can be:

  • "yes": It is a NAS LUN.
  • "no": It is not a NAS LUN.

remote_lun_wwn_list=?

WWN of a remote LUN.

To obtain the value, run the "show remote_lun general" command.

override_capacity=?

Capacity of a new LUN which will be created using the attributes of a source LUN.

  • The value is in the format of "capacity+unit", where the unit is case-insensitive and can be KB, MB, GB, or TB.
  • The value ranges from 512 KB to 256 TB.

The capacity of a new LUN equals that of a source LUN if this parameter will not be used.

override_pool_id=?

ID of the storage pool to which a new LUN belongs. The LUN will be created using the attributes of a source LUN.

To obtain the value, run "show storage_pool general".

A new LUN and a source LUN belong to the same storage pool if this parameter will not be used.

capacity=?

Capacity of a newly created LUN.

  • The value is in the format of capacity+unit, where the unit can be KB, MB, GB, TB or Blocks.
  • The value ranges from 512 KB to 256 TB.
  • One block equals 512 bytes.
  • When the unit is GB or TB, a decimal number can be used.
  • "remain" indicates that all the remaining space in a pool is used to create a LUN.
  • When "nas_lun" is set to "yes", the capacity can only be 256 GB, 1 TB, 4 TB, or 16 TB.

lun_type=?

Type of a LUN.

The value can be "thin". When a LUN is being created, the capacity of a LUN is automatically allocated by the system. The capacity cannot exceed the maximum value (specified by the capacity parameter).

vvol_type=?

VVol type.

The value must be "PE_LUN". "PE_LUN" indicates that the LUN is a PE LUN.

storage_pool_id=?

ID of the storage pool to which a LUN belongs.

To obtain the value, run the "show storage_pool general" command.

write_policy=?

Cache write policy.

The value can be "write_through" or "write_back", where:

  • "write_through": indicates write through. The system considers that a data write is successful only after data is written to disks. Disks are accessed in each data write.
  • "write_back": indicates write back. After data is written to the cache of the local controller, the system considers that a data write is successful. In addition, the data will be written to the cache of the peer controller as a mirror. When certain conditions are met, the caches write data to disks.

The default value is "write_back".

prefetch_policy=?

Cache prefetch policy.

The value can be "none", "constant", "variable", or "intelligent", where:

  • "none": non-prefetch.
  • "constant": constant prefetch.
  • "variable": variable prefetch.
  • "intelligent": intelligent prefetch.

The default value is "intelligent".

prefetch_multiple=?

Cache prefetch multiple. This parameter is required when "prefetch_policy=?" is set to "variable".

The value ranges from 0 to 1024.

prefetch_value=?

Cache prefetch value. When the value of "prefetch_policy=?" is "constant", this parameter is mandatory. When the value is "intelligent", this parameter is optional.

When the value of "prefetch_policy=?" is "constant", this parameter ranges from 0 to 1024 and is expressed in KB. When the value is "intelligent", this parameter ranges from 1024 to 8192 and is expressed in KB.

io_priority=?

I/O priority of a LUN.

The value can be "Low", "Middle", or "High", where:

  • "Low": indicates the low priority.
  • "Middle": indicates the medium priority.
  • "High": indicates the high priority.

The default value is "Low".

owner_controller=?

Owning controller of a LUN.

The value is in the format of "XA", "XB", "XC" or "XD", where "X" is an integer from 0 to 3.

lun_id=?

ID of a LUN that you want to create. This parameter cannot be used along with the number=? parameter.

The value is an integer ranging from 0 to the maximum number of LUNs – 1.

NOTE:

The maximum number of LUNs supported by different product models varies. For details, see section "Software Specifications" in the product description.

The storage system automatically allocates an ID for a newly created LUN if this parameter will not be used.

dif_switch=?

Whether or not to enable the DIF function.

The value can be:

  • "yes": The DIF function will be enabled.
  • "no": The DIF function will not be enabled.

thresholds_switch=?

Switch of the function that triggers an alarm when the threshold of a thin LUN is reached.

The value can be "off" or "on", where:

  • "off": disables the alarm function.
  • "on": enables the alarm function.

The default value is "off".

thresholds_percent=?

Threshold that will trigger an alarm in a thin LUN.

The value ranges from 50 to 99, expressed in %.

The default value is 90.

compression_enabled=?

Indicates whether the compression function is enabled.

The value can be "yes" or "no", where:

  • "yes": The deduplication function will be enabled.
  • "no": The deduplication function will not be enabled.

The default value is "yes".

dedup_enabled=?

Indicates whether the deduplication function is enabled.

The value can be "yes" or "no", where:

  • "yes": The deduplication function will be enabled.
  • "no": The deduplication function will not be enabled.

The default value is "yes".

lun_id_list=?

LUN ID list. This parameter cannot be used along with the lun_id=? or number=? parameter.

The value is an integer ranging from 0 to the maximum number of LUNs – 1.

NOTE:

The maximum number of LUNs supported by different product models varies. For details, see section "Software Specifications" in the product description.

LUN ID ranges are represented by hyphens (-), such as "0,5-8".

suffix_start_index=?

Suffix start index of "name".

The value is an integer between 0 and 9998.

workload_type_id=?

ID of the workload type.

The value is an integer between 0 and 143.

description=?

Description.

-

Level

Administrator

Usage Guidelines

You can create LUNs in either of the following ways:

  • To manually assign the parameters for a LUN to be created.create lun name=? [ number=? [suffix_start_index=?] | lun_id=? | lun_id_list=? [suffix_start_index=?] ] pool_id=? [ nas_lun=? ] capacity=? [ lun_type=? [ thresholds_switch=? | thresholds_percent=? ] | write_policy=? | prefetch_policy=? | owner_controller=? | io_priority=? | dif_switch=? | compression_enabled=? | dedup_enabled=? | workload_type_id=? ] *.
  • To create a LUN by copying the attributes of a source LUN.

create lun name=? [ number=? [suffix_start_index=?] | lun_id_list=? [suffix_start_index=?] ] copy_lun_id=? [ override_capacity=? | override_pool_id=? ] *.

Example

  • Create a LUN and set its parameters as follows:
    • Name: newlun.
    • ID of storage pool: 0
    • LUN capacity: 100 MB.
    admin:/>create lun name=newlun pool_id=0 capacity=100MB 
    Command executed successfully.
  • Create two LUNs and set their parameters as follows:
    • LUN name prefix: newlun-clone
    • Source LUN ID for copying attributes: 2
    • LUN capacity: 200 MB.
    admin:/>create lun name=newlun-clone copy_lun_id=2 override_capacity=200MB number=2 
    Create LUN newlun-clone0000 successfully. 
    Create LUN newlun-clone0001 successfully.
  • Create a thin LUN with the compression function and set its parameters as follows:
    • Name: asdf
    • ID of storage pool: 0
    • LUN capacity: 2 GB
    • LUN type: thin
    • Compression function switch: yes.
    admin:/>create lun name=asdf pool_id=0 capacity=2GB lun_type=thin compression_enabled=yes 
    Command executed successfully.

System Response

None

Translation
Download
Updated: 2019-07-16

Document ID: EDOC1100049140

Views: 116469

Downloads: 134

Average rating:
This Document Applies to these Products
Related Documents
Related Version
Share
Previous Next