how to disable simultaneous connections by one user on oracle

孤街醉人 提交于 2019-12-11 04:46:58

问题


i am using oracle 12, and hoping to find how can i enable or disable simultaneous connections for my database for each user. i found codes regarding dispatchers and other ones including the following codes:

SHARED_SERVER_SESSIONS 
MAX_DISPATCHERS
CONNECTIONS
SESSIONS
POOL

in addition to other codes that didn't find suitable for my case .Can anyone help ?


回答1:


Create a new profile as

CREATE PROFILE <profile_name> LIMIT 
   SESSIONS_PER_USER          1
   CPU_PER_SESSION            UNLIMITED 
   CPU_PER_CALL               <some_value>
   CONNECT_TIME               <some_value>
   LOGICAL_READS_PER_SESSION  DEFAULT 
   LOGICAL_READS_PER_CALL     <some_value>
   PRIVATE_SGA                <some_value>
   COMPOSITE_LIMIT            <some_value>; 

note: choose other parameters as per requirement, you can get current profile parameter values from dba_profile view and use them in the above query. Before that get the profile name of the user using below query

SELECT profile FROM dba_users WHERE username = <user_name>;

Then ALTER USER

ALTER USER <user_name> PROFILE <profile_name>;



来源:https://stackoverflow.com/questions/21026677/how-to-disable-simultaneous-connections-by-one-user-on-oracle

易学教程内所有资源均来自网络或用户发布的内容,如有违反法律规定的内容欢迎反馈
该文章没有解决你所遇到的问题?点击提问,说说你的问题,让更多的人一起探讨吧!