1.一種Oracle數(shù)據(jù)庫修改字符集的方法,其特征在于步驟為:
(1)完全關(guān)閉一個節(jié)點1;
(2)、在節(jié)點2操作,修改cluster_database參數(shù)為false,變成單實例;
(3)、在節(jié)點2上關(guān)閉數(shù)據(jù)庫,重啟數(shù)據(jù)庫;
(4)、在節(jié)點2上分別執(zhí)行命令;
(5)、重新啟動數(shù)據(jù)庫后啟動節(jié)點1。
2.根據(jù)權(quán)利要求1所述的一種Oracle數(shù)據(jù)庫修改字符集的方法,其特征在于步驟(1)中,oracle用戶下執(zhí)行如下代碼:srvctl stop nodeapps -n name1;root用戶下執(zhí)行如下代碼:crsctl stop crs。
3.根據(jù)權(quán)利要求1所述的一種Oracle數(shù)據(jù)庫修改字符集的方法,其特征在于步驟(2)中,代碼為:SQL> alter system set cluster_database=false scope=spfile。
4.根據(jù)權(quán)利要求1所述的一種Oracle數(shù)據(jù)庫修改字符集的方法,其特征在于步驟(4)中,將數(shù)據(jù)庫啟動到RESTRICTED模式下做字符集更改:
SQL> conn /as sysdba
Connected
SQL> shutdown immediate;
Database closed
Database dismounted
ORACLE instance shut down
SQL> startup mount
ORACLE instance started
Total System Global Area 236000356 bytes
Fixed Size 451684 bytes
Variable Size 201326592 bytes
Database Buffers 33554432 bytes
Redo Buffers 667648 bytes
Database mounted
SQL> ALTER SYSTEM ENABLE RESTRICTED SESSION;
System altered
SQL> ALTER SYSTEM SET JOB_QUEUE_PROCESSES=0;
System altered
SQL> ALTER SYSTEM SET AQ_TM_PROCESSES=0;
System altered
SQL> alter database open;
Database altered
SQL> ALTER DATABASE CHARACTER SET ZHS16GBK;
ALTER DATABASE CHARACTER SET ZHS16GBK
ERROR at line 1:
ORA-12712: new character set must be a superset of old character set。
5.根據(jù)權(quán)利要求1所述的一種Oracle數(shù)據(jù)庫修改字符集的方法,其特征在于步驟(4)中,若遇到提示字符集內(nèi)容為:新字符集必須為舊字符集的超集,此時,跳過超集的檢查做更改:
SQL> ALTER DATABASE character set INTERNAL_USE ZHS16GBK;
Database altered
SQL> select * from v$nls_parameters;
19 rows selected
SQL> alter system set cluster_database=true scope=spfile。
6.根據(jù)權(quán)利要求1所述的一種Oracle數(shù)據(jù)庫修改字符集的方法,其特征在于步驟(5)中,代碼為:crsctl start crs。