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


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


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).
import ssh_host_key_file

import ssh_host_key_file


The import ssh_host_key_file command is used to replace the public key file and private key file on the SSH server.


import ssh_host_key_file key_type=? ip=? user=? password=? public_key_file=? private_key_file=? [ protocol=? ] [ port=? ]






Type of the encryption algorithm for the imported public key file and private key file.

Possible value of the "key_type" parameter is "ecdsa" or "dsa" or "rsa" where:

  • "rsa":Rivest-Shamir-Adleman algorithm(RSA).
  • "dsa":Digital Signature Algorithm(DSA).
  • "ecdsa": Elliptic Curve Digital Signature Algorithm (ECDSA).


IP address of the FTP/SFTP server.



User allowed by the FTP/SFTP server.

The value contains 1 to 64 characters without colons (:).


Password of a user allowed by the FTP/SFTP server.

The value contains 1 to 64 characters.


Path for storing the public key on the FTP/SFTP server.



Path for storing the private key on the FTP/SFTP server.



Protocol used for transmitting the new public and private key.

The value can be "FTP" or "SFTP". The default value is "SFTP".

To ensure the security of data transfer, you are advised to use Secure File Transfer Protocol (SFTP).


Port of the FTP/SFTP server.

The value is an integer ranging from 1 to 65535.

  • If protocol=FTP, the default value is "21".
  • If protocol=SFTP, the default value is "22".


Super administrator

Usage Guidelines

If you want to use your own SSH public key file and private key file, perform the following steps:

  • Use the ssh-keygen tool to generate a public key file and private key file encrypted with RSA, DSA, or ECDSA algorithm.
  • Run the import ssh_host_key_file command to import the public key file and private key file.

If a public key file or private key file is encrypted with a non-RSA, non-DSA, and non-ECDSA algorithm, or an illegal public key file and an illegal private key file are imported, the RSA, DSA, or ECDSA algorithm will not be used for connection encryption when an SSH connection is set up the next time.


Replace the ECDSA public key file and private key file on the SSH server with the ECDSA public key file and private key file provided by the user.

admin/>import ssh_host_key_file key_type=ecdsa ip= user=admin password=****** private_key_file=ssh_host_ecdsa_key protocol=FTP port=21 
WARNING:You are about to replace the existing SSH public key file and private key file with a self-released SSH public key file and private key file. This operation may cause the Linux-based SSH client unable to connect to the storage array. 
Suggestion:Before you perform this operation, implement the following steps: 
1. Ensure that the existing SSH public key file and private key file need to be replaced. 
2. If the SSH client cannot connect to the storage array, manually clear historical records in file /root/.ssh/known_hosts and reconnect to the storage array. 
Have you read danger alert message carefully?(y/n)y 

Are you sure you really want to perform the operation?(y/n)Y 
Command executed successfully.

System Response


Updated: 2019-07-16

Document ID: EDOC1100049140

Views: 120916

Downloads: 149

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