Friday, 7 March 2008

How to kill a process in unix

Every so often a test case on our CI machine opens a port for a mock smtp server and then somehow leaves it open. I ssh into the machine and close the port. It usually take me 10 minutes to remember / find the command and 10 seconds to do all the work.

The command that I run is this:
fuser -n tcp -k [port number]

Hopefully I'll be able to find it faster now rather than digging though my email. :-/

No comments:

Post a Comment