Configuration and usage
To use Mountpoint for Amazon S3, your host needs valid Amazon credentials with access to the bucket or
buckets that you would like to mount. For different ways to authenticate, see
Mountpoint Amazon Credentials
For example, you can create a new Amazon Identity and Access Management (IAM) user and role for this purpose. Make sure that this role has access to the bucket or buckets that you would like to mount. You can pass the IAM role to your Amazon EC2 instance with an instance profile.
Use Mountpoint for Amazon S3 to do the following:
-
Mount buckets with the
mount-s3
command.In the following example, replace
with the name of your S3 bucket, and replaceDOC-EXAMPLE-BUCKET
with the directory on your host where you want your S3 bucket to be mounted.~/mnt
mkdir
~/mnt
mount-s3DOC-EXAMPLE-BUCKET
~/mnt
Because the Mountpoint client runs in the background by default, the
directory now gives you access to the objects in your S3 bucket.~/mnt
-
Access the objects in your bucket through Mountpoint.
After you mount your bucket locally, you can use common Linux commands, such as
cat
orls
, to work with your S3 objects. Mountpoint for Amazon S3 interprets keys in your S3 bucket as file system paths by splitting them on the forward slash (/
) character. For example, if you have the object keyData/2023-01-01.csv
in your bucket, you will have a directory namedData
in your Mountpoint file system, with a file named2023-01-01.csv
inside it.Mountpoint for Amazon S3 intentionally does not implement the full POSIX
standard specification for file systems. Mountpoint is optimized for workloads that need high-throughput read and write access to data stored in Amazon S3 through a file system interface, but that otherwise do not rely on file system features. For more information, see Mountpoint for Amazon S3 file system behavior on GitHub. Customers that need richer file system semantics should consider other Amazon file services, such as Amazon Elastic File System (Amazon EFS) or Amazon FSx . -
Unmount your bucket by using the
umount
command. This command unmounts your S3 bucket and exits Mountpoint.To use the following example command, replace
with the directory on your host where your S3 bucket is mounted.~/mnt
umount
~/mnt
Note
To get a list of options for this command, run
umount --help
.
For additional Mountpoint configuration details, see S3 bucket configuration