Setting up Amazon S3 Storage on Windows …
30 January, 2007 – 1:33 pmIf you are interested in using Amazon S3 as an alternative backup solution, you may need to move files from your windows box to the S3 storage account. In order to do this I recommend you use a version of rsync written in ruby.
Detailed instructions can be found in this post.
1. Firstly, if you haven’t setup an Amazon S3 storage account, do so here:
Amazon.com: Amazon S3, Amazon Simple Storage Service, Unlimited Online Storage: Amazon Web Services
2. To setup your first bucket you may find it easier using a GUI to begin with. A great open source java toolkit can be downloaded here:
JetS3t – Home
3. To launch JetS3t, from a command line simply run the cockput.bat file included in the bin directory of the install. Alternatively, from a unix terminal, run the shell script included in the bin directory ie. bash cockpit.sh

4. Once JetS3 is running (as a java applet) use the Direct Login tab. By now you should know your AWS Access Key and AWS Secret Key obtained during your account setup at step 1. Enter those details and click the login button.
5. Once logged in you will see your buckets created on the left hand panel with their contents (objects) displayed on the right. If this is your first time you will probably have no buckets. To create one simply use Buckets toolbar icon (confusingly sits to the left of the Object title!)

6. Give the bucket a new name. Keep the unique string to the left of the period, that will help keep your bucket id unique. Click OK and you’re done! You can quit JetS3 after this or play around with its other features. From here on in we use ruby …

7. To syncrhonize directories I use a ruby script call s3sync.rb. You can download the source here:
S3Sync.net - S3Sync Wiki
8. To use ruby scripts on your Windows server, download the one click installer for Ruby here:
RubyForge: One-Click Ruby Installer: Project Info
9. Once you have installed Ruby, you will need to setup environment variables on your windows server that contain the AWS access key and id.
Go to My Computer –> Right Mouse Click –> System Properties –> Advanced Tab –> Environment Variables Button
10. Create two new System variables like the following example:
Variable Value
AWS_ACCESS_KEY_ID 987897NDJHK12897JDN
AWS_SECRET_ACCESS_KEY 78979dsjh9ds7d098s0dskjdhs09dflksjd0f8fs-=f9-0fs
11. Click OK to save the variable information.
12. From a cmd window (or batch file) run the Ruby script as in the following example:
ruby s3sync.rb -d -v -r D:/PATH/TO/YOUR/FOLDER/ 16ZNP93R6M44KJEJ2M202.TestBucket:path/for/remote/folder
13. You will then get detailed progress / debug information on screen about your transfer.









One Response to “Setting up Amazon S3 Storage on Windows …”
Example showing how to access your files from a URL
https://s3.amazonaws.com/16ZNP93R6M44KJEJ2M02.DPHOTO/1/858/large/253173-daa15r-large.jpg
By Tim on Jun 21, 2007