Moving datafiles about & relocating the Arch destination
I've been asked to clean up one of our databases.
It archives the redo to one of the drives on the same server (Its Win NT4 and Ora8.1.5) - which I've never liked. I'm going to have it archive to a network location on a separate server.
I also have to switch/move some of the datafiles around.
So -
Datafiles: I believe its as simple as
(Make backup)
(a) close down Db and restart restricted.
(b) Make OS copy of file to new location.
(c) Rename file-in-orig-location to file-in-new-location (ALTER DATABASE rename 'C:\direc\datafile1.dbf' to 'F:\direc\datafile1.dbf')
(d) open db.
(e) Delete old version using OS command.
Redo logs :
(Make backup)
(a) Close down db.
(b) Move existing Arch redo logs to new location.
(c) Edit init.ora to write redo logs to new location
(d) Start db.
(e) Switch logfile several times to test change.
Is it as simple as I believe? Any pitfalls to watch out for?
Any misconceptions on my part?
Re: Moving datafiles about & relocating the Arch destination
Quote:
Originally posted by JMac
(a) close down Db and restart restricted.
(b) Make OS copy of file to new location.
(c) Rename file-in-orig-location to file-in-new-location (ALTER DATABASE rename 'C:\direc\datafile1.dbf' to 'F:\direc\datafile1.dbf')
(d) open db.
(e) Delete old version using OS command.
a) should be restart, mounting the db but leaving it closed.
After (e) you have to backup the database as you have made a structural change.
HTH.
Re: Moving datafiles about & relocating the Arch destination
Quote:
Originally posted by JMac
Redo logs :
(Make backup)
(a) Close down db.
(b) Move existing Arch redo logs to new location.
(c) Edit init.ora to write redo logs to new location
(d) Start db.
(e) Switch logfile several times to test change.
Nah, too complicated...
1. with the database up, stop archiving:
alter system archive log stop;
http://download-west.oracle.com/docs...19.htm#2053642
2. Start archiving to a new location:
alter system archive log start to '/u02/newdest/';
http://download-west.oracle.com/docs...19.htm#2053642
3. change your init.ora parameter to reflect the change
If you are using RMAN, your method will cause RMAN to fail the next time you run it because he is looking for the archived redo logs in a certain directory and you have moved them.