Sometimes, we want to stop Node.js program from command line.
In this article, we’ll look at how to stop Node.js program from command line.
How to stop Node.js program from command line?
To stop Node.js program from command line, we can use a few key combos or commands.
We can use ctrl + z to suspend the program.
We can use ctrl + c to stop the program.
Also, we can use
ps aux | grep node
to find the process ID of the node program.
Then we can use
kill 9 PROCESS_ID
to run kill with the node‘s process ID to kill node.
We can also use
killall node
to kill all instances of the node program.
Conclusion
To stop Node.js program from command line, we can use a few key combos or commands.
We can use ctrl + z to suspend the program.
We can use ctrl + c to stop the program.