Howto stop or terminate Linux command process with CTRL + C

by on July 12, 2007 · 2 comments· LAST UPDATED July 12, 2007

in , ,

Q. Sometime I type command and accidentally hit the [ENTER] key and immeditly realized that it was wrong command. How do I stop process assuming that process is not going in background? For example
cp /path/* /wrong/path

Stop or terminate Linux command process with CTRL + C

A. To stop process hit CTRL + C, for example, you entered:
$ cp -r /path/* /wrong/path

To stop the command hit CTRL+C and retype the command:
$ cp -r /path/* /correct/path

TwitterFacebookGoogle+PDF versionFound an error/typo on this page? Help us!

{ 2 comments… read them below or add one }

1 web design guy August 2, 2009 at 9:18 pm

I read that typing ‘reset’ works, even if you cant see it typing. I just use ctrl+c

Reply

2 takalani October 25, 2013 at 7:45 am

./ManualManageDB.shn /user/SHARK/log_files/sms.cfg 131022

how can i stop that command, it is loading data into mysql table.

Reply

Leave a Comment

Tagged as: , , ,

Previous Faq:

Next Faq: