Changes between Version 45 and Version 46 of DICLOUD/GEC12tutorial
- Timestamp:
- 10/28/11 13:12:43 (13 years ago)
Legend:
- Unmodified
- Added
- Removed
- Modified
-
DICLOUD/GEC12tutorial
v45 v46 1 1 = !DiCloud Tutorial at GEC12 = 2 2 3 This page summarizes the !DiCloud tutorial from GEC 12. Slides can be found here.3 This page summarizes the !DiCloud tutorial from GEC 12. Slides can be found [http://groups.geni.net/geni/attachment/wiki/DICLOUD/GEC12tutorial/GEC12tutorial.pptx here]. 4 4 5 5 Tutorial sections: … … 18 18 * '''Tutorial: Running a Gush experiment using !DiCloud and Orca''' 19 19 20 The sections labeled as Setup have already been performed on each tutorial participants' VM image, and can be skipped by tutorial participants. Directions on how the tutorial image for GEC12 was setup are a vailable [http://groups.geni.net/geni/wiki/GEC12VMSetup here]. We provide them here as an example of how to setup an independent !DiCloud deployment from scratch. Note that the setup assumes a user geni exists, and that all !DiCloud files (from [http://geni.cs.umass.edu/dicloud-tutorial.tgz here]) are located in the directory ~/Tutorials/DiCloud.20 The sections labeled as Setup have already been performed on each tutorial participants' VM image, and can be skipped by tutorial participants. Directions on how the tutorial image for GEC12 was setup are also available [http://groups.geni.net/geni/wiki/GEC12VMSetup here]. We provide them here as an example of how to setup an independent !DiCloud deployment from scratch. Note that the setup assumes a user geni exists, and that all !DiCloud files (from [http://groups.geni.net/geni/attachment/wiki/DICLOUD/GEC12tutorial/dicloud-tutorial.tgz here]) are located in the directory ~/Tutorials/DiCloud. 21 21 22 22 == Tutorial: Pre-requisites == … … 51 51 $ sudo add-apt-repository "deb http://archive.canonical.com/ lucid partner" 52 52 $ sudo apt-get update 53 $ sudo apt-get install keychain 53 54 $ sudo apt-get install sun-java6-jdk 54 55 $ sudo apt-get install maven2 … … 62 63 MySQL server will ask you to set a root password. Remember the password. 63 64 64 Finally, we need to sym-link apache's /var/www directory to ~/Tutorials/DiCloud/www to make the web portal available, and change the permissions of ~/Tutorials/DiCloud/www to be owned by www-data (the apache user).65 We need to sym-link apache's /var/www directory to ~/Tutorials/DiCloud/www to make the web portal available, and change the permissions of ~/Tutorials/DiCloud/www to be owned by www-data (the apache user). 65 66 66 67 {{{ … … 76 77 }}} 77 78 79 Finally, we create sym-links to all the keys in the top-level directory to reduce the typing we must do in the console. 80 81 {{{ 82 sudo ln -s /home/geni/Tutorials/DiCloud/ec2/keys/geni_cert.pem /geni_cert.pem 83 sudo ln -s /home/geni/Tutorials/DiCloud/ec2/keys/geni_pk.pem /geni_pk.pem 84 sudo ln -s /home/geni/Tutorials/DiCloud/ec2/keys/geni_cert_web.pem /geni_cert_web.pem 85 sudo ln -s /home/geni/Tutorials/DiCloud/ec2/keys/geni_pk_web.pem /geni_pk_web.pem 86 sudo ln -s /home/geni/Tutorials/DiCloud/ec2/keys/geni-keypair.pem /geni-keypair.pem 87 }}} 88 78 89 == Setup: Configure !DiCloud's MySQL Server == 79 90 … … 179 190 == Tutorial: Using the !DiCloud console == 180 191 181 Open a new terminal. We run ntpdate to make sure the time is accurate. Amazon will fail calls from machines with inaccurate local time. Also, note that we will use the Amazon Machine Image ami- 7f418316 for all VMs. This is a basic VM image that runs a 32-bit version ofLinux. Amazon has thousands of images available for use, including Windows images.192 Open a new terminal. We run ntpdate to make sure the time is accurate. Amazon will fail calls from machines with inaccurate local time. Also, note that we will use the Amazon Machine Image ami-013d6c44 for all VMs in the us-west-1 region. This is a basic VM image that runs a 32-bit version of Debian Linux. Amazon has thousands of images available for use, including Windows images. 182 193 183 194 {{{ … … 187 198 dicloud - not connected>connect localhost 1099 188 199 Connecting to //localhost:1099/dicloud/server 189 dicloud - //localhost:1099>ec2 start / home/geni/Tutorials/DiCloud/ec2/keys/geni_cert......200 dicloud - //localhost:1099>ec2 start /geni_cert.pem /geni_pk.pem ami-013d6c44 1 m1.small us-west-1 geni-keypair 190 201 dicloud - //localhost:1099>help 191 202 Commands available for the main menu are: … … 234 245 dicloud - //localhost:1099>get balance 235 246 Current balance is: $99.53222835338767 236 dicloud - //localhost:1099>ec2 probe / home/geni/Tutorials/DiCloud/ec2/keys/geni_cert.pem /home/geni/Tutorials/DiCloud/ec2/keys/geni_pk.pem i-b87b74d8 us-west-1 ascii247 dicloud - //localhost:1099>ec2 probe /geni_cert.pem /geni_pk.pem i-b87b74d8 us-west-1 ascii 237 248 Instance Id: i-b87b74d8 238 249 AMI Id: ami-7f418316 … … 262 273 {{{ 263 274 dicloud - //localhost:1099>s3 create gec12-tutorial-1 us 264 dicloud - //localhost:1099>s3 put gec12-tutorial-1 test /home/geni/Tutorials/DiCloud/ dicloud/bin/dicloud.properties265 Uploading file /home/geni/Tutorials/DiCloud/ dicloud/bin/dicloud.propertiesas object test in bucket gec12-tutorial-1275 dicloud - //localhost:1099>s3 put gec12-tutorial-1 test /home/geni/Tutorials/DiCloud/s3_test 276 Uploading file /home/geni/Tutorials/DiCloud/s3_test as object test in bucket gec12-tutorial-1 266 277 dicloud - //localhost:1099>s3 get gec12-tutorial-1 test /home/geni/Tutorials/DiCloud/test 267 278 Downloading file /home/geni/Tutorials/DiCloud/test from object test in bucket gec12-tutorial-1dicloud - //localhost:1099> … … 271 282 Example use of EBS 272 283 {{{ 273 dicloud - //localhost:1099>ebs create / home/geni/Tutorials/DiCloud/ec2/keys/geni_cert.pem /home/geni/Tutorials/DiCloud/ec2/keys/geni_pk.pem 1 us-west us-west-1a274 dicloud - //localhost:1099>ebs delete / home/geni/Tutorials/DiCloud/ec2/keys/geni_cert.pem /home/geni/Tutorials/DiCloud/ec2/keys/geni_pk.pem <volume_id> us-west284 dicloud - //localhost:1099>ebs create /geni_cert.pem /geni_pk.pem 1 us-west us-west-1b 285 dicloud - //localhost:1099>ebs delete /geni_cert.pem /geni_pk.pem <volume_id> us-west 275 286 }}} 276 287 … … 310 321 {{{ 311 322 $ cd ~/Tutorials/DiCloud/gush/ 323 $ cp ~/Tutorials/DiCloud/ec2/keys/geni-keypair.pem ~/.ssh/id_rsa 324 $ cp ~/Tutorials/DiCloud/ec2/keys/geni-keypair.pub ~/.ssh/id_rsa.pub 312 325 $ keychain ~/.ssh/id_rsa 313 326 $ ./gush -P 15000 … … 335 348 <software name="SimpleSoftwareName" type="none"> 336 349 <package name="Package" type="web"> 337 <path>http:// localhost/software.tar</path> //Software tarball350 <path>http://geni.cs.umass.edu/software.tar</path> //Software tarball 338 351 <dest_path>software.tar</dest_path> 339 352 </package> … … 398 411 === Start Gush === 399 412 400 Now we are ready to run our example. The following shows the output from a run using two clients. You only need to type the commands that appear after "gush>". 401 402 {{{ 413 Now we are ready to run our example. First, we need to set the appropriate hostnames on each host. Next, the following shows the output from a run using two clients. You only need to type the commands that appear after "gush>". 414 415 {{{ 416 $ ssh root@<Amazon IP 1> “hostname <Insert IP 1>” 417 $ ssh root@<Amazon IP 2> “hostname <Insert IP 2>” 403 418 $ ./gush -P 15000 404 419 gush>