Code: lsof -i tcp:22 | grep ESTABLISHED | awk '{print $2}' | xargs echo kill That will list the pid's to be killed Code: lsof -i tcp:22 | grep ESTABLISHED | awk '{print $2}' | xargs kill That will kill them Reactions: eva2000