Skip to content

Instantly share code, notes, and snippets.

@eonist
Created December 1, 2025 06:38
Show Gist options
  • Select an option

  • Save eonist/49148df5097e2348541c94f20c71d6ad to your computer and use it in GitHub Desktop.

Select an option

Save eonist/49148df5097e2348541c94f20c71d6ad to your computer and use it in GitHub Desktop.
Kill process on port

Use lsof to find the process using port 3055, then kill it by PID in Terminal.[1][2]

Step 1: Find the PID on port 3055

Run this in Terminal:

sudo lsof -i :3055

This lists processes using port 3055; look in the PID column to get the process ID you want to stop.[2][3]

Step 2: Kill the process

Once you have the PID (replace 12345 with the actual number):

kill 12345

If the process does not stop, you can force kill it (more aggressive, use only if needed):

kill -9 12345

This frees port 3055 so another app can bind to it.[4][1][2]

One-line shortcut

If you just want a quick one-liner for that specific port:

kill -15 $(lsof -t -i :3055)

This finds the PID using port 3055 and sends it a normal terminate signal in one command.[5][6]

1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment