Simpler Navigation for Servers and Operating Systems
Completed: a much simpler Servers and Operating Systems section of the Community. We combined many of the older boards, so you won't have to click through so many levels to get at the information you need. Check the consolidated boards here as many sub-forums are now single boards.
General
cancel
Showing results for 
Search instead for 
Did you mean: 

Will this create problems when running script ?

SOLVED
Go to solution
Deanna Tran
Frequent Advisor

Will this create problems when running script ?

Hi all,
I have installed oracle9i on HP-UX11i, however, I installed the oracle datafile and oracle software in the root vg but on different filesystem? As I read through Andreas' note, it is best for me to have these on the storage disk. My question is will this cause any problem when running the databasescript. In addition, the other fileystem such as rollack tmp index redo etc...I use the storage disk to create them...

Could I create the tablespace user datafile and
create the tablespace index on the same filesystem?
for example :
create tablespace user_01 datafile
'/u03/oradata/sales/sales_user01.dbf size etc...
create tablespace sales_index datafile
'/u03/oradata/sales/sales_index.dbf size etc...

Will this configuration slow down or create any problems on the I/O performance

thank you

9 REPLIES
Ceesjan van Hattum
Esteemed Contributor

Re: Will this create problems when running script ?

The general idea:
Ofcourse you can put everything on one single disk or filesystem, but that is not always the best solution.
First rule: use vg00 only for the basic OS logical volumes.
Make the data-disks on a second volume group.
Secondly, Oracle userdata and index can be stored together, but it will not be so good for your performance in case these files become really big.
It is better to have the user-data and the index in seperate filesystems IF the filesystems are indeed on seperated disks..
As long as the files are togehter on one phyiscal (!!) disk, it does not matter at all. Performance is gained by seperating the directories (links can be used) on more parallel accessible disks.

Rgrds,
Ceesjan
harry d brown jr
Honored Contributor
Solution

Re: Will this create problems when running script ?

Deanna,

You can have everything under vg00, but it's not advisable, especially if vg00 is a single disk, and even more especially if you put oracle tables on the same disk as root & swap. Now if vg00 is made up of several disks, and you can seperate the LVOL's onto different disks, placing your oracle on one of those seperate disks, then it's sort of okay. One of the major reasons why you wouldn't want to do this, is when you need to create a recovery tape using make_tape_recovery or make_net_recovery because normally most use the "-A" option which says backup all of VG00, and the larger vg00 gets the longer to create the tape.

live free or die
harry
Live Free or Die
pap
Respected Contributor

Re: Will this create problems when running script ?

HI Deanna,
Yes, You can put anything under vg00.
There will not be any problem as far as database and other softwares are concern. They will operate satisfactorily.
Although it will serve your purpose, it is not a good idea to put any other things in vg00 except root, core os and necessary basic OS filesystems.
This is becase in case if you want to upgrade OS in future, you will have lots of problems.

secondly as Harry said make_recovery will take very long time and if your oracle space is very high , the recovery tape may be short of space and will not be created successfuly. One more thing, if you are using just one disk in root vg then the disk i/o rate will be very high and will result in somewhat poor performance.

Apart form this no problems.

Hope this will help.

-Piyush.

"Winners don't do different things , they do things differently"
Andreas D. Skjervold
Honored Contributor

Re: Will this create problems when running script ?

Hi

As mentioned above, no problem running from vg00 but poor performance etc.

What you'll have to do to resolve this issue is to move the files that contain the database.

First note down the files to move:
select name from v$datafile;
select * from v$logfile;
select * from v$controlfile;

Then start the database in mount. To do this you have to shut it down first:
SQL> shutdown immediate
SQL> startup mount

Then copy the datafiles to a new location on the storage disks using operation system command (cp).

Then alter the datafile and logfile locations in the database:
SQL>alter database rename file '/oldpath/file' to '/newpath/filename';
repeat this step for all the files you moved.

Open the database and check that all files are OK.
(select name from v$datafile;)
(select * from v$logfile;)

Then move the controlfiles:
Shutdown the database
SQL>shutdown immediate

Copy the controlfiles to new location.
Update the init.ora file with the new controlfile location (controlfile=/newpath/filename)

and startup the database.
SQL>startup

The important thing here is to keep control of which files you have and where the are located. If you miss a file or renames incorrectly, you're in trouble. Not deep trouble; but anyway do this on a quiet day...

Andreas
Only by ignoring what everyone think is important, can you be aware of what everyone ignores!
Deanna Tran
Frequent Advisor

Re: Will this create problems when running script ?

Hi Andreas,
I 'm in the process of moving these files, but has this question for you?
After the step of verify all the files are okay you inidicated :
"Then move the controlfiles:
Shutdown the database
SQL>shutdown immediate "

TO move the controlfiles do I use the command mv to move the files? or cp? or uses sql command to move it?

Thank you
Deanna
Deanna Tran
Frequent Advisor

Re: Will this create problems when running script ?

Hi andreas,

Here is the error message that I got whenI tried to alter the database name?
when I do select * from v$logfile;
I got this:
GROUP# STATUS TYPE
---------- ------- -------
MEMBER
--------------------------------------------------------------------------------
3 STALE ONLINE
/u01/product/9.0.1/oradata/sales/redo03.log

2 ONLINE
/u01/product/9.0.1/oradata/sales/redo02.log

1 ONLINE
/u01/product/9.0.1/oradata/sales/redo01.log

** I notice that status on redo03.log is stale?
Is this normal? and what do I need to to do to fix this problem?


alter database rename file '/u01/product/9.0.1/oradata/sales/redo03.log' to '/u0
2/oradata/sales'
*
ERROR at line 1:
ORA-01511: error in renaming log/data files
ORA-01512: error renaming log file /u01/product/9.0.1/oradata/sales/redo03.log
- new file /u02/oradata/sales not found
ORA-27037: unable to obtain file status
Additional information: 4
Andreas D. Skjervold
Honored Contributor

Re: Will this create problems when running script ?

Hi

First, use cp to copy the controlfiles to the new location. (You might use mv as well but I find it more secure to use cp incase something interrupts the moving)

Second; the Stale redolog is of no matter. This will disapear after the next couple of logswitches.

And last; it seems like you have a typo in your syntax:
alter database rename file
'/u01/product/9.0.1/oradata/sales/redo03.log'
to
'/u02/oradata/sales';

should be:
alter database rename file
'/u01/product/9.0.1/oradata/sales/redo03.log'
to
'/u02/oradata/sales/redo03.log';
(Taken that you have copied the redo03 file to this location.)


(Another thing: If wanting to secure things a little bit more, the .log suffix should also be changed, incase a eager junior wants to free up space by erasing log-files....)

Andreas
Only by ignoring what everyone think is important, can you be aware of what everyone ignores!
Deanna Tran
Frequent Advisor

Re: Will this create problems when running script ?

hi andreas,
I am having this error when i am trying to move the control file
this is the command that i use
alterdatabaserenamefile '/u01/product/9.0.1/oradata/sales/control01.ctl'
to '/u02/oradata/sales';
alter database rename file '/u01/product/9.0.1/oradata/sales/control01.ctl'to '/
u02/oradata/sales'
*
ERROR at line 1:
ORA-01511: error in renaming log/data files
ORA-01516: nonexistent log file, datafile or tempfile
'/u01/product/9.0.1/oradata/sales/control01.ctl'
Deanna Tran
Frequent Advisor

Re: Will this create problems when running script ?

In addition, I got this error 2 core errors in this directory, when i startup the database?
can any1 help me to explain what causes this error and where can i be look at?

(root@princess)/u01/product/9.0.1/dbs# ls
core_9256/ initdia2.ora@ oracle
core_9686/ initdw.ora orapwdia2
init.ora lkSALES spfiledia2.ora