find open port and kill code example
Example 1: windows kill port
netstat -ano | findstr :3001
taskkill /PID <yourid> /F
Example 2: debian kill open port
fuser -k 3000/tcp //will kill that process.
netstat -ano | findstr :3001
taskkill /PID <yourid> /F
fuser -k 3000/tcp //will kill that process.