local-user ftp-directory

Function

The local-user ftp-directory command sets the File Transfer Protocol (FTP) directory for the local user.

The undo local-user ftp-directory command restores the default FTP directory for the local user.

By default, the FTP directory for the local user is null.

Format

local-user user-name ftp-directory directory

undo local-user user-name ftp-directory

Parameters

Parameter Description Value
user-name

Specifies the username. If the value includes @, the characters before @ are the user name and the characters after @ are the domain name. If the value excludes @, the entire string is the user name and the user belongs to the default domain.

The value is a string of 1 to 253 case-insensitive characters without spaces. If the value includes @, the characters before @ are the user name and the characters after @ are the domain name. If the value excludes @ or the domain name does not exist, the entire string is the user name and the user belongs to the default domain. A user name cannot contain two or more @s.

ftp-directory directory

Specifies the directory that the user accesses when logging in to the device through FTP.

The value is a string of 1 to 255 case-sensitive characters without any space.

Views

AAA view

Default Level

3: Management level

Task Name and Operations

Task Name Operations
aaa write

Usage Guidelines

Usage Scenario

When you need to configure the device as an FTP server so that the local user can access the device through FTP to add, delete, or modify files on the device, you can run the local-user ftp-directory command to set the FTP directory for the local user.

If the FTP directory is unspecified, the local user cannot log in to the device through FTP.

Configuration Impact

When the local-user ftp-directory command is used, the local user accesses the specified FTP directory after logging in to the device through FTP.

Precautions

The FTP directory specified in the local-user ftp-directory command must be an existing and valid one so that the system can identify it. Otherwise, the local user fails to log in to the device through FTP.

A local user attribute change does not apply to online users. The change takes effect after the online users relog in.

Example

# Set the FTP directory for the local user Hello123@163.net to cfcard:/.
<HUAWEI> system-view
[~HUAWEI] aaa
[~HUAWEI-aaa] local-user Hello123@163.net password irreversible-cipher Hello-13579
[~HUAWEI-aaa] local-user Hello123@163.net ftp-directory cfcard:/
Copyright © Huawei Technologies Co., Ltd.
Copyright © Huawei Technologies Co., Ltd.
< Previous topic Next topic >