sqlserver check running process 1
check process script 1, check which is current running:
use master
SELECT
spid,ER.percent_complete,
CAST(((DATEDIFF(s,start_time,GetDate()))/3600) as varchar) + ' hour(s), '
+ CAST((DATEDIFF(s,start_time,GetDate())%3600)/60 as varchar) + 'min, '
+ CAST((DATEDIFF(s,start_time,GetDate())%60) as varchar) + ' sec' as running_time,
CAST((estimated_completion_time/3600000) as varchar) + ' hour(s), '
+ CAST((estimated_completion_time %3600000)/60000 as varchar) + 'min, '
+ CAST((estimated_completion_time %60000)/1000 as varchar) + ' sec' as est_time_to_go,
DATEADD(second,estimated_completion_time/1000, getdate()) as est_completion_time,
ER.command,ER.blocking_session_id, SP.DBID,LASTWAITTYPE,
DB_NAME(SP.DBID) AS DBNAME,
SUBSTRING(est.text, (ER.statement_start_offset/2)+1,
((CASE ER.statement_end_offset
WHEN -1 THEN DATALENGTH(est.text)
ELSE ER.statement_end_offset
END - ER.statement_start_offset)/2) + 1) AS QueryText,
TEXT,CPU,HOSTNAME,LOGIN_TIME,LOGINAME,
SP.status,PROGRAM_NAME,NT_DOMAIN, NT_USERNAME
FROM sysprocesses SP
INNER JOIN
sys.dm_exec_requests ER
ON SP.spid = ER.session_id
CROSS APPLY sys.dm_exec_sql_text(ER.sql_handle) est

You see if there happen lock , you can see them
After that you may execute "kill xxx"
sqlserver check running process 1的更多相关文章
- PLT redirection through shared object injection into a running process
PLT redirection through shared object injection into a running process
- 搭建zookeeper出现错误:starting zookeeper... already running process 2853
今天搭建zookeeper时碰到了starting zookeeper already running process 2853这样一个错误. 上网上查了几个相似的问题都是要删除zookeeper_s ...
- check running processes in Ubuntu
Check processes If you want to see what processes are running use the command ps -ef If you want to ...
- Inno Setup Pascal Script to search for running process
I am currently trying to do a validation at the uninstall moment. In a Pascal script function, in In ...
- Linux process authority、the security risks in running process with high authority
catalog . Linux进程权限原理 . 最小权限原则 - 进程降权运行最佳实践 . 进程权限控制包含的攻防向量 . 进程高权限安全风险检查技术方案 1. Linux进程权限原理 我们知道,Li ...
- supervisor :a running process with pid = 0,程序PID为0
Neo君作为一只小白,今天踩到了一个supervisor的坑. 如上图所示,出现这种情况后,想把这个进程停止.或者重启,甚至stop all它还是这个样子,如下图(马赛克部分为进程名称): 一:背景 ...
- Linux Running State Process ".so"、"code" Injection Technology
catalog . 引言 . 基于so文件劫持进行代码注入 . 基于函数符号表(PLT)中库函数入口地址的修改进行代码注入 . PLT redirection through shared objec ...
- Process Kill Technology && Process Protection Against In Linux
目录 . 引言 . Kill Process By Kill Command && SIGNAL . Kill Process By Resource Limits . Kill Pr ...
- Tracing Memory access of an oracle process : Intel PinTools
https://mahmoudhatem.wordpress.com/2016/11/07/tracing-memory-access-of-an-oracle-process-intel-pinto ...
随机推荐
- SpringCloud-Hystrix原理
Hystrix官网的原理介绍以及使用介绍非常详细,非常建议看一遍,地址见参考文档部分. 一 Hystrix原理 1 Hystrix能做什么 通过hystrix可以解决雪崩效应问题,它提供了资源隔离.降 ...
- .Net Core 导出Html到PDF
前言 最近由于项目的需求问题,涉及到了在.Net Core中导出PDF的一个问题,最后选择方式是后端拼接到Html页面然后再通过Html导出到PDF.中间也尝试了许多的NuGet包.但是并不如意,可用 ...
- 记录我的 python 学习历程-Day13 匿名函数、内置函数 II、闭包
一.匿名函数 以后面试或者工作中经常用匿名函数 lambda,也叫一句话函数. 课上练习: # 正常函数: def func(a, b): return a + b print(func(4, 6)) ...
- 求二叉树的深度,从根节点到叶子节点的最大值,以及最大路径(python代码实现)
首先定义一个节点类,包含三个成员变量,分别是节点值,左指针,右指针,如下代码所示: class Node(object): def __init__(self, value): self.value ...
- Microsoft Visual Studio提示正忙如何解决
打开项目的时候会一直提示正在加载,然后卡死,点击VS界面即出现下如图- 如图: 解决方法: 1.打开项目 找到一个叫vs的文件夹, 2.找到一个后缀是.suo的文件 把它删掉 3.关闭VS进程 重新打 ...
- 使用vscode运行python出现中文乱码的解决方法
前提:自己安装了code runner的插件 快捷键Ctrl+Shift+P,打开设置Open Settings (JSON):
- Activiti结束事件(End Event)
Activiti结束事件(End Event) 作者:Jesai -2017.08.03T01:03 曾经,黑夜多么漫长,八月雨扰眠,缘何? 声明:版权所有,如需引用请注明出处,如发现抄袭,必追究法律 ...
- java 赋值运算
注意:在赋值运算的时候,会自动发生数据类型转变 例子 public class test{ public static void main(String[] args){ byte num = 5; ...
- SpringBoot使用thymeleaf模板时报错:Template might not exist or might not be accessible by any of the configured Template Resolvers
错误如下:Template might not exist or might not be accessible by any of the configured Template Resolvers ...
- 玩转Django2.0---Django笔记建站基础十三(第三方功能应用)
第13章 第三方功能应用 在前面的章节中,我们主要讲述Django框架的内置功能以及使用方法,而本章主要讲述Django的第三方功能应用以及使用方法.通过本章的学习,读者能够在网站开发过程中快速开发网 ...