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

OceanStor 2800 V3 V300R006

This document is applicable to OceanStor 2800 V3. Based on the CLI provided by the DeviceManager, this document describes how to use variouscommands classified by functions and how to set the CLI and manage the storage system throughthese 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).
create share nfs

create share nfs

Function

The create share nfs command is used to create an NFS share.

Format

create share nfs local_path=? [ file_system_id=? ] [ charset=? ] [ lock_type=? ] [ alias=? ] [ audit_items=? ] [ show_snapshot_enabled=? ]

Parameters

Parameter

Description

Value

file_system_id=?

File system ID.

The value ranges from 0 to 65535.

local_path=?

Absolute path of the NFS share.

The value consists of 1 to 1023 characters.

charset=?

Encoding mode of the NFS share.

The value can be "UTF-8", "JIS", "S-JIS", "EUC-JP", "DE", "ZH", "GBK", "EUC-TW", "BIG5", "PT", "FR", "IT", "ES" or "KO", The default value is "UTF-8". where:

  • "UTF-8": UTF-8 encoding.
  • "ZH": simplified Chinese.
  • "GBK": simplified Chinese.
  • "EUC-TW": traditional Chinese.
  • "BIG5": traditional Chinese.
  • "EUC-JP": EUC-JP encoding.
  • "JIS": JIS encoding.
  • "S-JIS": Shift-JIS encoding.
  • "DE": German.
  • "PT": Portuguese.
  • "ES": Spanish.
  • "FR": French.
  • "IT": Italian.
  • "KO": Korean.

lock_type=?

Lock policy type.

The value can be "Mandatory" or "Advisory", The default value is "Mandatory". where:

  • "Mandatory": indicates a mandatory strategy.
  • "Advisory": indicates a advisory strategy.

alias=?

Alias of the NFS share.

The value must start with a slash (/). Except the first slash, the value contains 1 to 255 characters, only including letters, digits, spaces, and special characters (!\"#&%$'()*+-,.:;<=>?@[]^_`{|}~). On the CLI, the following characters need to be represented with escape sequences: "\|" indicates "|", "\\" indicates "\", "\q" indicates "?", and "\s" indicates a space.

audit_items

Audit log option.

The parameter value contains at least one of the following values: "none","all","open","create","read","write","close","delete","rename","get_attr","set_attr","get_security",and "set_security", where:

  • "none": excludes all audit log options.
  • "all": includes all audit log options from "open" to "set_security".
  • "open": opens a file.
  • "create": creates a file.
  • "read": reads a file.
  • "write": writes a file.
  • "close": closes a file.
  • "delete": deletes a file.
  • "rename": renames a file.
  • "get_security": obtains security attributes of a file.
  • "set_security": sets security attributes of a file.
  • "get_attr": obtains file attributes.
  • "set_attr": sets file attributes.

If the parameter value is "all" or "none", no other values can be set.

show_snapshot_enabled=?

Whether the function of showing the .snapshot folder is enabled.

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

  • "yes": the function of showing the .snapshot folder is enabled.
  • "no": the function of showing the .snapshot folder is disabled.

The default value is "yes".

Level

Administrator

Usage Guidelines

None

Example

  • Create an NFS share.
    admin:/>create share nfs local_path=/fs110 file_system_id=0 charset=UTF-8 lock_type=mandatory alias=/share_alias audit_items=read,write show_snapshot_enabled=yes  
    WARNING: You are about to create an NFS share. This operation may cause the following problems: 
    1. If you set the lock policy of the NFS share to "Advisory" in this operation, cross-protocol interworking scenarios may be affected, causing data inconsistency or service interruption. 
    2. If you enable the audit log function of the NFS share in this operation, NFS service performance may decrease. 
    Suggestion: Confirm that you want to perform this operation based on the service type. 
      
    Are you sure you really want to perform the operation?(y/n)y 
    Command executed successfully. 
    admin:/>create share nfs local_path=/fs111 charset=UTF-8 lock_type=Advisory alias=/fs111 audit_items=rename show_snapshot_enabled=no 
    WARNING: You are about to create an NFS share. This operation may cause the following problems: 
    1. If you set the lock policy of the NFS share to "Advisory" in this operation, cross-protocol interworking scenarios may be affected, causing data inconsistency or service interruption. 
    2. If you enable the audit log function of the NFS share in this operation, NFS service performance may decrease. 
    Suggestion: Confirm that you want to perform this operation based on the service type. 
      
    Are you sure you really want to perform the operation?(y/n)y 
    Command executed successfully.
  • Query information about an NFS share.
    admin:/>show share nfs 
      Share ID  File System ID  Local Path  Charset Lock type  Alias Audit Items Show Snapshot Enabled 
      -------- -------------- ----------- ------- --------- ----- ---------- ---- -------- ------- 
      1         1         /     UTF-8     Advisory /fs1 none          Enable 
      2         2         /     UTF-8     Advisory /fs2 none          Disable 
      3         4         /     UTF-8     Advisory /fs3 none          Enable 
      4         5         /     UTF-8     Mandatory  /fs4 none          Disable 
      5         6         /     UTF-8     Mandatory  /fs5 none          Enable 
      6         0         /fs110/  UTF-8     Mandatory  /fs6  read,write         Enable 
      7         3         /fs111/  UTF-8     Advisory /fs111  rename         Enable

System Response

None

Translation
Download
Updated: 2019-07-12

Document ID: EDOC1000138382

Views: 311838

Downloads: 38

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