今天修改系统连接数,发现如下:
--查看当前使用的是spfileSQL> SHOW PARAMETER PFILE;NAME TYPE VALUE------------------------------------ ----------- ------------------------------spfile string E:ORACLEPRODUCT10.2.0DB_1DATABASESPFILEHS01.ORA--查看当前processes=450,sessions=500SQL> SHOW PARAMETER PROCESSES;NAME TYPE VALUE------------------------------------ ----------- ------------------------------aq_tm_processes integer 0db_writer_processes integer 3gcs_server_processes integer 0job_queue_processes integer 10log_archive_max_processes integer 2processes integer 450SQL> SHOW PARAMETER SESSION;NAME TYPE VALUE------------------------------------ ----------- ------------------------------java_max_sessionspace_size integer 0java_soft_sessionspace_limit integer 0license_max_sessions integer 0license_sessions_warning integer 0logmnr_max_persistent_sessions integer 1session_cached_cursors integer 20session_max_open_files integer 10sessions integer 500shared_server_sessions integerSQL> CONN / AS SYSDBAConnected.--创建pfileSQL> CREATE PFILE FROM SPFILE;File created.--查看pfile中processes=450;--修改processes=610SQL> ALTER SYSTEM SET PROCESSES=610 SCOPE=SPFILE;System altered.--创建pfileSQL> CREATE PFILE FROM SPFILE;File created.--查看pfile中processes=450;session=390(修改spfile中的参数后,用spfile创建pfile,pfile并不会体现出来修改后的参数值。)--重新启动数据库SQL> SHUTDOWN IMMEDIATE;Database closed.Database dismounted.ORACLE instance shut down.SQL> STARTUP NOMOUNTORACLE instance started.Total System Global Area 2550136832 bytesFixed Size 2153872 bytesVariable Size 446505584 bytesDatabase Buffers 2097152000 bytesRedo Buffers 4325376 bytesSQL> ALTER DATABASE MOUNT;Database altered.SQL> ALTER DATABASE OPEN;Database altered.--查看当前processes=610,sessions=676SQL> SHOW PARAMETER PROCESS;NAME TYPE VALUE------------------------------------ ----------- ------------------------------aq_tm_processes integer 0db_writer_processes integer 3gcs_server_processes integer 0job_queue_processes integer 10log_archive_max_processes integer 2processes integer 610SQL> SHOW PARAMETER SESSION;NAME TYPE VALUE------------------------------------ ----------- ------------------------------java_max_sessionspace_size integer 0java_soft_sessionspace_limit integer 0license_max_sessions integer 0license_sessions_warning integer 0logmnr_max_persistent_sessions integer 1session_cached_cursors integer 20session_max_open_files integer 10sessions integer 676shared_server_sessions integerSQL> SHOW PARAMETER PFILENAME TYPE VALUE------------------------------------ ----------- ------------------------------spfile string E:ORACLEPRODUCT10.2.0DB_1DATABASESPFILEHS01.ORASQL> CREATE PFILE FROM SPFILE;File created.--查看pfile中processes=610;session=390(修改processes,系统会同时修改session,但创建的pfile中,显示的session并不是当前的值,还是原来的值。)