操作系统是CENTOS5.2 
数据库是oracle 10 R2
现在的问题是:
如果用户多连接oracle就会慢下来
processes:300  够用
使用select count(*) from v$session;没有超过过60
SGA:1.5G
以前用的是WENDOWS,设置着2个就能满足需求了
现在改用LINUX,客户端连接数据库的过程就慢了下了
数据库性能没问题!!!

解决方案 »

  1.   


    既然是数据库性能没有问题,那么就是网络的问题了,或者是你的linux系统的问题了吧!你用个工具 测试下从客户端发个包到数据库服务器需要多长时间啊?
      

  2.   

    我也怀疑可能是linux的什么地方参数没有设置好
      

  3.   

    在linux上装oracle,有些系统参数的配置文件需要配置好才行,粗略找了一下,如etc/sysctl.conf和etc/security/limits.conf 
      

  4.   

    etc/sysctl.confkernel.shmall = 2097152
    kernel.shmmax = 2147483648
    kernel.shmmni = 4096
    kernel.sem = 250 32000 500 128
    fs.file-max = 65536
    net.ipv4.ip_local_port_range = 1024 65000
    net.core.rmem_default = 1048576
    net.core.rmem_max = 1048576
    net.core.wmem_default = 262144
    net.core.wmem_max = 26214etc/security/limits.conf oracle soft nproc 2047
    oracle hard nproc 16384
    oracle soft nofile 1024
    oracle hard nofile 65536
      

  5.   

    etc/sysctl.conf中,kernel.shmmax 应该是你物理内存的一半吧,其他的想差不多了我的etc/security/limits.conf 是:
    oracle  soft    nofile  65536
    oracle  hard    nofile  65536
    oracle  soft    nproc   16384
    oracle  hard    nproc   16384
      

  6.   

    oracle  soft    nproc  16384 
    oracle  hard    nproc  16384
    这是什么
    我的物理内存是2G
      

  7.   

    Nofile可打开的文件的最大数
    Nproc单个用户可用的最大执行绪量oracle  hard  nofile  65535    对oracle用户文件数量限制是65535个
    oracle  hard  nproc   16384    对oracle用户的process最大16384个2G的物理内存kernel.shmmax应该是2*1024*1024*1024/2我不能肯定这些是你oracle出问题的原因
      

  8.   

    pga有多大??SQL> show parameter pga 根据你的SGA,建议这个200M左右。
      

  9.   

    PGA192M  
    似乎跟PGA没多大关系
      

  10.   

    我现在开了20多个客户端连接
    正常
    等下测试使用PHP连接如何
      

  11.   

    与数据库无关了
    就是PHP,当PHP连接数过多是就出问题
    ASP连接也是没问题的