ossfs allows you to mount Object Storage Service (OSS) buckets as local file systems in Linux. Then, you can manage OSS objects in the same manner as you manage local files.
ossfs is developed based on the file system in userspace (fuse), and can only be run on machines that support fuse. OSS provides installation packages for Ubuntu and CentOS. To run the packages in other environments, use source code to build the required program.
You can use ossfs over the Alibaba Cloud internal network or over the Internet. To improve the speed and stability of access, we recommend that you use an internal endpoint within the internal network environment.
ossfs is built based on S3FS and incorporates all S3FS features, including:
- Support most features of the POSIX file system. For example, you can upload and download objects and directories, and configure user permissions.
- Use multipart upload and resumable upload provided by OSS to upload objects by default.
- Support MD5 verification to ensure data integrity.
- An Archive bucket cannot be mounted as local file systems in Linux.
- ossfs is unsuitable for scenarios that require highly concurrent read and write operations.
- If you use ossfs to edit an object in OSS, the object is uploaded again.
- When you perform metadata-related operations such as list directory, the performance of ossfs is compromised because you must remotely access the OSS server.
- Errors may occur if you rename an object or a directory. Operation failures may cause data inconsistency between OSS and local disks.
- If an OSS bucket is attached to multiple clients, you are responsible for maintaining data consistency. We recommend that you schedule the time for your users to use objects to prevent multiple clients from writing to the same object at the same time.
- Hard links are not supported.
- If the upload is interrupted before the object is completely uploaded, the uploaded data is stored as parts in an OSS bucket. To avoid additional storage fees, we recommend that you use one of the following methods to delete these parts if you no longer need them: