How to set the number of concurrent connections in Oracle

Source: Internet
Author: User

The following articles will show you how to set the number of concurrent connections in Oracle, under what circumstances cannot be set, and related query solutions. The following is an introduction to the specific content of the article. I hope you will gain some benefits,

OERR: ORA-12519 TNS: no appropriate service handler found

Client Connection intermittent failure, error ORA-12519

 
 
  1. Cause: the listener could not find any available service handlers that are  
  2. appropriate for the client connection.  
  3. Action: run "lsnrctl services" to ensure that the instance(s) have registered  
  4. with the listener, and are accepting connections.   

Check the lsnrctl service. The instance has been registered,

When the status shows ready, you can connect.

 
 
  1. When the listener believes the current number of connections has reached maximum load,  
  2. it may set the state of the service handler for an instance to "blocked" and begin refusing  
  3. incoming client connections with either of the following errors: ora-12519 or ora-12516  

Using dynamic service registration, PMON obtains the current connection status through SERVICE_UPDATE, but SERVICE_UPDATE has a time interval,

Therefore, the number of concurrent Oracle connections displayed by listener may be different from the actual number of connections currently.

Query solution:

Check whether the number of existing processes in the database has reached the processes parameter size.

1. select count (*) from v $ process; obtain the current number of processes in the database.

2. select value from v $ parameter where name = 'processs'; obtain the maximum number of processes.

3. If the upper limit is reached, modify the processes size in initSID. ora.

4. Restart the database to the nomount state, execute create spfile from pfile, and start up open.

Queries the maximum number of concurrent queries since the database is started.

Modify the maximum number of concurrent Oracle connections:

 
 
  1. alter system set processes = 300 scope = spfile; 

Restart the database:

 
 
  1. shutdown immediate;  
  2. startup;  

View which users are using data

 
 
  1. SELECT osuser, a.username,cpu_time/executions/1000000||'s', sql_fulltext,machine  
  2. from v$session a, v$sqlarea b  
  3. where a.sql_address =b.address order by cpu_time/executions desc;  

2

Sometimes we need to adjust the maximum number of connections of the oracle database, and the number of connections is adjusted in the init. ora file in the dbs directory of the oacle.

The number of concurrent Oracle connections (sessions) is related to the number of processes in the parameter file. Their relationships are as follows:

 
 
  1. sessions=(1.1*process+5) 

However, when we increase the number of processes, the database often cannot be started. This is because a unix system parameter is missing: semmns is the core parameter, which is the semaphore parameter of the unix system. Each process occupies a semaphore. After the semmns is adjusted, You need to restart the unix operating system to make the parameter take effect. However, its size is subject to hardware memory or oracle sga. Range: 200

 

Related Article

Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.