结束掉进程,sysdba才能连接上

# 两种写法都可以,结束掉前10个进程 [root@oramod ~]# ps -ef|grep LOCAL=NO|grep -v grep|awk '{print $2}'|head|xargs kill -9 [root@oramod ~]# ps -ef|grep LOCAL=NO|grep -v grep|cut -c 9-15|head|xargs kill -9

排查连接情况

SQL> select event,program,count(*) from v$session group by event,program order by 3;

看连接情况

select username,count(username) from v$session where username is not null group by username;

创建触发器,看IP

create or replace trigger on_logon_trigger after logon on database begin dbms_application_info.set_client_info(sys_context('userenv', 'ip_address')); end; /

显示客户端信息

select sid,serial#,username,program,machine,client_info from v$session where username is not null order by username,program,machine;