How to find what process is using a port in AIX 5L and above.
There have been a lot of threads about how to find processes that are using a specific port on an AIX server. After long hours of research and reading countless "you can't do that" responses, I finally found the answer.
YES IT CAN BE DONE! YES ITS EASY. NO, I DON'T KNOW WHY NO ONE GETS THIS ANSWER WHEN THEY ASK.
So here it is:
Recently, we had an issue with a port conflict on our server. Something was LISTENING on port 14248. You can find whether a port is in use by using the netstat command and grepping for the port number in question.
However, this is not enough to tell you what process is using the port, only that its being used. You can, however, add the -A argument to the netstat command and then use that output as an argument to the rmsock command to find the PID of the process using the port.
Walla!! We see that the Tivoli java process is using port 14248.
Enjoy your new found power to find what process is using a port on your AIX server!
Cheers,
Troy Morton
Senior Technical Analyst
Hospital Sisters Health Systems
There have been a lot of threads about how to find processes that are using a specific port on an AIX server. After long hours of research and reading countless "you can't do that" responses, I finally found the answer.[...]
In the AIX Toolbox for Linux, there is a program called "lsof" which makes finding this information even easier. It can be downloaded from IBM's website here:
You can pass it a "-i" followed by a colon and port number and you'll be shown the PID of the process using that port number (use the "grep LISTEN" to get the listening port and not the established connections):
hi,
i would like to create a bash script that check which port in my Linux server are closed (not in use) from a specific range, port range (3000-3010).
the print output need to be only 1 port, and it will be nice if the output will be saved as a variable or in same file.
my code is:
... (2 Replies)
i want to kill a tcp connection by killing its pid
with netstat -an i got the tcp ip connection on port 5914
but when i type ps -a or ps-e there is not such process running on port 5914
is it possible that because i do not log on with proper user account i can not see that process running? (30 Replies)
Hi All,
My application has specific processes when the developers start using respective GUI . I would like to find related process on server side that is older than 15 days for my application.
I am using AIX 6.0. Could you please help with the command on how to find the older process?
... (5 Replies)
Hi.
I am looking for a command that will return me the amount of CPU used by a specific process in AIX environment.
I know there is TOPAS - but it is interactive and I need to get this information from system that connects remotely via SSH.
Using writing to files and than reading them is also... (1 Reply)
Unix gurus,
I have a requirement wherein I want to find the port number for a given process id.
Is it possible? If so how?
TIA,
Regards,
Praveen (3 Replies)
Hello All,
I wanna find the CPU utilization of a specific process running on AIX OS. I have its pid, but not sure about the command.
iostat
sar 5 5
vmstat
All the above give me system CPU utilization. Is there a way to find for a specific pid???
Thanks,
Ankita (11 Replies)
How to find the process that is using the port 80 and apache server.
When i used the command 'netstat -a|grep 80' it given that port 80 is in listening mode.
I had used the following command:
telnet localhost 80
GET /
I had got some HTML script.
But when I accessed the GUI ( url is... (7 Replies)
Hi Unix Gurus,
Can we find out the port number used by the oracle process is running.I tried to search the forum but coudnt find.
Can anyone help me out with the command (2 Replies)