Migrer le Charset de WE8ISO8859P1 à W8ISOMSWIN1252 en Cluster RAC
Administration Oracle, Divers, scripts et trucs pas de Commentaire »Pour intégrer le passage à l’euro.
Le charset W8ISOMSWIN1252 est un subset de WE8ISO8859P1, il n’y a donc aucun risque mais que des avantages à passer en WE8ISOMSWIN1252 plutôt qu’en WE8ISO8859P15 qui possède mui aussi le caractère ‘€’ (y compris sur linux cf Note Metalink 264294.1).
Sur le nœud 1
[oracle@rac1 script]$ export ORACLE_SID=SID1
[oracle@rac1 script]$ sql
SQL*Plus: Release 10.2.0.4.0 – Production on Wed May 26 14:16:36 2010
Copyright (c) 1982, 2007, Oracle. All Rights Reserved.
Connected to:
Oracle Database 10g Release 10.2.0.4.0 – 64bit Production
With the Real Application Clusters option
SQL> create pfile=’/app/oracle/product/10.2.0/db_1/dbs/initSID1.ora’ from spfile;
File created.
SQL> shutdown immediate
Database closed.
Database dismounted.
ORACLE instance shut down.
Sur le nœud 2
[oracle@rac2 ~]$ export ORACLE_SID=SID2
[oracle@rac2 ~]$ sql
SQL*Plus: Release 10.2.0.4.0 – Production on Wed May 26 14:14:49 2010
Copyright (c) 1982, 2007, Oracle. All Rights Reserved.
Connected to:
Oracle Database 10g Release 10.2.0.4.0 – 64bit Production
With the Real Application Clusters option
SQL> shutdown immediate
Database closed.
Database dismounted.
ORACLE instance shut down.
SQL>
Sur le nœud 1
Dans /app/oracle/product/10.2.0/db_1/dbs on commente les deux lignes suivantes cluster_database_instances et cluster_database dans initSID1.ora.
SQL> startup mount pfile=’/app/oracle/product/10.2.0/db_1/dbs/initSID1.ora’
ORACLE instance started.
Total System Global Area 1577058304 bytes
Fixed Size 2084232 bytes
Variable Size 503317112 bytes
Database Buffers 1056964608 bytes
Redo Buffers 14692352 bytes
Database mounted.
SQL> alter system ENABLE RESTRICTED SESSION;
System altered.
SQL> alter database open;
Database altered.
SQL> ALTER DATABASE character SET WE8MSWIN1252 ;
Database altered.
SQL> shutdown immediate
Database closed.
Database dismounted.
ORACLE instance shut down.
On dé commente les paramètres dans initSID1.ora.
Avant d’arrêter le noeud 1 penser à recréer le spfile dans ASM.
On re démarre les deux instances
Nœud 1
SQL> startup
ORACLE instance started.
Total System Global Area 1577058304 bytes
Fixed Size 2084232 bytes
Variable Size 503317112 bytes
Database Buffers 1056964608 bytes
Redo Buffers 14692352 bytes
Database mounted.
Database opened.
SQL> quit
Nœud 2
SQL> startup
ORACLE instance started.
Total System Global Area 1577058304 bytes
Fixed Size 2084232 bytes
Variable Size 503317112 bytes
Database Buffers 1056964608 bytes
Redo Buffers 14692352 bytes
Database mounted.
Database opened.
SQL> quit
Le tour est joué.
albanlepunk