12c 簡單至極的靜默方式建立資料庫

snowdba發表於2015-02-09
12c 官方文件上建議建立資料庫使用AL32UTF8字符集,並給出了一個靜默模式快速安裝資料庫的一個小例子。

Oracle建議安裝資料庫時採用AL32UTF8字符集,它對於全世界各種不同語言支援的較好。改變字符集是一個複雜而繁重的工作,最好不要再修改。所以建議使用AL32UTF8。即便是Oracle建議使用該字符集,在DBCA建立資料庫的時候預設選項並不是AL32UTF8,而是基於作業系統當前的語言區域選定的,比如WE8MSWIN1252。

Oracle recommends AL32UTF8 as the database character set. AL32UTF8 is Oracle's name for the UTF-8 encoding of the Unicode standard. The Unicode standard is the universal character set that supports most of the currently spoken languages of the world. The use of the Unicode standard is indispensable for any multilingual technology, including database processing.


下面來執行一次這個建庫語句,感受這簡單至極的過程,字符集採用AL32UTF8

[oracle@test ~]$ dbca -silent -createDatabase -templateName General_Purpose.dbc -gdbname oradb.example.com -sid oradb -responseFile NO_VALUE -characterSet AL32UTF8 -memoryPercentage 30 -emConfiguration LOCAL
Enter SYS user password:
 
Enter SYSTEM user password:
 
Copying database files
1% complete
3% complete
11% complete
18% complete
26% complete
33% complete
37% complete
Creating and starting Oracle instance
40% complete
45% complete
50% complete
55% complete
56% complete
60% complete
62% complete
Completing Database Creation
66% complete
70% complete
73% complete
85% complete
96% complete
100% complete
Look at the log file "/12c/app/oracle/cfgtoollogs/dbca/oradb/oradb.log" for further details.


[oracle@test ~]$ export ORACLE_SID=oradb
[oracle@test ~]$ sqlplus / as sysdba

SQL*Plus: Release 12.1.0.1.0 Production on Fri Jan 30 17:02:50 2015

Copyright (c) 1982, 2013, Oracle.  All rights reserved.


Connected to:
Oracle Database 12c Enterprise Edition Release 12.1.0.1.0 - 64bit Production
With the Partitioning, OLAP, Advanced Analytics and Real Application Testing options

SYS@oradb >show parameter name

NAME                                 TYPE        VALUE
------------------------------------ ----------- ------------------------------
cell_offloadgroup_name               string
db_file_name_convert                 string
db_name                              string      oradb
db_unique_name                       string      oradb
global_names                         boolean     FALSE
instance_name                        string      oradb
lock_name_space                      string
log_file_name_convert                string
pdb_file_name_convert                string
processor_group_name                 string
service_names                        string      oradb.example.com
SYS@oradb >
SYS@oradb >select name from v$datafile;

NAME
--------------------------------------------------------------------------------
/12c/app/oracle/oradata/oradb/system01.dbf
/12c/app/oracle/oradata/oradb/sysaux01.dbf
/12c/app/oracle/oradata/oradb/undotbs01.dbf
/12c/app/oracle/oradata/oradb/users01.dbf


[oracle@test ~]$ export ORACLE_SID=oradb
[oracle@test ~]$ sqlplus / as sysdba

SQL*Plus: Release 12.1.0.1.0 Production on Fri Jan 30 17:02:50 2015

Copyright (c) 1982, 2013, Oracle.  All rights reserved.


Connected to:
Oracle Database 12c Enterprise Edition Release 12.1.0.1.0 - 64bit Production
With the Partitioning, OLAP, Advanced Analytics and Real Application Testing options

SYS@oradb >show parameter name

NAME                                 TYPE        VALUE
------------------------------------ ----------- ------------------------------
cell_offloadgroup_name               string
db_file_name_convert                 string
db_name                              string      oradb
db_unique_name                       string      oradb
global_names                         boolean     FALSE
instance_name                        string      oradb
lock_name_space                      string
log_file_name_convert                string
pdb_file_name_convert                string
processor_group_name                 string
service_names                        string      oradb.example.com
SYS@oradb >
SYS@oradb >select name from v$datafile;

NAME
--------------------------------------------------------------------------------
/12c/app/oracle/oradata/oradb/system01.dbf
/12c/app/oracle/oradata/oradb/sysaux01.dbf
/12c/app/oracle/oradata/oradb/undotbs01.dbf
/12c/app/oracle/oradata/oradb/users01.dbf

全文完

來自 “ ITPUB部落格 ” ,連結:http://blog.itpub.net/29047826/viewspace-1431667/,如需轉載,請註明出處,否則將追究法律責任。

相關文章