| | 2 | |
| | 3 | === What is Cloud Computing? === |
| | 4 | |
| | 5 | Cloud Computing is a form of computation and storage that |
| | 6 | hides the complexity of hardware and software management |
| | 7 | from a user. Typically, cloud computing services allow you |
| | 8 | to rent computing or storage services. These services |
| | 9 | charge on a pay-per-use basis (roughly, about 0.10 per CPU |
| | 10 | hour or per GB/month). Cloud computing services such as |
| | 11 | Amazon's Elastic Compute Cloud (EC2) also allow one to |
| | 12 | tailor a computing environment through the use of virtual |
| | 13 | machines. In addition, Amazon offers a Simple Storage |
| | 14 | Service (S3) for enabling remote storage. |
| 11 | | This Quick Start guide assumes you already have some experience (and accounts) with Amazon's EC2 and S3. If not, see the detailed starting instructions. |
| | 24 | We have created a custom virtual machine with a BOINC server |
| | 25 | installed and configured. This includes all server software |
| | 26 | prerequisites and the correct permissions and accounts |
| | 27 | already setup. All you need to do is to deploy this virtual |
| | 28 | machine image on the cloud and your server should be up and |
| | 29 | running. This guide describes how to deploy this Amazon |
| | 30 | Machine Image (AMI) over Amazon's EC2 cloud. This can be |
| | 31 | done in minutes. |
| 37 | | 2. [http://developer.amazonwebservices.com/connect/entry.jspa?externalID=368 Install Amazon's AMI tools.] |
| | 62 | Then login to the instance: |
| | 63 | |
| | 64 | {{{ ssh -i [private_key] root@ec2-XXX-XXX-XXX-XXX.z-2.compute-1.amazonaws.com }}} |
| | 65 | |
| | 66 | In the home directory is a README.txt file with important |
| | 67 | information. |
| | 68 | |
| | 69 | === Setting Up a Test Project === |
| | 70 | |
| | 71 | Here we describe how to create a test project using the |
| | 72 | uppercase application. |
| | 73 | |
| | 74 | As root, |
| | 75 | |
| | 76 | {{{sudo boincadm; cd}}} |
| | 77 | |
| | 78 | Create a test project uppercase: |
| | 79 | |
| | 80 | {{{~/boinc/tools/make_project --url_base http://ec2-XXX-XXX-XXX-XXX.z-2.compute-1.amazonaws.com --test_app cplan}}} |
| | 81 | |
| | 82 | Answer yes to all questions. |
| | 83 | |
| | 84 | {{{ cd ~/projects/cplan}}} |
| | 85 | |
| | 86 | {{{{bin/xadd}}} |
| | 87 | |
| | 88 | {{{bin/update_version}}} |
| | 89 | |
| | 90 | {{{bin/start}}} |
| | 91 | |
| | 92 | To check that all daemons are running: |
| | 93 | |
| | 94 | {{{bin/status}}} |
| | 95 | |
| | 96 | Now any [http://boinc.berkeley.edu/download.php BOINC client] should be able to attach to the project and download |
| | 97 | workunits. |
| | 98 | |
| | 99 | === Technical Notes === |
| | 100 | |
| | 101 | Below is not required reading, but we describe how and why |
| | 102 | the image was built. |
| | 103 | |
| | 104 | ==== Why Xen? ==== |
| | 105 | |
| | 106 | The general approach was to build a Debian EC2 AMI from a |
| | 107 | Xen image. (The alternative approach was to use an existing |
| | 108 | Debian AMI.) However, we chose the Xen approach primarily |
| | 109 | to be able to install and test things without having to |
| | 110 | worry about EC2 hourly costs. As a side-effect, one can use |
| | 111 | the Xen image either as a standalone server or over EC2 (as |
| | 112 | it's Xen based). |
| | 113 | |
| | 114 | [http://jimmyg.org/2007/09/01/custom-debian-ec2-amis-from-xen-images/ This describes the setup involved.] |
| | 115 | |
| | 116 | If you would like to use the Xen image directly, you can |
| | 117 | download the Xen image |
| | 118 | [http://mescal.imag.fr/membres/derrick.kondo/disk.img.tgz disk.img.tgz (MB)] and |
| | 119 | [http://mescal.imag.fr/membres/derrick.kondo/swap.img.tgz swap.img.tgz (MB)] and go from there. |
| | 120 | |
| | 121 | ==== Configuration ==== |
| | 122 | |
| | 123 | The hostname can change each time an instance is started. |
| | 124 | As such, the start-up script {{{rc.local}}} was modified to query |
| | 125 | Amazon for the hostname and to set it at each boot. |
| | 126 | |
| | 127 | {{{rc.local}}} is also configured to randomly change the root |
| | 128 | password at each boot, and to download your ssh public key |
| | 129 | and cat it to the authorized_keys file to allow remote |
| | 130 | passwordless access. |
| | 131 | |
| | 132 | ==== IP Address ==== |
| | 133 | |
| | 134 | The IP address could change each time the instance is |
| | 135 | created. To associate a fixed address (regardless of the |
| | 136 | instance), one should use |
| | 137 | [http://aws.amazon.com/ec2/ Amazon's Elastic IP Addresses]. |
| | 138 | |
| | 139 | In addition, one can configure the image to use dynamic DNS |
| | 140 | to associate a domain name with the instance. See the following links. |
| | 141 | [http://www.ioncannon.net/system-administration/120/dynamic-dns-with-ec2-and-zoneedit/ Dynamic DNS with ZoneEdit] |
| | 142 | [http://blog.spaceprogram.com/2008/03/how-to-set-up-dynamic-dns-for-your.html Dynamic DNS Setup] |
| | 143 | |
| | 144 | === To do === |
| | 145 | |
| | 146 | * Consider setting up dynamic DNS by default in the bundle |
| | 147 | |
| | 148 | === Questions? === |
| | 149 | |
| | 150 | Email Derrick Kondo (derrick.kondo :: inria fr) |