oracle 最大连接数的报错
<DIV>1.设置最大连接数</DIV><DIV>SQL>alter system set processes=25 scope=spfile;</DIV>
<DIV>SQL> show parameter processes</DIV>
<DIV>NAME TYPE VALUE<BR>------------------------------------ ----------- ------------------------------<BR>aq_tm_processes integer 0<BR>db_writer_processes integer 1<BR>gcs_server_processes integer 0<BR>job_queue_processes integer 10<BR>log_archive_max_processes integer 2<BR>processes integer 25</DIV>
<DIV>$ ps -ef|grep ora_<BR>oracle 4678 1 0 11:02 ? 00:00:00 ora_pmon_Peng<BR>oracle 4680 1 0 11:02 ? 00:00:00 ora_psp0_Peng<BR>oracle 4682 1 0 11:02 ? 00:00:00 ora_mman_Peng<BR>oracle 4684 1 0 11:02 ? 00:00:00 ora_dbw0_Peng<BR>oracle 4686 1 0 11:02 ? 00:00:00 ora_lgwr_Peng<BR>oracle 4688 1 0 11:02 ? 00:00:00 ora_ckpt_Peng<BR>oracle 4690 1 0 11:02 ? 00:00:00 ora_smon_Peng<BR>oracle 4692 1 0 11:02 ? 00:00:00 ora_reco_Peng<BR>oracle 4694 1 0 11:02 ? 00:00:00 ora_cjq0_Peng<BR>oracle 4696 1 0 11:02 ? 00:00:00 ora_mmon_Peng<BR>oracle 4698 1 0 11:02 ? 00:00:00 ora_mmnl_Peng<BR>oracle 4700 1 0 11:02 ? 00:00:00 ora_d000_Peng<BR>oracle 4702 1 0 11:02 ? 00:00:00 ora_s000_Peng<BR>oracle 4719 1 0 11:02 ? 00:00:00 ora_arc0_Peng<BR>oracle 4721 1 0 11:02 ? 00:00:00 ora_arc1_Peng<BR>oracle 4725 1 0 11:02 ? 00:00:00 ora_qmnc_Peng<BR>oracle 4731 1 0 11:02 ? 00:00:00 ora_q000_Peng<BR>oracle 5050 1 0 11:03 ? 00:00:00 ora_q002_Peng<BR>oracle 5501 5372 0 11:13 pts/9 00:00:00 grep ora_<BR>$ ps -ef|grep ora_|grep -v grep|wc<BR> 19 152 1178<BR>后台进程的连接数为19,processes的值一定要大于后台进程的连接数,不然启动不了数据库。</DIV>
<DIV>
<DIV>SQL> startup<BR>ORA-03113: end-of-file on communication channel</DIV>
<DIV>$ ps -ef|grep oraclePeng<BR>oracle 4717 4605 0 11:02 ? 00:00:01 oraclePeng (DESCRIPTION=(LOCAL=YES)(ADDRESS=(PROTOCOL=beq)))<BR>oracle 5096 5095 0 11:04 ? 00:00:00 oraclePeng (DESCRIPTION=(LOCAL=YES)(ADDRESS=(PROTOCOL=beq)))<BR>oracle 5098 5097 0 11:04 ? 00:00:00 oraclePeng (DESCRIPTION=(LOCAL=YES)(ADDRESS=(PROTOCOL=beq)))<BR>oracle 5124 5122 0 11:04 ? 00:00:00 oraclePeng (DESCRIPTION=(LOCAL=YES)(ADDRESS=(PROTOCOL=beq)))<BR>oracle 5435 5080 0 11:11 ? 00:00:00 oraclePeng (DESCRIPTION=(LOCAL=YES)(ADDRESS=(PROTOCOL=beq)))<BR>oracle 5562 5561 0 11:15 ? 00:00:00 oraclePeng (DESCRIPTION=(LOCAL=YES)(ADDRESS=(PROTOCOL=beq)))<BR>oracle 6368 5372 0 11:41 pts/9 00:00:00 grep oraclePeng<BR>$ ps -ef|grep oraclePeng|grep -v grep|wc<BR> 6 54 654<BR>此时刚好25个连接。</DIV>
<DIV>如果再次连接,则报错:</DIV>
<DIV>$ sqlplus scott/tiger</DIV>
<DIV>SQL*Plus: Release 10.2.0.1.0 - Production on Fri Sep 23 11:42:46 2011</DIV>
<DIV>Copyright (c) 1982, 2005, Oracle. All rights reserved.</DIV>
<DIV>ERROR:<BR>ORA-00020: maximum number of processes (%s) exceeded</DIV>
<DIV><BR>Enter user-name:</DIV>
<DIV>查看警告日志:</DIV>
<DIV># tail alert_Peng.log <BR>Fri Sep 23 11:40:44 2011<BR>ksvcreate: Process(q002) creation failed<BR>Fri Sep 23 11:41:35 2011<BR>Process q002 died, see its trace file<BR>Fri Sep 23 11:41:35 2011<BR>ksvcreate: Process(q002) creation failed<BR>Fri Sep 23 11:43:18 2011<BR>Process q002 died, see its trace file<BR>Fri Sep 23 11:43:18 2011<BR>ksvcreate: Process(q002) creation failed</DIV>
<DIV>通过查看警告日志,知道oracle此时有些非核心进程要创建,但由于processes的限制,所以会提示</DIV>
<DIV>Process(q002) creation failed。</DIV>
<DIV>此时我们需要将连接数增大:</DIV>
<DIV>alter system set processes = 300 scope = spfile; </DIV>
<DIV>在重新启动数据库。<BR></DIV></DIV>
页:
[1]