Re: rename a database
Date: Mon, 19 May 2008 16:26:41 -0400
Message-ID: <69eafc3f0805191326s396803f0q3b7a97d1487804b6@mail.gmail.com>
The NID utility greatly simplifies this. You can change either the database
name, the database id, or both. It works the same on both UNIX or Windows.
Check Metalink Note #224226.1. I've had to use this several times to finish off RMAN duplicates on UNIX and once on Windows when I had to change a database name as part of an application upgrade. It's pretty slick.
From the doc:
Change Only the DBNAME
- Backup the database
- SHUTDOWN IMMEDIATE of the database
- STARTUP MOUNT
- Open one session and run NID with sysdba privileges
% nid TARGET=SYS/password_at_test_db DBNAME=test_db2 SETNAME=Y
- the value of DBNAME is the new dbname of the database
- SETNAME must be set to Y. The default is N and causes the DBID to be changed also.
- shutdown IMMEDIATE of the database
- Set the DB_NAME initialization parameter in the initialization parameter file to the new database name
- Create a new password file
- Startup of the database(without resetlogs)
On Mon, May 19, 2008 at 2:57 PM, <genegurevich_at_discover.com> wrote:
> Hello :
>
>
> I need to rename an existing database (10.2.3). In the past (about 10 years
> ago and oracle 7) I was able to take the create controlfile command
> (via alter database rebuild controlfile to trace), replace the filesystem
> name and the database name with a new instance name, rename
> all the filesystems accordingly, execute the create controlfile command and
> be done.
>
> As I said I have not done it in about 10 years. Can this still be done like
> that? Am I missing anything?
>
> thank you
>
> Gene Gurevich
>
>
> --
> http://www.freelists.org/webpage/oracle-l
>
>
>
-- http://www.freelists.org/webpage/oracle-lReceived on Mon May 19 2008 - 15:26:41 CDT