Oracle中如何保证用oracle账号户只有一个session登录
SQL> create profile one_session limit sessions_per_user 1;
SQL> create user test identified by test;
User created. www.2cto.com
SQL> grant connect,resource to test;
Grant succeeded.
SQL> alter user test profile one_session;
SQL> alter system set resource_limit=true;
sqlplus test/test
host sqlplus test/test
ERROR:
ORA-02391: exceeded simultaneous SESSIONS_PER_USER limit
但有个条件是如果是RAC, 则在其他instance还可以登录