Combine lsof and xargs to terminate port users.
Section: Batch Termination Patterns
Terminate port owners with lsof and xargs
bash
bash
lsof -ti :3000 | xargs -r -n1 kill -TERMExplanation
Combine lsof and xargs to terminate port users.
Learn the surrounding workflow
Compare similar commands or jump into common fixes when this command is part of a bigger troubleshooting path.
Related commands
Same sheet · prioritizing Batch Termination Patterns