In today's society, computers are becoming more and more popular. We use computers, but we know how computers work? The essential part of computers is the operating system. The development of the Linux operating system is very rapid, and there is a trend to catch up with Microsoft. Here is the knowledge of the Linux operating system, so that you can learn to use the Linux operating system. Today, I will explain the killing process under the Linux operating system. I hope you will remember to kill the process under the Linux operating system. After collecting and sorting out the materials related to the killing process of the Linux operating system, I would like to recommend this article here, I hope that you will have a lot of gains after watching it.
1. kill
Role: Kill process according to process number
Usage: kill [signal code] Process ID
Example:
[root@localhost ~]# ps auxf |
Grep httpd
Note: kill -9 to force termination to exit
Example [root@localhost ~]# ps aux |
Grep gaim
or [root@localhost ~]# pgrep -l gaim 5031 gaim
5031 gaim
[root@localhost ~]# kill -9 5031
Special Usage:
kill -STOP [pid]
Send SIGSTOP (17,19,23) to stop a process without the Linux operating system killing the process.
kill -CONT [pid]
Send SIGCONT (19,18,25) to restart a stopped process.
kill -KILL [pid]
Sending SIGKILL (9) forces the process to stop immediately and does not perform cleanup operations.
kill -9 -1
Terminate all processes you have.
2. killall
Role: Kill all processes directly by the name of the program
Usage: killall Name of the running program
Example: Br>
[root@localhost beinan]# pgrep -l gaim 2979 gaim
[root@localhost beinan]# killall gaim
Note: This command can be forced with -9 parameters Kill Process
3. pkill
Role: Kill all processes directly by the name of the program
Usage: #pkill Name of the running program
Example:
[root@localhost beinan]# pgrep -l gaim 2979 gaim
[root@localhost beinan]# pkill gaim
4 Xkill
Function: A program that kills the desktop graphical interface.
Example of application situation: When firefox crashes and cannot exit, you can kill firefox with a click of the mouse.
When xkill runs out and the icon of the individual brain, which graphics program crashes a bit is OK.
If you want to terminate xkill, right click to cancel;
Call method:
[root@localhost ~]# xkill
◆Note:< Br>
KILLALL
NAME (name)
killall - kills processes by name on the Linux operating system
SYNOPSIS (overview)
Killall [-egiqvw] [-signal] name ...
killall -l
killall -V
DESCRIPTION (description)
killall Send a Signals to all processes running any given command. If no signal name is specified, SIGTERM. is sent.
Signals can be specified by name (eg -HUP) or by number (eg -1). Signal 0 (checking for the presence of a process) can only be specified numerically.
If the command name includes a slash (/), the process executing that particular file will be killed, regardless of the process name.
If there is no process to kill for the listed commands, killall will return a non-zero value. If at least one process is killed for each command, killall returns 0. The Killall process never kills itself (but can kill other killall processes).
OPTIONS (options)
-e For very long names, exact matching is required. If a command name is longer than 15 characters, the entire name may not be used (overflow). In this case, killall kills all processes that match the first 15 characters of the name. With the -e option, such records are ignored. If the -v option is also specified, killall prints a message for each ignored record. .
-g kills processes belonging to this process group. The kill signal is sent to each group only once, even if multiple processes are included in the same process group.
-i interactive mode, asking for confirmation before the Linux operating system kills the process.
-l lists all known signal names.
-q If there is no process to kill, no complaints will be made.
-v Reports whether the signal was successfully sent.
-V displays version information.
-w waits for all killed processes to die. Killall will check every second if any killed processes still exist, only return after all dead. Note: If the signal is ignored or not working, Or the process stays in the zombie state, and killall may wait forever.
FILES (related files)
The location of the /proc proc file system.
KNOWN bugS (known BUGS)
Killing files only works for executables that are always open at execution time, that is, mixed executables cannot pass Kill this way.
The caveat is that typing killall name may not produce the expected results on non-Linux operating systems, especially when privileged users are performing.
In the gap between scans, if the process disappears and is replaced by a new process with the same PID, killall -w is not detected.
Learn about killing processes under the Linux operating system.
On the linux device model online, there are some discussions, some things I used to use, to modify a
Webalizer is a commonly used web log analysis script under Linux, of course, for nginx. I am curious
Among the many members of the MCU family, MCS-51 series MCUs occupy industrial measurement and contr
2011 is the 20th anniversary of Linux and the 18th anniversary of the Debian release. Linux has expe
Centos crack password and run level
CentOS Linux VPS installs IPSec+L2TP VPN
Linux development model and operating mechanism
Git and Github first use basic tutorials
WindowsXP classic failure network failure articles
How to clear the old Linux kernel
Two ways to install SUSE Linux10 on a hard disk
Centos 6 error after closing ipv6: Module off not found Solution
Linux regularly performs tasks. Implementation Tutorial
Set the script to self-starting under Linux system
Ordinary users under Linux can not directly use crontab problem
Make:arm-linux- conmand not found error handling discussion
Caption: The evolution of Win3.0 to Win8 Task Manager Evolution
How do I run the Win8 start screen as an administrator?
Win8 system virtual hotspot sharing Internet access method
Win8 system Microsoft Pinyin input method how to play full-width characters
How does Win8 cancel the timed shutdown? Win8 closes the method of timing shutdown task
Linux find naming fast find poisoning file operation example
An alternative way to quickly start a Windows 7 system
There is no playlist resolution when playing media or video under Vista
The function and related knowledge of the Svchost.exe process is revealed