|
Re: how to recovery database from tape to test db [message #120334 is a reply to message #120323] |
Thu, 19 May 2005 03:33 |
girish.rohini
Messages: 744 Registered: April 2005 Location: Delhi (India)
|
Senior Member |
|
|
HI
R u planning to test this database on same machine which is hosting the production database?
If No, restore database backup from tape to ur filesystem on test environment, & startup the databse normally using ur backup parameter file.
U may need to rename files present in datbase due to different file architecture in ur test environment.
This will take place at mount stage of database.
Use: Alter datbase rename <filename> to <filename> for this.
If yes, in startup parameter file, change the instance name to a name different from the instance name of ur production database and the n follow the steps as mentoned earlier.
Regds
Girish
|
|
|
|
|
|
|
|
Re: how to recovery database from tape to test db [message #120741 is a reply to message #120735] |
Mon, 23 May 2005 08:36 |
girish.rohini
Messages: 744 Registered: April 2005 Location: Delhi (India)
|
Senior Member |
|
|
HI NK
My Quote:
as oracle doesn't allow running two databases with same name on same setup.
[& NK said]One database per instance... you could have multiple instance runnin with all different databases on a single box.. depends on machine it self!
Girish: True, we can have multiple instances on single machine & each instance can have its own database.
My query is "Can we have same name for those simultaneously running databases, does Oracle really support running multiple databases with same name on a single machine? Actually, when I tried it our, if gave me error. I tried it on Win2k System"
My Quote:
So either u need to change the name of ur database or choose a different set up for testing ur backup fro recovery purpose.
[NK said]Use a different box rite?
Girish: Yes. Use a different machine with, if possible, same configuration as on the production machine.
Regds
Girish
|
|
|
Re: how to recovery database from tape to test db [message #120865 is a reply to message #120323] |
Tue, 24 May 2005 06:12 |
nabeelkhan
Messages: 73 Registered: May 2005 Location: Kuwait
|
Member |
|
|
Quote: | "Can we have same name for those simultaneously running databases, does Oracle really support running multiple databases with same name on a single machine?
|
Yes you can
Quote: | Actually, when I tried it our, if gave me error. I tried it on Win2k System"
|
Cz you cant have Identical Service names on Windoz!
A database is a set of files (data, redo, ctl and so on)
An instance is a set of processes (SMON, PMON, DBWR, etc) and a shared memory segment (SGA).
A database may be mounted and opened by many INSTANCES (Parallel Server) concurrently.
An instance may mount and open ANY database however it may only open a single database at any time.
If you used DBCA on Windows to create additional databases you will notice that it will create a new service called "OracleService<SID>", now if you try to give the same sid as the previous one windoz will fine that in registry and will through an error. On windoz it registers the necessary services that can be used to start an instance when you want.
When you stop the service, the INSTANCE is gone. So, DBCA isn't creating an instance, it creates a database (set of files). The instance is fleeting, do a shutdown and instance is no more.
Each sid in each oracle_home must be unique actually. but it would be a really bad practice to have the same sids in different oracle homes.
On windows, it is probably 100% true that the sid must be unique on a machine due to service name
On unix, everything is possible. The two oracle homes are totally unaware of eachothers existence, totally separate.
Please correct, me if im wrong..
|
|
|
Re: how to recovery database from tape to test db [message #120909 is a reply to message #120865] |
Tue, 24 May 2005 10:55 |
girish.rohini
Messages: 744 Registered: April 2005 Location: Delhi (India)
|
Senior Member |
|
|
HI
The sid i used were different. I used orcl & orcl1 on Win2k.
on unix too u need to have separate SIDs.
On unix, everything is possible. The two oracle homes are totally unaware of eachothers existence, totally separate.
Even on Windows they are separate. U can have n number of homes even on Win2k machine.
Regds
Girish
|
|
|
Re: how to recovery database from tape to test db [message #121091 is a reply to message #120323] |
Thu, 26 May 2005 00:33 |
nabeelkhan
Messages: 73 Registered: May 2005 Location: Kuwait
|
Member |
|
|
okay lets see this:
However.
easy to prove "not correct" on the "sid must be unique". the
ORACLE_HOME+ORACLE_SID must be unique on unix (it is the key to the shared memory segment), but that is it.
facts:
o 9ir1 in /home/ora9ir1
o 9ir2 in /home/ora9ir2
Had an existing database in both. Oracle_sid is ora9ir2 in the oracle 9ir2 install. I want (for whatever reason) two database instances up and running with that sid.
So, I log into the ora9ir1 account.
I export ORACLE_SID=ora9ir2.
I then:
[ora9ir1@xtkyte-pc dbs]$ mv spfileora9ir1.ora spfileora9ir2.ora
[ora9ir1@xtkyte-pc dbs]$ mv orapwora9ir1 orapwora9ir2
[ora9ir1@xtkyte-pc ora9ir1]$ cd $ORACLE_HOME/admin
[ora9ir1@xtkyte-pc admin]$ ln -s ora9ir1/ ora9ir2
(and that is it -- really, nothing more)
Startup both 9ir1 and 9ir2 and lets see what we have:
[tkyte@xtkyte-pc admin]$ su -
Password:
[root@xtkyte-pc root]# ps -auxwwee | grep pmon_ora9ir2
ora9ir1 31262 0.0 0.3 201056 7400 ? S 07:57 0:00 ora_pmon_ora9ir2
HOSTNAME=xtkyte-pc.us.oracle.com SHELL=/bin/bash TERM=xterm HISTSIZE=1000
LD_PRELOAD=/home/ora9ir1/libcwait.so USER=ora9ir1
LD_LIBRARY_PATH=/home/ora9ir1/lib ORACLE_SID=ora9ir2
PATH=/home/tkyte/bin:/home/ora9ir1/bin:/home/tkyte/bin:/home/ora9ir1/bin:/bin:/
usr/bin:/usr/ccs/bin:/usr/ucb::/usr/X11R6/bin:/home/ora9ir1/bin
MAIL=/var/spool/mail/ora9ir1 _=/usr/bin/rlwrap PWD=/home/ora9ir1
INPUTRC=/etc/inputrc LANG=en_US.UTF-8 SQLPATH=/home/tkyte/src/sqlstuff
HOME=/home/ora9ir1 SHLVL=2 LOGNAME=ora9ir1
ORACLE_PROC_MAKEFILE=/home/ora9ir1/precomp/demo/proc/demo_proc.mk
ORACLE_HOME=/home/ora9ir1 ORA_NET2_DESC=7,10
ora9ir2 31312 0.0 0.4 402660 8232 ? S 07:57 0:00 ora_pmon_ora9ir2
HOSTNAME=xtkyte-pc.us.oracle.com SHELL=/bin/bash TERM=xterm HISTSIZE=1000
LD_PRELOAD=/home/ora9ir2/libcwait.so USER=ora9ir2
LD_LIBRARY_PATH=/home/ora9ir2/lib ORACLE_SID=ora9ir2
PATH=/home/tkyte/bin:/home/ora9ir2/bin:/bin:/usr/bin:/usr/ccs/bin:/usr/ucb::/us
r/X11R6/bin:/usr/java/j2sdk1.4.2_04/bin/:/home/ora9ir2/bin
MAIL=/var/spool/mail/ora9ir2 _=/home/ora9ir2/bin/sqlplus PWD=/home/ora9ir2
INPUTRC=/etc/inputrc LANG=en_US.UTF-8 SQLPATH=/home/tkyte/src/sqlstuff
HOME=/home/ora9ir2 SHLVL=2 LD_ASSUME_KERNEL=2.4.19 LOGNAME=ora9ir2
ORACLE_PROC_MAKEFILE=/home/ora9ir2/precomp/demo/proc/demo_proc.mk
ORACLE_HOME=/home/ora9ir2 ORA_NET2_DESC=7,10
[root@xtkyte-pc root]#
Now, that aside, you do NOT want to install the software multiple times A version should be INSTALLED EXACTLY ONCE on a machine. A single software install can support multiple instances and databases -- each with their own SID
(hey, they could have the same db name if you wanted but that was be a really bad idea too -- the goal is to organize things, not to make things more confusing)
Why do you believe you want to install multiple times??
|
|
|
Re: how to recovery database from tape to test db [message #121192 is a reply to message #121091] |
Thu, 26 May 2005 15:00 |
girish.rohini
Messages: 744 Registered: April 2005 Location: Delhi (India)
|
Senior Member |
|
|
Theres no need to install Oracle multiple times, unless of-course the two versions that are to be installed are different.
Also, NK thanks for clearing this concept:
ORACLE_HOME+ORACLE_SID must be unique on unix.
But still not sure with having 2 different databases with same name on same machine. Have to check it...
Regds
Girish
|
|
|
|
|