DBNEWID工具使用二:更改DBNAME
二、使用DBNEWID修改DBNAME
1、檢視當前的DBNAME
SQL> select name from v$database;
SQL> select name from v$database;
NAME
---------
WWL
2、建立引數檔案
SQL> create pfile from spfile;
File created.
---------
WWL
2、建立引數檔案
SQL> create pfile from spfile;
File created.
3、關閉資料庫
SQL> shutdown immediate
Database closed.
Database dismounted.
ORACLE instance shut down.
SQL> startup mount pfile='/orasoft/product/10.2.0/db_1/dbs/initwwl.ora';
ORACLE instance started.
SQL> shutdown immediate
Database closed.
Database dismounted.
ORACLE instance shut down.
SQL> startup mount pfile='/orasoft/product/10.2.0/db_1/dbs/initwwl.ora';
ORACLE instance started.
Total System Global Area 285212672 bytes
Fixed Size 1218992 bytes
Variable Size 62916176 bytes
Database Buffers 218103808 bytes
Redo Buffers 2973696 bytes
Database mounted.
SQL> exit
Disconnected from Oracle Database 10g Enterprise Edition Release 10.2.0.1.0 - Production
With the Partitioning, OLAP and Data Mining options
Fixed Size 1218992 bytes
Variable Size 62916176 bytes
Database Buffers 218103808 bytes
Redo Buffers 2973696 bytes
Database mounted.
SQL> exit
Disconnected from Oracle Database 10g Enterprise Edition Release 10.2.0.1.0 - Production
With the Partitioning, OLAP and Data Mining options
4、使用NID命令更改資料庫名稱,將原來的WWL更改為WWL01:
[oracle@ora10g dbs]$ nid target = sys/oracle DBNAME = WWL01 SETNAME=YES;
DBNEWID: Release 10.2.0.1.0 - Production on Wed Dec 7 00:28:17 2011
Copyright (c) 1982, 2005, Oracle. All rights reserved.
Connected to database WWL (DBID=4286252909)
Connected to server version 10.2.0
Control Files in database:
/oradata/wwl/control01.ctl
/oradata/wwl/control02.ctl
/oradata/wwl/control03.ctl
/oradata/wwl/control01.ctl
/oradata/wwl/control02.ctl
/oradata/wwl/control03.ctl
Change database name of database WWL to WWL01? (Y/[N]) => Y
Proceeding with operation
Changing database name from WWL to WWL01
Control File /oradata/wwl/control01.ctl - modified
Control File /oradata/wwl/control02.ctl - modified
Control File /oradata/wwl/control03.ctl - modified
Datafile /oradata/wwl/system01.dbf - wrote new name
Datafile /data2/test_local_01.dbf - wrote new name
Datafile /oradata/wwl/sysaux01.dbf - wrote new name
Datafile /oradata/wwl/users01.dbf - wrote new name
Datafile /oradata/wwl/test01_01.dbf - wrote new name
Datafile /data2/test001_01.dbf - wrote new name
Datafile /data2/test001_02.dbf - wrote new name
Datafile /data2/test002_01.dbf - wrote new name
Datafile /data2/bigfile001.dbf - wrote new name
Datafile /data2/undotbs2_01.dbf - wrote new name
Datafile /oradata/wwl/temp01.dbf - wrote new name
Datafile /data2/temp01_01.dbf - wrote new name
Control File /oradata/wwl/control01.ctl - wrote new name
Control File /oradata/wwl/control02.ctl - wrote new name
Control File /oradata/wwl/control03.ctl - wrote new name
Instance shut down
Changing database name from WWL to WWL01
Control File /oradata/wwl/control01.ctl - modified
Control File /oradata/wwl/control02.ctl - modified
Control File /oradata/wwl/control03.ctl - modified
Datafile /oradata/wwl/system01.dbf - wrote new name
Datafile /data2/test_local_01.dbf - wrote new name
Datafile /oradata/wwl/sysaux01.dbf - wrote new name
Datafile /oradata/wwl/users01.dbf - wrote new name
Datafile /oradata/wwl/test01_01.dbf - wrote new name
Datafile /data2/test001_01.dbf - wrote new name
Datafile /data2/test001_02.dbf - wrote new name
Datafile /data2/test002_01.dbf - wrote new name
Datafile /data2/bigfile001.dbf - wrote new name
Datafile /data2/undotbs2_01.dbf - wrote new name
Datafile /oradata/wwl/temp01.dbf - wrote new name
Datafile /data2/temp01_01.dbf - wrote new name
Control File /oradata/wwl/control01.ctl - wrote new name
Control File /oradata/wwl/control02.ctl - wrote new name
Control File /oradata/wwl/control03.ctl - wrote new name
Instance shut down
Database name changed to WWL01.
Modify parameter file and generate a new password file before restarting.
Succesfully changed database name.
DBNEWID - Completed succesfully.
Modify parameter file and generate a new password file before restarting.
Succesfully changed database name.
DBNEWID - Completed succesfully.
5、登陸到資料庫檢查,發現DBNAME已經由原來的WWL修改為現在的WWL01
[oracle@ora10g dbs]$ sqlplus / as sysdba
[oracle@ora10g dbs]$ sqlplus / as sysdba
SQL*Plus: Release 10.2.0.1.0 - Production on Wed Dec 7 00:26:44 2011
Copyright (c) 1982, 2005, Oracle. All rights reserved.
Connected to:
Oracle Database 10g Enterprise Edition Release 10.2.0.1.0 - Production
With the Partitioning, OLAP and Data Mining options
SQL> select dbid,name from v$database;
DBID NAME
---------- ---------
4286252909 WWL01
---------- ---------
4286252909 WWL01
SQL> exit
來自 “ ITPUB部落格 ” ,連結:http://blog.itpub.net/20674423/viewspace-713742/,如需轉載,請註明出處,否則將追究法律責任。
相關文章
- 利用DBNEWID工具來修改DBNAME
- Oracle工具——DBNEWIDOracle
- oracle 11g 更改sid和dbnameOracle
- 10G DBNEWID工具的增強
- DBNEWIN工具使用一:更改DBID
- DBNEWID Utility
- DBNEWID 筆記筆記
- 11g DBNEWID工具修改DBID碰到的問題
- oracle nid修改dbnameOracle
- oracle 修改dbid和dbnameOracle
- DBNEWID的用法----NID命令
- BBED工具的安裝使用(二)
- dbnewid修改dbid和庫名
- Oracle rac使用nid和dbms_backup_restore包修改dbid和dbnameOracleREST
- 11g Oracle DBNEWID的改進Oracle
- win10系統使用自帶畫圖工具更改照片大小的方法Win10
- 效能測試工具Locust使用指南(二)
- 手工修改Oracle資料庫DBNAME-轉載Oracle資料庫
- Windows下更改並使用NTPWindows
- Statspack之二-需要更改的系統引數
- 更改oracle使用者資訊(轉)Oracle
- CLUVFY工具(二)
- ORION工具(二)
- centos7 用工具nmtui更改網路卡設定CentOSUI
- Flutter 之使用 Event Bus 更改主題Flutter
- oracle更改使用者名稱Oracle
- Visual Studio系列教程:使用XAML工具建立使用者介面(二)
- 更改使用者host留下的坑
- 更改MYSQL使用者名稱密碼MySql密碼
- 高併發&效能優化(二)------系統監控工具使用優化
- 記一次通過DBNEWID工具修改DBID時的NID-00135: There are 1 active threads錯誤thread
- Excel通用類工具(二)Excel
- 【工具】git筆記(二)Git筆記
- Oracle工具——ADRCI(二)Oracle
- HAC叢集更改IP(單節點更改、全部節點更改)
- Win10 Bash更改預設使用者Win10
- MySQL 5.5更改使用者密碼方法MySql密碼
- 使用Oracle Hint提示來更改執行計劃Oracle