Friday, June 10, 2011

ubuntu jsvc.exec[944]: Error occurred during initialization of VM

So, I moved one of my AMI from Amazons us-east-1 region to ap-southeast-1 and found that tomcat stopped working. Whenever I start it says Fail and nothing else. Looking at the Syslog Logs in /var/log/daemon.log I found the error:

jsvc.exec[944]: Error occurred during initialization of VM#012java/lang/ClassNotFoundException: error in opening JAR file /usr/lib/jvm/java-6-openjdk/jre/lib/rt.jar

Interestingly when I check the path /var/lib/jvm/java-6-openjdk/jre/lib/ I can  very well find rt.jar. Looks like during the copy or somewhere the JVM has been corrupted.. So I decided to reinstall JVM but even though I run below command they did not solve the problem:

sudo apt-get clean
sudo apt-get --reinstall install openjdk-6-jre
sudo dpkg --configure -a

Finally someone suggested me to try below and I tried:

Thursday, June 9, 2011

Modifying event_scheduler using RDS command line tool for APAC region

So here is an example of modifying your DB parameter group in a different region (apac in this example). It modifies the current value of event_scheduler to ON. By default this is set to OFF in RDS.
rds-modify-db-parameter-group mytestparagroup --region ap-southeast-1 --parameters "name=event_scheduler, value=ON, method=immediate"

Wednesday, June 1, 2011

Converting JKS file to p12 format using Keytool.exe


Here is an example of keytool command... this will convert a certificate within JKS file to P12 format.


keytool -importkeystore -srckeystore file.jks -destkeystore file.p12 -srcstoretype JKS -deststoretype PKCS12 -srcstorepass mypassword -deststorepass mypassword -srcalias myaliastname -destalias myaliastname -srckeypass mypassword -destkeypass mypassword

Amazon EC2 Regions

US East (Virginia)
us-east-1a
us-east-1b
us-east-1c
us-east-1d

US West (N. California)
us-west-1a
us-west-1b
us-west-1c

EU West (Ireland)
eu-west-1a
eu-west-1b
eu-west-1c

Asia Pacific (Singapore)
ap-southeast-1a
ap-southeast-1b

Asia Pacific (Tokyo)
ap-northeast-1a
ap-northeast-1b