Want to kill a ping job, kill:argument should be jobs or process id's

Google "unix signals" will illuminate the subject. So will the on-line manual pages: man manl

In Unix, signals provide a generic mechanism for providing external, unsolicited, input to a running process. Processes are divided into:
  1. the process you are currently running in the foreground (which requires no additional identification); and
  2. any other process (you will generally have automatic rights to send signals to those that you own).
The command stty -a will show the keyboard input required to send a signal to the process you are currently running in the foreground. Look at the "cchars".

These "cchars" can be tailored to your individual choice, but most people leave them set at their default values. See stty(1)().

See kill(1)() for how to send a signal to any running process, and signal(3)() for the list of signals available.

The short answer to your question is that typing "^C" generally sends signal SIGINT to the process you are running, and SIGINT will generally terminate the process.

If you wish to kill a process by name, see killall(1)().
 
after "ping www.bing.com" I use ctrl+c to suspend it
What is the correct terminate command to input?

Why not try $ ping -c 3 bing.com and limit your ping thing instead?

Code:
$ ping -c 3 bing.com
PING bing.com (13.107.21.200): 56 data bytes

--- bing.com ping statistics ---
3 packets transmitted, 0 packets received, 100.0% packet loss
 
To kill by name, there is also pkill. The kill command uses PID, but pkill uses the name of the process. For ping itself Trihexagonal's suggestion seems easiest to me ping -c 3 or ping -c 2 (or even ping -c 1 if one response is enough for you) to limit the amount of times ping is sent.
 
Back
Top