---
title: "Jatin Panjwani (@jatinScripter) | Hashnode"
description: "Jatin Panjwani (@jatinScripter) writes on Hashnode. Read their latest articles and follow their work."
url: "https://hashnode.com/@jatinScripter"
---

@jatinScripter

# Jatin Panjwani

@jatinScripter · Joined June 2021

### [Bash script to kill process on the specified port](https://jatinpanjwani.hashnode.dev/bash-script-to-kill-process-on-the-specified-port?utm_source=hashnode&utm_medium=feed)

#!/bin/bash echo Enter port number to kill read port\_number pid="$(lsof -i:$port\_number | awk '{ print $2 }' | sed -n 2p)" kill -9 $pid echo $? How to run it? ./killProcessOnPort.sh Terminal will ask you the port number to kill. and we are good to go...

1 min read · [jatinpanjwani.hashnode.dev](https://jatinpanjwani.hashnode.dev/bash-script-to-kill-process-on-the-specified-port?utm_source=hashnode&utm_medium=feed)

[Jul 8, 2021](https://hashnode.com/posts/bash-script-to-kill-process-on-the-specified-port/60e6e901c32fbd1b737214f6)
