Reorganizing index datafiles with tables in partition (merged) [message #668960] |
Mon, 26 March 2018 01:15 |
reym21
Messages: 241 Registered: February 2010 Location: Philippines
|
Senior Member |
|
|
Gurus,
As we're expanding/adding disks on the database server, we will be relocating most of our index datafiles to another location/mountpoint. We will implement this without shutting down the database.
The tables associated with said indexes are partitioned.
Do this implementation have any critical impact on the database?
Thank you very much.
[Updated on: Tue, 27 March 2018 00:59] by Moderator Report message to a moderator
|
|
|
Re: Reorganizing index datafiles with tables in partition [message #668961 is a reply to message #668960] |
Mon, 26 March 2018 01:19 |
John Watson
Messages: 8963 Registered: January 2010 Location: Global Village
|
Senior Member |
|
|
As you are on release 10, you will not be able to relocate datafiles without taking them offline. Yes, you can do this without shutting down the database but large parts (probably all) of your application will not be available while doing this.
Partitioning has minimal impact.
|
|
|
|
Relocating/moving data files without a shutdown (merged) [message #668973 is a reply to message #668960] |
Mon, 26 March 2018 20:57 |
reym21
Messages: 241 Registered: February 2010 Location: Philippines
|
Senior Member |
|
|
Sirs,
Good day!
As we're preparing to reorganize index datafiles (due to diskspace issue),
below are our planned steps without shutting down the Prod database:
1. check datafiles current paths and the new path (esp. permissions);
2. make the tablespace OFFLINE;
3. copy (via OS) the datafiles from source to destination;
4. execute the ALTER DATABASE RENAME FILE;
5. bring the tablespace ONLINE;
6. backup the controlfile;
7. execute the ALTER DATABASE OFFLINE DROP;
8. delete (via OS) the old datafiles;
9. implement index rebuild.
Just to validate if there are steps in here that would cause something
troublesome for the database.
Thank you in advance.
[Updated on: Tue, 27 March 2018 01:00] by Moderator Report message to a moderator
|
|
|
|
|
|
|
|
|
|
Re: Reorganizing index datafiles with tables in partition (merged) [message #669002 is a reply to message #668992] |
Wed, 28 March 2018 08:34 |
|
JPBoileau
Messages: 88 Registered: September 2017
|
Member |
|
|
The mountpoint is not as relevant here as the tablespaces you are using (and of course where it is located).
e.g.:
1) If you have a 10GB table in tablespace A on mountpoint 1, along with 5GB of indexes in tablespace A on mountpoint 1, if you rebuild the indexes in tablespace B on mountpoint 2, you will have freed 5GB in tablespace A, but not on the mountpoint 1.
2) If you have a 10GB table in tablespace A on mountpoint 1, along with 5GB of indexes in tablespace Z on mountpoint 1, if you rebuild the indexes in tablespace B on mountpoint 2, you can then drop tablespace Z (which should be empty after rebuilding the indexes) including the tablespace datafiles, and will have freed 5 GB on mountpoint 1.
If your situation is #1 above, you would need to resize the tablespace if possible, or create a new tablespace with a smaller size, and move the table into the new tablespace.
JP
|
|
|