Friday, 31 July 2015

Hadoop 2.6.0 Single Node Setup on Fedora

Dear viewers,

This post will help you to single node setup of hadoop 2.6.0 on Fedora or similar systems.

Steps:

1. Install Java if not exists. (Version 1.6 +)
use sudo yum install java-package-name
After installation, cross check it by below commands

[pavan@Pavan ~]$ java -version
java version "1.7.0_b147-icedtea"
OpenJDK Runtime Environment (fedora-2.1.fc17.6-x86_64)
OpenJDK 64-Bit Server VM (build 22.0-b10, mixed mode)

[pavan@Pavan ~]$ which java
/usr/bin/java

[pavan@Pavan ~]$ whereis java
java: /bin/java /usr/bin/java /etc/java /lib64/java /usr/lib64/java /usr/share/java /usr/share/man/man1/java.1.gz


Run JSP Servlet in Apache Tomcat No Eclipse

Dear viewers,

This post will help you to run JSP and Servlet in Apache Tomcat without using any IDE (for e.g. Eclipse, NetBeans)

Prerequisite:
1. Apache Tomcat
  - I have apache-tomcat-7.0.63 on my Fedora machine.
2. Java
  - I have java-1.7.0-openjdk-1.7.0.3.x86_64 installed on my machine


Wednesday, 29 July 2015

Java program to perform 64-bits numbers multiplication using shared memory concept

/*
    Title: Java program to perform 64-bits numbers multiplication using memorymapped files and utility classes
    -- Memorymapped files have been used to simulate shared memory concepts in Java. Multiple threads can be though of other alternative here
    -- 19 digits input is accepted which in turns represent 64-bits
    -- School multiplication methos is applied
    -- For simplicity block of 8 bytes is used for multiplication
*/


Wednesday, 15 July 2015

Mongodb commands to play with databases and collections

Dear Viewers,

This post helps to create and drop database, create and drop collections in mongodb.

I assume that you have mongodb and required JDK version present on your Linux machine. For demonstration purpose, I have used Fedora 17.