Pages

Thursday, October 25, 2012

amazon s3 eucalyptus

amazon s3 eucalyptus

Amazon S3 (Simple Storage Service) enables user to store / retrieve
Files .
Amazon S3 is called as Walrus in Eucalyptus
Amazon S3 technical terms are as follows

Normal TermsAmazon S3 Terms
FolderBucket
FilesObjects
Read FileGet Object
Save FilePut Object

Beside storing / retrieving objects , Amazon S3 Supports to publish a file to every one, so that any person with the link, shall download the file. (Like publishing a file in google docs)
Amazon S3 API Supports  privileges  to buckets / objects.
 
This post is with respect to connecting Amazon S3 API with Eucalyptus Open Source Version (2.0.3).
Amazon S3 Tools - Eucalyptus :

Assuming, you are using debian based linux.
Install the following packages.
apt-get install libdigest-hmac-perl
apt-get install curl

The following shows how to put / get objects into Eucalyptus Walrus

S3 Curl is basically a perl script.



Getting the jet3t S3 GUI tool to work with Walrus (Eucalyptus S3)


I found the following link from eucalyptus forums, how to connect to Eucalyptus Walrus with Jet3t .


http://blog.ibd.com/scalable-deployment/getting-the-jet3t-s3-gui-tool-to-work-with-walrus-eucalyptus-s3/

 

 

 You can get the Jets3t from the following link

https://bitbucket.org/jmurty/jets3t

 

 Jet3t is basically Java Swing Application.

To connect to Eucalyptus Walrus, Property file needs to be changed.


First unzip the archive.

unzip jets3t-0.9.0.zip
cd jets3t-0.9.0 
cd configs

You need to edit jets3t.properties file to connect to Eucalyptus


Line:37:  s3service.https-only=falseLine:39:  s3service.s3-endpoint=<CloudControllerIP>
Line:40:  s3service.s3-endpoint-http-port=8773
Line:41:  s3service.s3-endpoint-https-port=8443
Line:42:  s3service.disable-dns-buckets=true


In Line 54,be sure about the endpoint property

s3service.s3-endpoint-virtual-path=/services/Walrus

A sample property is shown below.

###
# RestS3Service
###
s3service.https-only=false

s3service.s3-endpoint=<Cloud Controller IP>
s3service.s3-endpoint-http-port=8773
s3service.s3-endpoint-https-port=8443
s3service.disable-dns-buckets=true

s3service.default-bucket-location=US

s3service.enable-storage-classes=true
s3service.default-storage-class=STANDARD
#s3service.default-storage-class=REDUCED_REDUNDANCY

# Uncomment this directive to use Amazon S3's server-side encryption
#s3service.server-side-encryption=AES256

# Virtual path for non-standard servers, such as Eucalyptus
s3service.s3-endpoint-virtual-path=/services/Walrus

cd ../bin 
chmod 777 cockpit.sh 
./cockpit.sh
A Window will be opened. Refer the screenshot.





Now enter the accesskeys / Secret keys from Eucalyptus Portal and click Login.

Now you see a progress screen, validating the Credentials


After successful login,you will get a similar screen shown below, where you can create / delete  bucket, change ACL for a bucket.




To make an object in a bucket to be  accessible to every one, you need to give full ACL to the Object and the Entire bucket.

Next right click on the particular object and select "Generate public GET URL".





Now you need to copy the URL and paste in a browser.
You will be able to download the object from the bucket.

1 comment: