Skip to content
Open
Show file tree
Hide file tree
Changes from all commits
Commits
Show all changes
34 commits
Select commit Hold shift + click to select a range
dd8da1d
README change
Jun 24, 2014
9c512d9
A saner readme
sophiayangyxy Jun 24, 2014
f9c0204
changes to properties
sophiayangyxy Jun 26, 2014
2503281
changes to properties
sophiayangyxy Jun 26, 2014
305d034
add midway local
Jun 26, 2014
045e899
change beagle to remote
sophiayangyxy Jun 26, 2014
5f17538
adding doc
sophiayangyxy Jul 1, 2014
430691f
adding doc
sophiayangyxy Jul 1, 2014
2dc0a6a
changing README
sophiayangyxy Jul 1, 2014
99e8e62
changing README
sophiayangyxy Jul 1, 2014
90ce53c
updating doc
sophiayangyxy Jul 1, 2014
6b883b1
updating doc
sophiayangyxy Jul 2, 2014
7629241
updating doc
sophiayangyxy Jul 2, 2014
64a5387
updating doc
sophiayangyxy Jul 2, 2014
1da3cff
adding html
sophiayangyxy Jul 2, 2014
b72674d
updating doc
sophiayangyxy Jul 2, 2014
58aeea0
updating doc
sophiayangyxy Jul 2, 2014
d1cfc70
add osg config
sophiayangyxy Jul 7, 2014
cdd33d4
link to apps
Jul 7, 2014
4fa952a
change config
sophiayangyxy Jul 7, 2014
9dee019
updating doc
sophiayangyxy Jul 8, 2014
9a66919
updaing
sophiayangyxy Jul 8, 2014
7b2e1f7
updating config
sophiayangyxy Jul 9, 2014
17b74a4
updating
sophiayangyxy Jul 10, 2014
460eb5f
adding part04_new
sophiayangyxy Jul 14, 2014
357c1a1
adding part04_new
sophiayangyxy Jul 14, 2014
5c2a6ff
removing things
sophiayangyxy Jul 14, 2014
1117ae9
removing things
sophiayangyxy Jul 14, 2014
ba9a135
update
sophiayangyxy Jul 14, 2014
2e7e8b6
updating doc
sophiayangyxy Jul 14, 2014
588d9a4
updating doc
sophiayangyxy Jul 14, 2014
93aa612
updating doc
sophiayangyxy Jul 14, 2014
766b75b
updating doc
sophiayangyxy Jul 14, 2014
e8e6ec9
updating doc
sophiayangyxy Jul 14, 2014
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
1 change: 0 additions & 1 deletion README.asc

This file was deleted.

173 changes: 173 additions & 0 deletions README.asc
Original file line number Diff line number Diff line change
@@ -0,0 +1,173 @@
Swift cloud on Google Compute Engine
------------------------------------

Sign up online
^^^^^^^^^^^^^^

1. Go to Google's compute engine https://console.developers.google.com/?getstarted=https://cloud.google.com[page]
2. Create a new project and fill in the project and project id.
3. Select the project and then select compute engine from the left panel.
4. Enter billing information.

NOTE: You should sign into your google account. Once the billing info is set, you might need
to wait a few minutes. Please note the project-name and project-id in the config file in
the swift-on-cloud/compute-engine folder.

Setup local-machine
^^^^^^^^^^^^^^^^^^^

On your local-machine setup Google's cloud SDK based on the document here:
[source,bash]
----
curl https://dl.google.com/dl/cloudsdk/release/install_google_cloud_sdk.bash | bash
# Restart bash session for the changes to kick in.
----

Authenticate via browser, by clicking the link and pasting the response to the commandline
[source,bash]
-----
gcloud auth login
-----

Get the swift-on-cloud repository from git
[source,bash]
-----
git clone git@github.com:yadudoc/swift-on-cloud.git
cd swift-on-cloud/compute-engine
-----



Manage you Cloud resources
^^^^^^^^^^^^^^^^^^^^^^^^^^

Update the file *swift-on-cloud/compute-engine/configs* in the cloned repository from the previous step,
with the following information:

* GCE_PROJECT : Name of project selected during the compute-engine sign up.
* GCE_PROJECTID : This is the unique ID for your project selected during compute-engine sign up.
* WORKER_MACHINE_TYPE, HEADNODE_MACHINE_TYPE: VM types for workers and headnode, choose between:
- 'f1-micro'
- 'g1-small'
- 'n1-standard-<1,2,4,8>'
- 'n1-<highmem/highcpu>-<2,4,8>'
* GCE_WORKER_COUNT : Number of workers to start at setup (pick a number between 1 and 20)
* GCE_ZONE : GCE Region to use (Multiple regions are not supported now). Choose between:
- 'us-central1-a' and 'us-central1-b' (with Sandy bridge processors)
- 'europe-west1-a' and 'europe-west1-b' (with Sandy bridge processors)
- 'asia-east1-a' and 'asia-east1-b' (with Ivy bridge processors)

NOTE: Read more about Compute-engine zones https://developers.google.com/compute/docs/zones[here]

NOTE: GCE_WORKER_COUNT directly affects the cost. If you require more than 22 nodes including the
headnode, file a request to increase your resource quotas.

WARNING: Do *NOT* change the images for the worker and headnode to point at images which have not
been explicitly setup with swift.



Start your cloud setup!
^^^^^^^^^^^^^^^^^^^^^^^

Once you finish editing the configs file with your preferences, start the cloud instances
by sourcing the setup script.

The setup script will setup firewall rules, copy over the required images and start a headnode
and the requested number of worker instances.

[source, bash]
-----
# Must source the setup script.
source setup.sh
-----

NOTE: The setup script will ask for a passphrase when you run it for the first time. If you
give a passphrase, it will be required when you attempt to connect to the cloud instances.

NOTE: The setup.sh script may not work on shells besides bash.


Run swift from your local machine
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^

Now, once you've configured and started you cloud resources we can move on to trying the
swift-cloud-tutorial. To run the cloud tutorial from your local machine :

[source,bash]
-----
cd swift-on-cloud/swift-cloud-tutorial
source setup.sh
-----

NOTE: You must source the setup.sh script.


Run the tutorial on the cloud
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^

Once your cloud resources have been configured and setup, you can run the swift-cloud-tutorial
directly from the cloud. The cloud resources created include a headnode, to which you would
connect to, and the several nodes in worker roles which would do computations in parallel.

To run the tutorial, first connect to the headnode:


[source, bash]
-----
# Connect to the Headnode
connect headnode
# This will have you logged in to the headnode on the cloud
-----


Miscellanious operations supported:
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^

[source, bash]
-----
# Connect to the Headnode
connect headnode
-----

To see resources use :
[source, bash]
-----
list_resources
-----

To ssh to any resource listed :
[source, bash]
-----
# Specify the resource name as listed by list_resources here
# If resource_name is omitted, connect will try to connect to the
# headnode
connect <resource_name>
-----

To stop all resources use from your local machine. Please wait for a couple of minutes
for the command to finish. Confirm that all resources have been removed using
list_resources. :
[source, bash]
-----
# This will delete the headnode as well as all workers.
# This command will take a few minutes to execute
dissolve
# Use list_resources to check if any resources still linger
list_resource
-----

To add more worker nodes use:
[source, bash]
-----
# The number of nodes you can create is limited by the quota's set by google.
# To increase quotas contact google using the change request form available
# under Your project / Compute engine / Quotas tab in developer console
start_n_more <Number of nodes>

# Alternatively update the configs with the total number of nodes you require
# and rerun the setup script
source setup.sh
-----

Note: Creating an Image https://developers.google.com/compute/docs/images#creatingimage[Link]
Binary file modified gce-md-demo/src/md/md
Binary file not shown.
Empty file modified gce-md-demo/test_all.sh
100644 → 100755
Empty file.
Binary file removed gce-md-demo/tutorial.pptx
Binary file not shown.
1 change: 1 addition & 0 deletions swift-cloud-tutorial/app/simulate
1 change: 1 addition & 0 deletions swift-cloud-tutorial/app/stats
Loading