重庆分公司,新征程启航

为企业提供网站建设、域名注册、服务器等服务

查看oracle数据库job及会话信息

查看所有job
select from dba_jobs;
查看正在运行的job
select
from dba_jobs_running;
select job,log_user,priv_user,schema_user,BROKEN from dba_jobs where job=545;
查看数据库建立的回话情况
select sid,serial#,username,program,machine,status
from v$session;
查看对应sid的sql_id
select * from v$session where sid=2272 or sid=327;
知道sql_id后查看sql语句
select SQL_TEXT from v$sql where sql_id='3f18ygbqg41mw';
给MESPRD赋权
grant execute on DBMS_WORKLOAD_REPOSITORY to MESPRD;
kill会话
alter system kill session 'sid,serial#';
alter system kill session '327,8133';
查看进程的spid
select spid, program from v$process
where program!= 'PSEUDO'
and addr not in (select paddr from v$session)
and addr not in (select paddr from v$bgprocess)
and addr not in (select paddr from v$shared_server);
!ps -ef|grep spid|grep -v grep;
查看进程的spid
SELECT s.username,s.status,
x.ADDR,x.KSLLAPSC,x.KSLLAPSN,x.KSLLASPO,x.KSLLID1R,x.KSLLRTYP,
decode(bitand (x.ksuprflg,2),0,null,1)
FROM x$ksupr x,v$session s
WHERE s.paddr(+)=x.addr
and bitand(ksspaflg,1)!=0;
查看进程的spid
select spid,program from v$process where pid in(327,2272);

成都创新互联主要从事网站制作、成都网站设计、网页设计、企业做网站、公司建网站等业务。立足成都服务平川,十多年网站建设经验,价格优惠、服务专业,欢迎来电咨询建站服务:028-86922220


文章题目:查看oracle数据库job及会话信息
分享地址:http://cqcxhl.com/article/jdhpdg.html

其他资讯

在线咨询
服务热线
服务热线:028-86922220
TOP