NP++ pattern


for matching

/* 1: */


MS Font for J2EE Web application Deploying in Linux

Add this dependency to your projects POM






Red Hat Linux 6.6 configuring firewall

Found a superb command for configuring firewall in redhat linux



Postgresql 9.5 and Red Hat Enterprise Linux 7.0

I used to use Postgresql 9.5 with Red Hat Enterprise Linux 6.6.

As quite a long time passed using them, I had change my server configuration. So, I tried to start using Postgresql 9.5 and Red Hat Enterprise Linux 7.0 . When started installing them, I found out that these completely new command set.  Here it goes,

rpm -ivh pgdg-redhat95-9.5-3.noarch.rpm
yum install postgresql95-server.x86_64

Read more of this post

Check Linux Max Directory Size

Check Linux Max Directory Size

du -h –max-depth=1 | sort -hr

JSF : Check Version

JSF : Check Version

String version = FacesContext.class.getPackage().getImplementationVersion();

Tomcat – java.lang.OutOfMemoryError


find catalina.bat and add

# for out of memory
# Ensure that any user defined CLASSPATH variables are not used on startup,
# but allow them to be specified in, in rare case when it is needed.

if [ -r “$CATALINA_BASE/bin/” ]; then
elif [ -r “$CATALINA_HOME/bin/” ]; then

Read more of this post

Postgresql : moving data from windows to linux

I was trying to move my database from Windows server to Linux server. I thought it will be a simple process. But, it is not. It took backup from windows server via pgAdmin III. and tried to restore the backup to linux server via command line.

pg_restore -d dbname -U username -C /home/back1.backup

Then I got peer authentication error. so i fixed my pg_hba.conf file. It was

local   all             all                                     peer

I changed it to

local   all             all                                     trust

Then again I tried to run restore command. I got the following error.

pg_restore: [archiver (db)] Error while PROCESSING TOC:
pg_restore: [archiver (db)] Error from TOC entry 2021; 1262 16483 DATABASE dbname dbname
pg_restore: [archiver (db)] could not execute query: ERROR: invalid locale name: “English_United States.1252”
Command was: CREATE DATABASE dbname WITH TEMPLATE = template0 ENCODING = ‘UTF8’ LC_COLLATE = ‘English_United States.1252’ LC_CTYPE = ‘Engli…
WARNING: errors ignored on restore: 1

Read more of this post

JDK installation in Redhat Linux

I had OpenJDK installed in my Redhat Linux. That openJDK was 1.6, i wanted to install jdk 1.7 from

So at first I had to uninstall OpenJDK. So,

yum remove java-1.6.0-openjdk.x86_64

Then I downloaded jdk-7u79-linux-x64.rpm from the above link.

I copied the rpm to /usr/java and issued command as root

rpm -ivh jdk-7u79-linux-x64.rpm

after installation I issued

java -version

To check the installation.

The result. hmmmm….

java version “1.7.0_79”
Java(TM) SE Runtime Environment (build 1.7.0_79-b15)
Java HotSpot(TM) 64-Bit Server VM (build 24.79-b02, mixed mode)

Looks like we are cool.

Making an executable jar file


Right click on your Java Project and select Export.

Select Java -> Runnable JAR file -> Next.

Select the Launch Configuration and choose project file as your Main class

Select the Destination folder where you would like to save it and click Finish.


java -jar <jar-file-name>.jar