Common Procedures


"Restarting" the Virtual Machine

You can't actually restart it, instead you essentially delete it and roll-back to a prior machine image.

  1. Use the EC2 Console  to terminate the instance.
  2. Still in the console, locate the machine image you want to roll back to and Launch an instance of that image.
    1. This post may provide some guidance as to which image to launch.
    2. Specify the details of the instance, we usually create one small instance, use the StandardFirewallRules Security Group, and the BaseAdmin key-pair.
  3. Attach the appropriate Elastic Block Store to the new instance at /dev/sdh.
  4. Follow the directions below to connect to the instance via SSH.
  5. Follow the directions below to mount the Elastic Data Store.
  6. Follow the directions below to start Apache, then PostgreSQL and MySQL, then Tomcat.


Connect to the Instance Using SSH (and PuTTY)

If you already have the .ppk file for the appropriate user that you wish to log in with, use it. You may want to set up SSH Tunneling if you want to use pgAdmin to connect to PostgreSQL.

If you don't have a.ppk file, follow the instructions outlined in this post.


Mounting the Elastic Block Store

First, use the EC2 Console  to attach the volume to the instance at /dev/sdh

mkdir /mnt/data-store
mount /dev/sdf /mnt/data-store


Starting, Stoping, Restarting Applications

These commands should be executed with root privileges

/etc/init.d/apache2 start
/etc/init.d/apache2 stop
/etc/init.d/apache2 reload
/etc/init.d/tomcat6 start
/etc/init.d/tomcat6 stop
/etc/init.d/tomcat6 restart
/etc/init.d/postgresql-8.4 start
/etc/init.d/postgresql-8.4 stop
/etc/init.d/postgresql-8.4 restart
/etc/init.d/mysql start
/etc/init.d/mysql stop
/etc/init.d/mysql restart
Related Community Groups
CSW Debug Blog | 17 Posts | Join
A group blog to discuss metadata Catalog Service for the Web (CSW) implementation experiences
Building a GeoSciML WFS Server | 11 Posts | Join
Development, testing and implementation of a WFS service that returns GeoSciML documents
ETL Debug Blog | 12 Posts | Join
A group blog on implementing and debugging Extract-Transform-Load (ETL) efforts.
Presentations and Posters | 12 Posts | Join
Post your posters and presentations related to USGIN topics.
Metadata interest group | 13 Posts | Join
group for general posting on metadata content, standards, tools
USGIN Amazon Virtual Server Development | 18 Posts | Invite only
Documenting the process of development of a Web Server in the Amazon EC2 environment. Software installations tailored to the requirements for USGIN
GeoNetwork configuration and development | 7 Posts | Join
Discussion on GeoNetwork setup, configuration, and development.
Student Projects | 0 Posts | Join
Discussion of student projects related to USGIN
Drupal Development | 6 Posts | Join
All about bending Drupal to your needs
Geoportal on an Amazon Virtual Machine | 3 Posts | Closed
Installation, configuration, etc.
Using Django for USGIN | 7 Posts | Request membership
Thought and ideas about using Django to accomplish USGIN-related... things.
ArcGIS Server and OGC Services | 3 Posts | Join
Tips on using ArcGIS Server to provide OGC web services
Content model discussion | 0 Posts | Request membership
Community site for comments on development of content models and encoding for information intechange
Making Web Maps | 2 Posts | Request membership
For information about the myriad of mechanisms for showing service data on a web page.
Troubleshooting Web Service Deployment - Blog | 5 Posts | Join
This blog is for documenting our group's experiences with web service deployment.
Best Practices for USGIN Web Service Hosting | 10 Posts | Join
Tips, techniques, and frequently asked questions for hosting AASG Geothermal Data Web Map Services and Web Feature Services
Hub Disaster Recovery | 0 Posts | Request membership
Discussions around how to harden a distributed federated system against disaster; setting up a system to mirror hub VMs at other hubs.