Oracle control file log file data file migration

Source: Internet
Author: User

1. View tablespace correspondence D:CD D:\app\administrator\product\11.2.0\dbhome_1\BINsqlplus sys/[email protected] as Sysdbaselect * FROM V$TABLESPACE; 2. Close the database shutdown immediate; 3. Copy the data file to the new location  4. Start the database to mount state startup Mount;5. Rename data file Alter DATABASE rename file ' H:\oradata\spectra\RISDAT01. DBF ' to ' L:\oradata\spectra\RISDAT01. DBF '; Alter DATABASE rename file ' H:\oradata\spectra\RISDAT02. DBF ' to ' L:\oradata\spectra\RISDAT02. DBF '; Alter DATABASE rename file ' H:\oradata\spectra\SPDAT01. DBF ' to ' L:\oradata\spectra\SPDAT01. DBF '; Alter DATABASE rename file ' H:\oradata\spectra\SPDAT02. DBF ' to ' L:\oradata\spectra\SPDAT02. DBF '; Alter DATABASE rename file ' H:\oradata\spectra\SPIDX01. DBF ' to ' L:\oradata\spectra\SPIDX01. DBF '; Alter DATABASE rename file ' H:\oradata\spectra\SPIDX02. DBF ' to ' L:\oradata\spectra\SPIDX02. DBF '; Alter DATABASE rename file ' H:\oradata\spectra\SYSAUX01. DBF ' to ' L:\oradata\spectra\SYSAUX01. DBF '; Alter DATABASE rename file ' H:\oradata\spectra\SYSTEM01. DBF ' to ' L:\oradata\spectra\SYSTEM01. DBF '; Alter DATABASE rename file ' H:\oradata\spectra\TEMP01. DBF ' to ' L:\oradata\spectra\TEMP01. DBF '; Alter DATABASE rename file ' H:\oradata\spectra\UNDOTBS01. DBF ' to ' L:\oradata\spectra\UNDOTBS01. DBF '; Alter DATABASE rename file ' H:\oradata\spectra\USERS01. DBF ' to ' L:\oradata\spectra\USERS01. DBF ';   5. Rename the log file alter DATABASE rename file ' H:\oradata\spectra\REDO01. LOG ' to ' L:\oradata\spectra\REDO01. LOG '; Alter DATABASE rename file ' H:\oradata\spectra\REDO02. LOG ' to ' L:\oradata\spectra\REDO02. LOG '; Alter DATABASE rename file ' H:\oradata\spectra\REDO03. LOG ' to ' L:\oradata\spectra\REDO03. LOG '; 6. Open the database and view the status ALTER DATABASE Open;shutdown Immediate;startup;select * from V$logfile; or select a.group#, A.status, b.member,a.bytes/1024/1024 Sizem from V$log A, V$logfile b where a.group#=b.group#;alter system switch logfile;//switch log &nbs p;===========================================================7. View the control file select name from V$controlfile; 8. Recovery control file shutdown Immediate;startup nomount;quitrmant target/reStore Controlfile to ' L:\oradata\spectra\CONTROL01. CTL ' from ' H:\oradata\spectra\CONTROL01. CTL '; restore Controlfile to ' L:\oradata\spectra\CONTROL02. CTL ' from ' H:\oradata\spectra\CONTROL02. CTL '; restore Controlfile to ' L:\oradata\spectra\CONTROL03. CTL ' from ' H:\oradata\spectra\CONTROL03. CTL ';  quit//Exit Rman 9: Modify control File location Sqlplus/as sysdbaalter system set control_files= ' L:\oradata\spectra\ CONTROL01. CTL ', ' L:\oradata\spectra\CONTROL02. CTL ', ' L:\oradata\spectra\CONTROL03. CTL '   scope=spfile; 10. Startup database Startup Mount Force;select * from v$controlfile;alter database Open;select * from S Pectra.version;  11. View information for changes above the database select name from V$controlfile;select * from V$logfile;select * from v$ tablespace; 

Oracle Control file log file data file migration

Related Article

Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.