Use the wizard in the NAS console to configure and mount an NFS file system without running manual commands. The file system and the ECS instance must be in the same VPC.
Limitations
-
Operating system: Only Linux ECS instances are supported. The one-click mount feature is not supported on CoreOS, FreeBSD, and Fedora CoreOS.
If you use Red Hat Enterprise Linux, you must install the Cloud Assistant Agent with an RPM package before mounting the file system. For more information, see Install the Cloud Assistant Agent on a Linux instance (RPM).
-
Network type: ECS instances and mount targets in the classic network are not supported. The ECS instance and the mount target must be in the same VPC.
-
Instance status: The ECS instance must be in the Running (
Running) state. -
Protocol type: Only file systems that use the NFS protocol are supported. This feature is not available for SMB file systems.
Prerequisites
Make sure that the following resources are ready:
-
An NFS file system is created. For more information, see Create a file system.
-
A mount target is added. For more information, see Add a mount target.
-
A Linux ECS instance is created in the same region and VPC as the file system. For more information, see Create an instance by using the custom launch tab.
Mount the file system
-
Log on to the NAS console.
-
Go to the File System List page, and select the region where the file system is located from the top navigation bar.
-
Find the file system and click Mount in the Actions column.
-
In the Mount panel, complete the following steps:
-
Select a mount target and click Next.
-
Select the target ECS instance and click Next.
Select an ECS instance that is in the same VPC as the file system. If the instance is in a different VPC, NAS warns you that the network may be unavailable.
Note-
If you cannot find the target ECS instance in the drop-down list, refresh the page and try again.
-
You can select only one ECS instance at a time. To mount the file system on multiple ECS instances, see Mount an NFS file system on multiple ECS instances.
-
To mount a file system across VPCs in the same region, see Mount a NAS file system across VPCs in the same region by using Cloud Enterprise Network.
-
-
Configure the mount parameters and click Mount.
Parameter
Description
Mount path
The absolute local path on the ECS instance. The path must start with a forward slash (
/), for example,/mnt. If the directory does not exist, NAS automatically creates it.NoteWe recommend that you use an empty directory. After the file system is mounted, the directory displays the content of the NAS file system, and the original local data in the directory is temporarily inaccessible.
Auto mount
Automatic Mount at Startup is selected by default. If you enable this option, the file system is automatically remounted when the ECS instance restarts.
Protocol type
The NFS protocol version:
-
NFSv3 (Recommended for General-purpose NAS): Use this version when multiple ECS instances do not need to write to the same file simultaneously. It offers better performance than NFSv4.0.
-
NFSv4.0: General-purpose NAS supports NFSv4.0. Use this version when multiple ECS instances need to modify the same file simultaneously.
Extreme NAS file systems support only NFSv3.
NAS directory
The directory in the NAS file system to mount:
-
General-purpose NAS: The root directory (/) or any subdirectory such as /abc.
NoteIf the specified directory does not exist, you can select Confirm New Directory to create the directory in the file system. When you create the directory, you can also set the UID, GID, and POSIX permissions. If you do not configure these parameters, the default values are used.
-
Extreme NAS: By default, the root path (/) is mounted to the /share directory. If you specify a subpath such as /subdir, it is mounted to /share/subdir. If the subdirectory does not exist, it is automatically created.
UID
The user ID (UID) of the new directory's owner. The default value is
0(therootuser). This setting is required only when you create a new directory.GID
The group ID (GID) of the new directory's owner group. The default value is
0(therootgroup). This setting is required only when you create a new directory.POSIX permissions
The POSIX permissions for the new NAS directory. The default value is
0755. This setting is required only when you create a new directory.Mount parameters
Use the default mount parameters unless you have specific requirements. For more information about the parameters, see Parameter description.
-
-
-
Click Complete. The mount process takes about 1 to 2 minutes.
View the mount status in the panel:
-
Mounted: The file system is successfully mounted. You can log on to the ECS instance to access the file system at the configured mount path.
-
Mount Failed: The following table lists common causes and solutions. For more troubleshooting information, use the troubleshooting tool. For more information, see Automatic check script for failures to mount an NFS file system on a Linux instance.
Symptom
Possible cause
Solution
The mount path does not exist.
The specified local directory is not created.
Make sure that the path starts with
/, or allow NAS to automatically create the directory.A "network unavailable" error is reported.
The ECS instance and the mount target are in different VPCs.
Make sure that the ECS instance and mount target are in the same VPC, or configure cross-VPC access.
The subdirectory does not exist.
The specified NAS subdirectory does not exist.
Mount the root directory (
/), create the subdirectory in the file system, and then remount the file system.The ECS instance is not found in the instance list.
The instance is not in the Running state, or the page has not been refreshed.
Make sure that the instance is in the Running state. Then, refresh the page and try again.
-
Check mount status
-
Click the ID of the target file system to open its details page.
-
Click Mount Targets to view the list of mount targets.
-
Find the target mount target and click Mount in the Actions column. In the Mount panel, find the target ECS instance and click Query Mount Details in the Actions column.
-
View the mount details and configuration information of the ECS instance.
Unmount the file system
You can unmount a file system from an ECS instance in the console using one of the following methods.
From the file system list page
-
In the Actions column for the target file system, click the
icon and select Unmount. -
In the Unmount panel, complete the following steps:
-
Select the mount target and click Next.
-
Select the ECS instance from which you want to unmount the file system, and then click Next.
-
Select the unmount path and click Unmount.
-
From the mount usage page
-
On the Mount Targets page, find the target mount target and click Unmount in the Actions column.
-
In the Unmount panel, complete the following steps:
-
Select the ECS instance from which you want to unmount the file system, and then click Next.
-
Select the unmount path and click Unmount.
-
FAQ
-
Which operating systems and file system protocols does the one-click mount feature support?
-
What are the possible causes for a file system mount failure in the console?
For more information about mount issues, see FAQ about mounting and accessing file systems.
Related topics
-
To mount and access a NAS file system from a non-Alibaba Cloud compute node such as an on-premises server or a personal computer, see Access file systems from on-premises data centers.
-
To mount and access a NAS file system across regions, VPCs, or accounts, see Access a file system across networks or accounts.
-
By default, General-purpose NAS file systems use the Standard storage class. To reduce costs, you can convert the storage class to Infrequent Access (IA) or Archive. For more information, see Set a lifecycle policy.
-
To limit the number or size of files in a directory of a General-purpose NAS file system, or to limit the resource usage of a user, use the directory quota feature.
-
To periodically back up data in a NAS file system to prevent data loss, use Cloud Backup. For more information, see Back up and restore files.
-
To prevent permanent data loss from accidental deletion, enable the recycle bin feature. After you enable this feature, deleted files or directories are temporarily stored in the recycle bin and are permanently deleted after the retention period expires. Within the retention period, you can restore the files and their metadata, such as UIDs, GIDs, and ACLs. For more information, see Recycle bin.