which command is used to stop a running process in unix?
Answer Posted / rhino
Hi Sivakumar,
When we know the answer it would be good to post it , As
some of them might not able to find the answers and this
site would help them to get their issues addressed. Here is
how this goes
stop <pid> -- is the command to stop , Below example
explains this better
Ex Prog. to print 10000 numbers
#!/bin/sh
x=1
while [ $x -le 10000 ]
do
echo "No is. $x"
x=`expr $x + 1`
done
If you wish to stop this , Login to the different a/c get
the pid of the prog running as this will take some time to
execute you find sufficient time to do this
Login to other session on the same directory -- give ps -a
and check the prog. running stop it using below
ps -a ---> is the command used to check all the processes
running
stop 17872 (17872 is the pid of the program -- This will
stop the prog. as below
o/p :
No is. 8128
No is. 8129
[1] + Stopped (SIGSTOP) ./prnNo1
Is This Answer Correct ? | 3 Yes | 1 No |
Post New Answer View All Answers
Which command is used to delete all files in the current directory and all its sub-directories?
What does the command ' $who | sort –logfile > newfile' do?
Differentiate cmp command from diff command.
What is merge command in unix?
What does grep v do?
Why is grep called grep?
What do chmod, chown, chgrp commands do?
Is there any method to erase all files in the current directory, along with its all sub-directories, by using only one command?
What is unix command?
What is the unix command to confirm a remote host is alive or not?
What does this command do,"$more readme.txt“?
Who wrote grep?
What is “chmod” command?
What is a bash command?
Why is it called a shebang?