• Status: Solved
  • Priority: Medium
  • Security: Public
  • Views: 4672
  • Last Modified:

How do I break out of terminal commands?

Okay, this is an easy one.  I'm learning Linux and don't know the Windows equivalent to Ctrl-Break.

For example, I type "ping yahoo.com" at a terminal prompt and it just keeps going.... how do I stop it.  Another example is the "top" command, how do I exit the utility??

I'm stuck in a Windows world and want to escape soon!
0
chadly2
Asked:
chadly2
  • 2
1 Solution
 
chadly2Author Commented:
I figured it out, Ctrl-C or Ctrl-Z.... but what's the difference.  Does one Kill the process versus End?
0
 
arjanhCommented:
Ctrl-c is indeed for cancelling something.

ctrl-z is for putting something in the background. This can be handy for long-lasting commands and you want to do something else on the same command prompt... After ctrl-z you can give the command 'bg' to continue the process in the background. The results of the ping will still be printed though. With 'fg' you can bring the command back to the foreground.
0
 
arjanhCommented:
'top' can also be exited by pressing 'q' by the way
0
Question has a verified solution.

Are you are experiencing a similar issue? Get a personalized answer when you ask a related question.

Have a better answer? Share it in a comment.

Join & Write a Comment

Featured Post

Cloud Class® Course: Amazon Web Services - Basic

Are you thinking about creating an Amazon Web Services account for your business? Not sure where to start? In this course you’ll get an overview of the history of AWS and take a tour of their user interface.

  • 2
Tackle projects and never again get stuck behind a technical roadblock.
Join Now