How to mount the S3 bucket with Linux EC2 Server by Kv. Reddy. Step 1: Download the ... https://code.google.com/archive/
SUVEN IT
AWS Admin
-An Admin Choice
How to mount the S3 bucket with Linux EC2 Server by Kv. Reddy. Step 1: Download the latest s3fs package from S3fs link https://code.google.com/archive/p/s3fs/downloads
Step 2: Untar the package in EC2 instance. #tar -xvzf s3fs-1.63.tar.gz
Step 3: If it is new centos or ubuntu instance. Update the system . For CentOS or Red Hat yum update all For Ubuntu sudo apt-get update
Step 4: Now install the dependencies. In CentOS or Red Hat yum install gcc libstdc++-devel gcc-c++ fuse fuse-devel curl-devel libxml2-devel openssl-devel mailcap In Ubuntu or Debian apt-get install build-essential gcc libfuse-dev fuse-utils libcurl4-openssl-dev libxml2-dev mime-support build-essential libcurl4-openssl-dev
SUVEN IT || :
[email protected] || Ph: +1 202-403-9022||+ 91- 9515839400 || www.suvenit.com pg|1
SUVEN IT
AWS Admin
-An Admin Choice
Step 5: Now change to extracted directory cd s3fs-1.63
Step 6: Now compiling ./configure --prefix=/usr make make install
Step 7: To check where s3fs command is placed in O.S. It will also tell you the installation is ok. which s3fs
Step 8: Now getting the access key and secret key. Click on AWS Menu -> Your AWS Account Name -> Security Credentials Note: The option is at top Right corner of the aws console page Here you can see access key and secret key (secret key is visible when you click on show tab) Copy these both keys seperately Step 9 : Create a new file in /etc with the name passwd-s3fs Paste the access key and secret key in this manner . accesskey:secretkey Note: colon (:) is require in between of both keys. for eg.
SUVEN IT || :
[email protected] || Ph: +1 202-403-9022||+ 91- 9515839400 || www.suvenit.com pg|2
SUVEN IT
AWS Admin
-An Admin Choice
Access key: bwbshjklwmsysiene7hh Secret key: jdjbeeosakw3389 vi /etc/passwd-s3fs bwbshjklwmsysiene7hh:jdjbeeosakw3389 save and exit from file.
Note: I just gave an eg. of keys by randomely typing the letters. But you have to only paste the keys which you have obtained from "Security Credential" tab -see step 8
Step 10: change the permission of file chmod 640 /etc/passwd-s3fs
Step 11 : now create a directory to mount S3bucket mkdir /mys3bucket
Step 12: Now mount the s3 bucket s3fs bucketname /mys3bucket
Note: you can get bucket name from S3 management console. Step 13: To check mounted s3 bucket df -Th /mys3bucket
Step 14 : If you already had some data in s3bucket and it is not visible then you have to set permission in ACL at S3 AWS management console for related s3 bucket.
SUVEN IT || :
[email protected] || Ph: +1 202-403-9022||+ 91- 9515839400 || www.suvenit.com pg|3
SUVEN IT
AWS Admin
-An Admin Choice
Any Questions
SUVEN IT || :
[email protected] || Ph: +1 202-403-9022||+ 91- 9515839400 || www.suvenit.com pg|4
SUVEN IT
AWS Admin
-An Admin Choice
SUVEN IT
About us SUVEN IT established in 01-Jan--2010 by Mr.
Kv. Reddy having 20 years teaching
and 17 years of real time work experience across USA & India, We are recognized as a leader in all IT training Courses to supply quality IT Professionals to Industry. SUVEN IT committed to provide high quality service with elevated level of student’s satisfaction and provides the high end industry training and real time knowledge to students.
We trained and placed 7000+ Students in top MNC’s in 7 Years (Most of them are selected in first interview)
SUVEN IT || :
[email protected] || Ph: +1 202-403-9022||+ 91- 9515839400 || www.suvenit.com pg|5