What is the difference between Kill and Kill -9 command in Unix?
w
difference kill -9 pid and kill pid command - Ask Ubuntu https://askubuntu.com/questions/791841/difference-kill-9-pid-and-kill-pid-command
kill pid (which sends signal 15 (SIGTERM)) tells pid to terminate, but said program can execute some code first or even ignore the signal. kill -9 pid, on the other hand, forces the program to immediately terminate (it cannot be ignored).
You should always try kill pid first, as it allows the program to do things like saving/closing open files before exiting. Only use kill -9 when you need the program to close and it won't respond to a simple kill pid.
https://www.quora.com/What-is-the-difference-between-Kill-and-Kill-9-command-in-Unix
kill is used to send signal to a process. The default signal is TERM i.e. to terminate(kill) the process. Similar to End Task on windows task manager.
To terminate(kill) any ordinary process :
- kill <pid>
For a highly critical process, which kill alone cannot terminate :
- kill -9 <pid>
where 99 is the strongest signal
https://en.wikipedia.org/wiki/Unix_signal#List_of_signals
SIGKILL 9 Terminate Kill (cannot be caught or ignored).
What is the difference between Kill and Kill -9 command in Unix?的更多相关文章
- 【转载】Linux kill, killall, kill -9
1) 查看进程的方法: ps -ef 或者 ps aux root 15087 0.0 0.0 0 0 ? S 23:31 0:00 [kwo ...
- linux命令kill和kill -9的区别
linux命令kill和kill -9的区别 2018年04月13日 16:53:07 坠入苦海销尘垢 阅读数 2854 转载自https://www.cnblogs.com/liuhouhou/ ...
- ps -ef|grep详解 、kill与kill -9的区别
ps -ef|grep详解 ps命令将某个进程显示出来 grep命令是查找 中间的|是管道命令 是指ps命令与grep同时执行 PS是LINUX下最常用的也是非常强大的进程查看命令 grep命令是查找 ...
- 【Linux常用命令】Linux kill, killall, kill -9,
参考链接 https://blog.csdn.net/zong596568821xp/article/details/77899454 kill + PID kill -9 + PID 加上-9 是 ...
- Linux kill, killall, kill -9
tyle="margin: 20px 0px 0px; font-size: 14px; line-height: 26px; font-family: Arial;"> 附 ...
- kill与kill -9的区别
有时候我们使用kill无法杀掉一个进程,但是用kill -9却可以,why? 首先看一下kill的功能,man手册对kill描述如下: KILL(1) Linux User's Manual KILL ...
- kill 与 kill -9(面试中问道的知识点)
转载自:http://www.2cto.com/os/201305/215267.html 需要特别说明的是,SIGKILL和SIGSTOP这两个信号既不能被应用程序捕获,也不能被操作系统阻塞或忽略. ...
- 授权其他数据库用户kill session
授权其他数据库用户kill session kill session权限 CREATE OR REPLACE PROCEDURE P_KILL_SESSION(P_USER IN VARCHAR2, ...
- MySQL连接线程kill利器之pt-kill
如何每10秒检查一次,杀死指定用户超过100秒的查询? pt-kill \ --no-version-check \ --host 127.0.0.1 --port 3306 --user 'xxxx ...
随机推荐
- P1079Vigenère密码
这是2012年noip提高组的的DAY1T1,我用了一下午的时间,一次性AC^^. 这是一个字符串的模拟题.首先给出了一个密码对应法则,我们发现在同一对角线的明文通过密钥得出来的密文是相同的.根据八皇 ...
- 嵌入式软件工程师C语言经典笔试2
1. 使用宏定义swap函数,不使用中间变量 #define swap(x,y) {(x) = (x) + (y);(y) = (x) - (y);(x) = (x) - (y)} 2. 实现字符串的 ...
- idea 代码部分格式化
效果: 处理Idea使用ctrl+alt+L进行代码格式化时部分代码可以被忽略,不执行格式化功能(webstorm,phpstorm同理) 原因: 有时希望自己写的一些代码不被格式化,或者发现格式化后 ...
- HDU 2196 Computer( 树上节点的最远距离 )
Computer Time Limit: 1000/1000 MS (Java/Others) Memory Limit: 32768/32768 K (Java/Others)Total Su ...
- 如何查看Win10开机运行了多长时间 - Windows10.Pro
原文:如何查看Win10开机运行了多长时间 - Windows10.Pro 方法一:使用Windows PowerShell命令查看 以管理员身份运行Windows PowerShell,在打开的“管 ...
- CSS中:first-child伪类
使用 :first-child 伪类来选择作为某个元素的第一个子元素.这个特定伪类很容易遭到误解,所以有必要举例来说明.考虑以下标记: 如下: html: <div> <p>T ...
- react 从商品详情页返回到商品列表页,列表自动滚动上次浏览的位置
现状:目前从商品详情页返回到商品列表页,还需要再去请求服务数据,还需要用户再去等待获取数据的过程,这样用户体验非常不好, 遇到的问题: 1:如何将数据缓存, 2:如何获取和保存列表滑动的高度, 3:判 ...
- Redis数据结构&命令手册
Redis数据结构&命令手册 Redis数据结构 Redis可以存储键与5种不同数据结构之间的映射,这五种数据结构类型分别为STRING(字符串).LIST(列表).SET(集合).HASH( ...
- C++ md5类,封装好
在网上看到很多md5类,不过封好的很少,我就在网上看到一篇把他写的封装 头文件 #ifndef _MD5_H #define _MD5_H #pragma warning(disable:4786)/ ...
- makeinfo - 翻译 Texinfo 文档
SYNOPSIS 总览 makeinfo [OPTION]... TEXINFO-FILE... DESCRIPTION 描述 将 Texinfo 源文档翻译为各种其他格式,默认是可以用 Emacs ...