Skip to content

mini How to create a yas3fs "cluster" on Amazon Linux

gianlucanigro edited this page Dec 8, 2014 · 3 revisions
  1. Install yas3fs

sudo yum -y install fuse fuse-libs

sudo easy_install pip

sudo pip install yas3fs

  1. Create a topic in SNS and take note of the topic ARN

  2. Create a SQS queue for every EC2 instance joining the cluster

  3. Subscribe every queue created in step 3 to the SNS topic created in step 2

  4. edit /etc/fuse.conf on every EC2 instance removing the leading # on the row containing user_allow_other

  5. create the folder where the S3 bucket will be mounted

  6. edit /etc/rc.local adding

su -c "/usr/bin/yas3fs s3://BUCKET_NAME FULL_PATH_TO_EC2_FOLDER --queue QUEUE_OF_THE_INSTANCE --topic TOPIC_ARN -region AWS_REGION" - ec2-user

  1. reboot the instance and enjoy yas3fs :-)
Clone this wiki locally