Setting Up a New GenePattern AMI  Print-icon

The following steps are necessary to create a new GenePattern instance from the GenePattern Amazon Machine Image (AMI).

Create your Amazon account (if you do not already have one)

  1. Set up an Amazon Web Services account.
    1. Go to http://aws.amazon.com and click Sign Up Now. Sign in to an existing Amazon account or create a new one.
    2. Go to http://aws.amazon.com/ec2 and click Sign Up Now. After completing sign up, you should be at the EC2 console.
    3. In the Navigation menu, click Key Pairs.
    4. Click the Create Key Pair button and then save the key pair to a file. Name it something you will remember, like "GenePattern."  This is private key that is used in creating SSH connections to new AMI instances.
  2. Set up your Amazon API credentials.
    1. Select Account>Security Credentials.
    2. Click the X.509 Certificates tab.
    3. Click to Create a New Certificate. Note: An Amazon account may have two certificates.  If your account already has two certificates, you will need to use one of them, or delete one and create a new one.
    4. Download the private key and certificate, and save them in a known location, for example. ~/.ec2/prikey.pem and ~/.ec2/cert.pem.
    5. Make sure these files have the correct security, otherwise using them for SSH will not work: chmod 600 ~/.ec2/*.pem

Create a new instance of the GenePattern AMI

  1. Go to the AMI creation link: https://console.aws.amazon.com/ec2/home?region=us-east-1#launchAmi=ami-5f24ee36
  2. If you are not already logged in, log into Amazon Web Services.
  3. If Amazon prompts you for a region, select us-east-1a, as the GenePattern AMI has only been made available for that region.
  4. Follow the steps in the wizard.
    • Make sure to select the Key Pair you just created.
    • Feel free to use the default Security Group.  This group should have port 8080 open by default.  If you are using a custom security group, make sure that port 8080 is open.
  5. The new instance will appear in your list of instances in the AWS Management Console.
  6. SSH into the new GenePattern AMI instance using username and password "genepattern".
  7. Edit /home/genepattern/GenePatternServer/resources/genepattern.properties by changing GenePatternURL to point to the instance URL.
    • If you are using your own domain name, you will need to point the domain name at the Amazon Public DNS address.  Your domain name provider should have more information on how to do that.
    • If you are not using a domain name, the address you will need to enter is the Amazon Public DNS.  This can be found by selecting the newly-created GenePattern instance in the EC2 console.

Mounting EBS storage for use with GenePattern (optional)

Note: If one opts not to set up EBS storage, files will be saved on the GenePattern instance's file system.  This file system is sufficient only for a small number of GenePattern files.

  1. Create the EBS
    1. Go to http://aws.amazon.com/ec2 and sign in.
    2. Select Volumes>Create Volume.
    3. When the dialog box appears, enter the size of the EBS volume you want to create. We recommend at least 100 GB for GenePattern.  If you are asked for a snapshot, select No Snapshot.  This EBS has to be in the same availability zone as the GenePattern instance (us-east-1a).
    4. Note the ID of the EBS once created. You will need this shortly.
  2. Attach the EBS to the GenePattern Instance
    1. Under Volumes, select the EBS volume that you have just created.
    2. Click Attach Volume and select your GenePattern instance from the list.
    3. Click Attach and wait several minutes for the volume to finish attaching.
    4. Note the device name of the attached EBS.
  3. Mount the EBS in the GenePattern Instance
    1. SSH into your GenePattern instance using username and password "genepattern".
    2. Confirm that the EBS has finished attaching by running "cat /proc/partitions" and making sure the attached name appears in the list.
    3. If you need to format the EBS, run "sudo /sbin/fdisk ATTACHED" where "ATTACHED" is the attached name you were shown for the EBS, for example "/dev/sdk". Follow the prompts. This should give you a partition name, for example "/dev/sdk1". Make note of this.
    4. If you need to partition the EBS (you will need to partition the EBS unless you are using a pre-existing EBS), run "sudo /sbin/mkfs -t ext3 PARTITION" where "PARTITION" is the partition name you were just given.
    5. To mount the partition, run "sudo mount PARTITION /home/genepattern/GenePatternServer/data" where "PARTITION" is the partition name you were just given.

Start your GenePattern AMI

  1. You can start GenePattern by running: /home/genepattern/GenePatternServer/StartGenePatternServer
  2. You can view your GenePattern instance by navigating to http://ADDRESS:8080/gp where ADDRESS is the domain name in use or the Amazon Public DNS address.
  3. GenePattern log files can be found at: /home/genepattern/GenePatternServer/Tomcat/logs/

<< Integrating GenePattern with Existing Tools Up >>

Updated on August 22, 2013 07:32