Installing MongoDB on an EC2 Linux instance

This applies to Fedora/CentOS/RedHat distributions of Linux.

Log in to the instance is as root

Add the 10gen MongoDB repository for yum, by creating the file /etc/yum.repos.d/10gen-mongodb.repo

For 64-bit version of MongoDB, add the following

name=10gen Repository

For 32-bit version of MongoDB, add the following

name=10gen Repository

Install MongoDB by running the following command

yum install mongo-10gen mongo-10gen-server

Modify the file /etc/mongod.conf Change the location of DB, logs files, ports as necessary


If you have changed the location of the db or log files, make sure that mongod has write permissions at the new locations. If not assign persmission

chown mongod:mongod /newlocation/mongodbfiles

Start MongoDB server

service mongod start
/etc/init.d/mongod start

To start MongoDB on server reboot

chkconfig --levels 235 mongod on

Connecting to an EC2 instance using Putty, WinSCP and a PEM file

First install the necessary tools

From this site (, install Putty and PuttyGen.

From this site (, install WinSCP.

Convert the PEM file to a PPK file

When you created the EC2 instance, you were given a private key file (extension: .pem). This private key file is in a form called PEM – “Private Enhanced Mail”. Putty cannot work with PEM files. Putty uses a different format called PPK. You can convert the PEM to PPK file using Puttygen.

  1. Run Puttygen.
  2. From the menu option “Conversions”, select “Import key”
  3. In the dialog, locate the pem file and “Open” it.
  4. Change the comment from ‘imported-openssh-key” to a something more descriptive like “my-db-server”
  5. Optional: Enter a passphrase.
  6. Create PPK file by clicking on “Save private key”

Connect to the server using WinSCP

  1. Run WinSCP
  2. In the Login dialog, click on the “New” button
  3. Enter the “Host” name or IP address
  4. Enter “User name” (ec2-user, root etc.)
  5. Select the PPK file in box “Private key file”
  6. Click on “Save…” and give it a descritive name like “my-db-server”
  7. Close and run WinSCP again, this time select server name and click in the “Login” button

Connect to the server using Putty

  1. Configure WinSCP to invoke Putty
  2. Goto “Options->Preferences”
  3. Select “Integrations/Applications”
  4. Locate putty.exe and click on “OK”
  5. Restart WinSCP and login to the server.
  6. From the WinSCP toolbar click, on the Putty icon (usually 8th icon from the left)
  7. You should be now logged into the server using Putty.

Disabling Internet Explorer’s “Enhanced Security Configuration”

Turning off Internet Explorer Enhanced Security Configuration in Windows Server 2003

  1. Start -> Control Panel -> Add/Remove Programs -> Add/Remove Windows Component
  2. Un-check “Internet Explorer Enhanced Security Configuration”
    • To disable this for Administrators but not for all users, leave this option checked and click on the “Details” button”
  3. Click next

Turning off Internet Explorer Enhanced Security Configuration in Windows Server 2008

  1. Start -> Administrative Tools -> Server Manager
  2. Under “Security Information” section in the main (right hand side) pane, click on “Configure IE ESC”
  3. A dialog box will be shown, where it can be disabled for Administrators or Users or both. Make the choice and click “OK”

Minimum set of jar files for Apache Axis2 1.6.1

Apache Axis2 1.6.1 comes with 67 jar files. There is little to no documentation on the jar file dependencies. So do you need all of these jar files for you project? Perhaps not.

For my project, I needed just the following.

  • axiom-api-1.2.12.jar
  • axiom-impl-1.2.12.jar
  • axis2-adb-1.6.1.jar
  • axis2-kernel-1.6.1.jar
  • axis2-transport-http-1.6.1.jar
  • axis2-transport-local-1.6.1.jar
  • axis2-xmlbeans-1.6.1.jar (optional)
  • commons-codec-1.3.jar
  • commons-httpclient-3.1.jar
  • commons-logging-1.1.1.jar
  • httpcore-4.0.jar
  • mail-1.4.jar
  • neethi-3.0.1.jar
  • woden-api-1.0M9.jar
  • woden-impl-dom-1.0M9.jar
  • wsdl4j-1.6.2.jar
  • wstx-asl-3.2.9.jar
  • xmlbeans-2.3.0.jar (optional)
  • XmlSchema-1.4.7.jar