shutdown immedate;
关闭系统
复制control file,例如从D:\oracle\oradata\test\中,将CONTROL01.CTL
copy一份为CONTROL02.CTL;
startup nomount;
可以看出必须在nomount的状态下修改spfile
- SQL> alter system set control_files="D:\ORACLE\ORADATA\TEST\CONTROL01.CTL", "D:
- ORACLE\FLASH_RECOVERY_AREA\TEST\CONTROL02.CTL","D:\ORACLE\ORADATA\TEST\CONTROL0
- .CTL" scope=spfile;
- System altered.
- SQL> show parameter control
- NAME TYPE
- ------------------------------------ ----------------------
- VALUE
- ------------------------------
- control_file_record_keep_time integer
- 7
- control_files string
- D:\ORACLE\ORADATA\TEST\CONTROL
- 01.CTL, D:\ORACLE\FLASH_RECOVE
- RY_AREA\TEST\CONTROL02.CTL
- control_management_pack_access string
- DIAGNOSTIC+TUNING
- SQL> shutdown immediate;
- ORA-01507: ??????
- ORACLE instance shut down.
- SQL> startup;
- ORACLE instance started.
- Total System Global Area 1933430784 bytes
- Fixed Size 1378680 bytes
- Variable Size 452986504 bytes
- Database Buffers 1468006400 bytes
- Redo Buffers 11059200 bytes
- Database mounted.
- Database opened.
- SQL> show parameter control_file;
- NAME TYPE VALUE
- ------------------------------------ ----------- ------------------------------
- control_file_record_keep_time integer 7
- control_files string D:\ORACLE\ORADATA\TEST\CONTROL
- 01.CTL, D:\ORACLE\FLASH_RECOVE
- RY_AREA\TEST\CONTROL02.CTL, D:
- \ORACLE\ORADATA\TEST\CONTROL02
- .CTL