Answer Posted / srinivas kalvacherla
How to terminate process by name in UNIX
kill -9 `ps -ef | grep process_name | grep -v grep |
awk '{print $2}'`
Note that the grep process_name should be the command that
you ran. Also note that the commands after 'kill -9' are
enclosed in backtiks.
Is This Answer Correct ? | 7 Yes | 1 No |
Post New Answer View All Answers
Write a command that will allow a unix system to shut down in 15 minutes, after which it will perform a reboot.
What is rmdir command?
How do you grep a case insensitive?
How does the system know where one command ends and another begins?
What is grep in bash?
Why is awk called awk?
Is there any method to erase all files in the current directory, along with its all sub-directories, by using only one command?
What do chmod command do?
Name the various commands that are used for the user information in unix.
What is unix command line?
What is the use of find command in unix?
Describe the usage and functionality of the command rm –r * in unix?
What does the md command do?
What does touch command do in unix?
how to sort the content of the file based on numeric values