Friday, October 28, 2016

How to find port conflict issue and How to resolve port conflict


Why port conflict issue comes :-

If a port is assign to more than one process or jvm is become the issue for port conflict.

Follow step to resolve the port conflict

lets assume that we are starting a jvm and after 2 min it through exception failed to start.

1. Go to the log directory for that server and open the file SystemOut.log file
     there you will find that port conflict like 9060 or something else.

2.  first we need to check that which process is use this port

3. use lsof command to find that process

          Execute this command   lsof  -i :9060

4. Out will come like this

      [root@localhost bin]# lsof -i :9060
      COMMAND   PID USER   FD   TYPE DEVICE SIZE/OFF NODE NAME
                   java    10407 root  203u  IPv6  69266      0t0  TCP *:9060 (LISTEN)


PID is 10407

5.  find the process with the help of pid

Execute the command 

 ps -ef |grep 10407

see the screenshot for more information.









as per process id this port is assign to dmgr

Solution :- either stop the dmgr service or assign the new port to server.

No comments:

Post a Comment