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 10

OceanStor 18500 V3 and 18800 V3 Mission Critical Storage System V300R003

"Based on the CLI, 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. The document that you browse online matches the latest C version of the product. Click Download to download documents of other C versions."
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).
CLI Command Filtering

CLI Command Filtering

You can filter off redundant information from command line interface (CLI) commands to display only the information that you require.

CLI command outputs are displayed in columns and rows. After typing a complete command line, you can see the filterColumn and filterRow commands for respectively filtering columns and rows by entering a vertical bar (|) and pressing the Tab or space key.

Column Filtering Command

show xxx|filterColumn { exclude | include } columnList=? is used to filter column information off a command output. Table 1-3 describes the parameters of the command and their meanings.
NOTE:
  • xxx is the ending keywords of the command that you want to query column information for.
  • If the name of a selected column field contains a space, replace the space with \s. For example, to query the Write Policy column for LUNs, run the following command: show lun general|filterColumn include columnList=Write\sPolicy.
Table 1-3  parameter description for the filterColumn command

Parameter

Description

Value

exclude

Column fields available for filtering that do not need to be displayed.

By typing show xxx|filterColumn exclude and pressing the Tab or space key, you can see all of the applicable column fields.

include

Column fields available for filtering that need to be displayed.

By typing show xxx|filterColumn include and pressing the Tab or space key, you can see all of the applicable column fields.

columnList=?

Column fields that are available for a filtering.

To query multiple column fields, separate them by commas (,) for this parameter.

The following exemplifies how to filter column fields for the show bbu general command.
  1. Query all column fields available for the show bbu general command.
    admin:/>show bbu general |filterColumn exclude//Press Tab
    <columnList=?> column list separated by comma, select one or more seperated by comma,please replace the space with \s in parament.
    columnList=Inter ID 
    columnList=ID 
    columnList=Health Status 
    columnList=Running Status 
    columnList=Current Voltage(V) 
    columnList=Number Of Discharges 
    columnList=Firmware Version 
    columnList=Delivered On 
    columnList=Owning Controller 
    columnList=Electronic Label 
    Query information about the BBU module among all column fields available for filtering, excluding the Electronic Label and Owning Controller.
    admin:/>show bbu general |filterColumn exclude columnList=Electronic\sLabel,Owning\sController
    
    Inter ID ID Health Status Running Status Current Voltage(V) Number Of Discharges Firmware Version Delivered On 
    -------- --------- ------------- -------------- ------------------ -------------------- ---------------- ------------ 
    0.0A.0 CTE0.PSU0 Normal Online 16.1 20 20.06T4 20XX-5-20 
    0.0A.1 CTE0.PSU1 Normal Online 16.1 11 20.06T4 20XX-7-16 
  2. Query all column fields available for the show bbu general command.
    admin:/>show bbu general |filterColumn include//Press Tab
    <columnList=?> column list separated by comma, select one or more seperated by comma,please replace the space with \s in parament.
    columnList=Inter ID 
    columnList=ID 
    columnList=Health Status 
    columnList=Running Status 
    columnList=Current Voltage(V) 
    columnList=Number Of Discharges 
    columnList=Firmware Version 
    columnList=Delivered On 
    columnList=Owning Controller 
    columnList=Electronic Label 
    Query information about the BBU module among all column fields available for filtering, including the Inter ID and ID.
    admin:/>show bbu general |filterColumn include columnList=Inter\sID,ID
    
    Inter ID ID 
    -------- ------ 
    0.0A.0 CTE0.0 
    0.0A.1 CTE0.1 
    0.0B.2 CTE0.2 
    0.0B.3 CTE0.3 

Row Filtering Command

show xxx |filterRow column=? predict=? [ predict2=? ] value=? [ logicOp=? ] is used to filter row information off a command output. Table 1-4 describes the parameters of the command and their meanings.
NOTE:
  • xxx is the ending keyword of the command that you want to query row information for.
  • You can select multiple column fields at one time and use logicOp=? to set up a logical relationship between those fields.
  • If the name of a selected column field contains a space, replace the space with \s. For example, to query the Write Policy column for LUNs, run the following command: show lun general|filterRow column=Write\sPolicy.
Table 1-4  parameter description for the filterRow command

Parameter

Description

Value

column=?

Column fields that you want to include into a filtering.

By typing show xxx|filterRow and pressing the Tab or space key, you can see all of the applicable column fields.

predict=?

A filter condition for selected column fields.

The value can be not, equal_to, greater_than, greater_equal, less_than, less_equal, or match. The following describes those values:
  • not: indicates the logical NOT operator. This value must be used along with predict2=? to eliminate the values or value ranges excluded by the predict2=? and value=? combination.
  • equal_to: indicates that the value of a field must be equal to value=?.
  • greater_than: indicates that the value of a field must be greater than value=?.
  • greater_equal: indicates that the value of a field must be no less than value=?.
  • less_than: indicates that the value of a field must be less than value=?.
  • less_equal: indicates that the value of a field must be no greater than value=?.
  • match: indicates that the value of a field matches with value=? in regular expressions.

predict2=?

Additional filter condition for selected column fields. This parameter is required when predict=? is set to not.

The value can be equal_to, greater_than, greater_equal, less_than, less_equal, or match. The following describes those values:
  • equal_to: indicates that the value of a field must be equal to value=?.
  • greater_than: indicates that the value of a field must be greater than value=?.
  • greater_equal: indicates that the value of a field must be no less than value=?.
  • less_than: indicates that the value of a field must be less than value=?.
  • less_equal: indicates that the value of a field must be no greater than value=?.
  • match: indicates that the value of a field matches with value=? in regular expressions.

value=?

Value of a field.

-

logicOp=?

Logical relationship between column fields. By using this command, you can select multiple column fields at one time and set up a relationship between those fields.

The value can be and or or. The following describes those values:
  • and: Displays the information that matches with multiple column=? values.
  • or: Displays the information that matches with any column=? value.
The following command instances use the show lun general command as an example.
  1. To query the column fields available for the show lun general command, run the following command:
    admin:/>show lun general|filterRow  //Press Tab
    <column=?>          column
    column=ID                                 
    column=Name                               
    column=Pool ID                            
    column=Capacity                           
    column=Subscribed Capacity                
    column=Protection Capacity                
    column=Sector Size                        
    column=Health Status                      
    column=Running Status                     
    column=Type                               
    column=IO Priority                        
    column=WWN                                
    column=Exposed To Initiator               
    column=Data Distributing                  
    column=Write Policy                       
    column=Running Write Policy               
    column=Prefetch Policy                    
    column=Read Cache Policy                  
    column=Write Cache Policy                 
    column=Cache Partition ID                 
    column=Prefetch Value                     
    column=Owner Controller                   
    column=Work Controller                    
    column=Snapshot ID(s)                     
    column=LUN Copy ID(s)                     
    column=Remote Replication ID(s)           
    column=Split Clone ID(s)                  
    column=Relocation Policy                  
    column=Initial Distribute Policy          
    column=SmartQoS Policy ID                 
    column=Protection Duration(days)          
    column=Has Protected For(h)               
    column=Estimated Data To Move To Tier0    
    column=Estimated Data To Move To Tier1    
    column=Estimated Data To Move To Tier2    
    column=Is Add To Lun Group                
    column=DIF Switch  
  2. To query the information about the LUN whose name is LUN005 from the preceding available fields, run the following command:
    admin:/>show lun general|filterRow column=Name predict=equal_to value=LUN005
    
      ID  Name              Pool ID  Capacity    Health Status  Running Status  Type   
      --  ----------------  -------  ----------  -------------  --------------  -----  
      5   LUN005            0           5.000GB  Normal         Online          Thick  
      
      WWN                               Is Add To Lun Group  DIF Switch  
      --------------------------------  -------------------  ----------  
      633343710036383904e5fcaf00000005          No              No     
    
  3. To query the information about the LUN whose owning storage pool and owning controller are storage pool 1 and controller 0A respectively, run the following command:
    admin:/>show lun general|filterRow column=Pool\sID predict=equal_to value=1 logicOp=and column=Owner\sController predict=equal_to value=0A
    ID  Name       Pool ID          Capacity  Health   Running   Type   WWN
                                              Status   Status
    --  ---------  ---------------  --------  ------   --------  ----   ----
    3   LUN002     1                1.000GB   Normal   Online    Thick  --
    6   yushi0000  1                3.000GB   Normal   Online    Thin   --
    7   yushi0001  1                3.000GB   Normal   Online    Thin   --
    11  newlun0001 1                2.000GB   Normal   Online    Thin   --
Translation
Download
Updated: 2019-07-22

Document ID: EDOC1000084078

Views: 289575

Downloads: 252

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