Saturday, June 24, 2017

db2 backup and drop database

db2 connect to xydb
--the next command forces off the users asynchronously
db2 quiesce database immediate force connections
--but you need to unquiesce to drop
db2 unquiesce database
db2 connect reset
-- hope you don't have a connection in between
-- also make sure the database isn't activated....
db2 deactivate db xydb
-- do this as a safeguard cause there is no going back once you drop it.....
db2 backup db xydb to '<path you provide>' compress
db2 drop db xydb

Thursday, June 8, 2017

kill tomcat linux

* process_name="prmbodev"
* ps -eaf | grep $process_name
* export pid=` ps -eaf | grep  $process_name | grep -v "grep"| awk 'NR==1{print $2}' | cut -d' ' -f1`;kill -9 $pid
* ps -eaf | grep $process_name

Wednesday, June 7, 2017

linux tomcat port open

* logged in as root user
* iptables -L -n -t nat
* iptables -I INPUT -p tcp -m tcp --dport 9020 -j ACCEPT
* service iptables save

Monday, May 29, 2017

activemq port 61616 close/need to open

* First confirm Apache activemq is running
if not than run command in bin folder: activemq start
* iptables -L -n -t nat
* iptables -I INPUT -p tcp -m tcp --dport 61616 -j ACCEPT
* service iptables save

Saturday, May 20, 2017

Kill tomcat service running on any port, Windows

1) Go to (Open) Command Prompt (Press Window + R then type cmd Run this).
2) Run following commands
For all listening ports

netstat -aon | find /i "listening"

Apply port filter

netstat -aon |find /i "listening" |find "8080"

Finally with the PID we can run the following command to kill the process

Copy PID from result set

taskkill /F /PID

Ex: taskkill /F /PID 189

Done !!!


Wednesday, April 19, 2017

How to connect DB2 Server using putty

* Login server using server username and password (this user have to have required permission to access DB2)
db2 "connect to db user un using pwd"

change below values as you required:
DB Name: db 
Logged in Username: un 
Logged in password: pwd

Thursday, April 6, 2017

Let me share the simple way to enable the remote debugging mode in tomcat with eclipse (Windows)

Step 1: open bin/startup.bat file
Step 2: add the below lines for debugging with JDPA option (it should starting line of the file )

  • set JPDA_ADDRESS=9090
  • set JPDA_TRANSPORT=dt_socket

Step 3: in the same file .. go to end of the file modify this line -

    call "%EXECUTABLE%" jpda start %CMD_LINE_ARGS%
    instead of line
    call "%EXECUTABLE%" start %CMD_LINE_ARGS%

step 4: then just run bin>startup.bat (so now your tomcat server run in remote mode with port 9090).

step 5: after that lets connect your source project by eclipse IDE with remote client.

step6: In the Eclipse IDE go to "debug Configuration"

step7:click "remote java application" and on that click "New"

step8. in the "connect" tab set the parameter value

   project= your source project
   connection Type: standard (socket attached)
   host: localhost

step9: click apply and debug.

so finally your eclipse remote client is connected with the running tomcat server (debug mode).

Hope this approach might be help you.

Ref: Link

Monday, February 6, 2017

how to create a free private git repository

Create your project in which is providing 1,00,000 private repository.

You can manage here:
* Import project from others server like github or bitbucket
* Wiki
* Code Snippets
* Powerful APIs
* Control read/write permissions to specific branches
* Track and manage releases
* Issues, Issue Board, Todo
* Milestones
* Powerful diff tools
* Jenkins Integration
* SSH, HTTPS supporting tools

GitLab Enterprise vs GitHub Enterprise

releasedSeptember 2011April 2008
PricingUnlimited public and private repositories / unlimited public and private collaboratorsFree for public repositories / Paid plans for private repositories
Code review featuresyesyes
Bug & issue trackingyesyes
Private branchyesYes (with paid plans)
Build systemyesYes (with 3rd party service)
Self-hostingyesYes (with enterprise plan)
Popularity100.000+ projects35.000.000+ projects
detailed pricingFree: / Free: GitLab Community Edition / $39 / Year: GitLab EnterpriseFree: public projects / $7/month: Personal plan / $25/month: organization plan / $2.500/year: Enterprise