[oracle@urp65 dbs]$ cp spfilejwdb.ora spfilejwdb.ora.bak
cd /u01/app/oracle/oracle/oraInventory/db_1/admin/jwdb/pfile/
cp init.ora.2132009144930 init.ora.2132009144930.bak
------------单独创建spfile文件
SQL> create spfile from pfile='/u01/app/oracle/oracle/oraInventory/db_1/admin/jwdb/pfile/init.ora.2132009144930'
2 /
create spfile from pfile='/u01/app/oracle/oracle/oraInventory/db_1/admin/jwdb/pfile/init.ora.2132009144930'
*
μú 1 DD3 ′í ó:
ORA-32002: T·¨′′ ¨ò óéêμàyê1ó μ SPFILE
需要关闭数据库在nmount下建立pfile否则如果在使用的话、失败
SQL> shutdown immediate;
êy Y aò -1 ± £
ò -D êy Y a £
ORACLE ày3ìò -1 ± £
SQL> create spfile from pfile='/u01/app/oracle/oracle/oraInventory/db_1/admin/jwdb/pfile/init.ora.2132009144930'
2 /
SQL> startup
ORACLE ày3ìò - ˉ £
Total System Global Area 436207616 bytes
Fixed Size 1219856 bytes
Variable Size 125829872 bytes
Database Buffers 306184192 bytes
Redo Buffers 2973696 bytes
启动发现内存值变化了spfilejwdb.ora与init.ora2132009144930保持一致的
*.sga_target=434288000;
但是此时没有sga_max_size在sfilejwdb.ora中出现、应为在init.ora2132009144930没有指定
[oracle@urp65 pfile]$ pwd
/u01/app/oracle/oracle/oraInventory/db_1/admin/jwdb/pfile
[oracle@urp65 pfile]$ vi init.ora.2132009144930
增
sga_max_size=524288000#internally adjusted
---关闭
SQL> shutdown immediate;
êy Y aò -1 ± £
ò -D êy Y a £
ORACLE ày3ìò -1 ± £
SQL> create spfile from pfile='/u01/app/oracle/oracle/oraInventory/db_1/admin/jwdb/pfile/init.ora.2132009144930'
2 /
SQL> startup
ORACLE ày3ìò - ˉ £
Total System Global Area 524288000 bytes
Fixed Size 1220384 bytes
Variable Size 213909728 bytes
Database Buffers 306184192 bytes
Redo Buffers 2973696 bytes
êy Y a×° íê± £
êy Y aò -′ò a £
启动发现值发生了变化、最大内存变化为524288000 bytes 与sga_max_size=524288000#internally adjusted
增加保持一致了
因此直接修改 init.ora.2132009144930---->增加sga_max_size=524288000#internally adjusted、*.sga_target=434288000;===》 create spfile 生成
达到同时修改的功效、最有效
-----直接修改spfilejwdb.ora值
*.sga_max_size=504288000#internally adjusted
*.sga_target=404288000
SQL> shutdown immediate
êy Y aò -1 ± £
ò -D êy Y a £
ORACLE ày3ìò -1 ± £
SQL> startup
ORA-01078: failure in processing system parameters
LRM-00109: '/u01/app/oracle/oracle/oraInventory/db_1/dbs/initjwdb.ora'
报告错误说明、无法直接的修改spfilejwdb.ora文件而是需要通过修改init.ora.2132009144930 实现
解决办法:
SQL> create spfile from pfile='/u01/app/oracle/oracle/oraInventory/db_1/admin/jwdb/pfile/init.ora.2132009144930'
2 /
SQL> startup
ORACLE
Total System Global Area 524288000 bytes
Fixed Size 1220384 bytes
Variable Size 213909728 bytes
Database Buffers 306184192 bytes
Redo Buffers 2973696 bytes
设置成功!!!!