第四章: 建立資料庫
db_name = lx02
db_block_size = 8192
pga_aggregate_target = 30m
db_cache_size = 80m
shared_pool_size = 60m
parallel_threads_per_cpu = 4
optimizer_mode = choose
star_transformation_enabled = true
db_file_multiblock_read_count = 16
query_rewrite_enabled = true
query_rewrite_integrity = trusted
background_dump_dest = $oracle_base/admin/lx02/bdump
user_dump_dest = $oracle_base/admin/lx02/udump
core_dump_dest = $oracle_base/admin/lx02/cdump
control_files = $oracle_base/oradata/lx02/control01.ctl
undo_management = auto
undo_tablespace = rtbs
3)建立建庫指令碼
1、庫名
2、表空間及資料檔案的位置和大小
3、redo 日誌檔案的位置和大小
4、字符集
建庫指令碼:vi cr_db.sql
create database lx02
user sys identified by oracle
user system identified by oracle
datafile '$oracle_base/oradata/lx02/system01.dbf' size 300m
sysaux datafile '$oracle_base/oradata/lx02/sysaux01.dbf' size 100m
default temporary tablespace temp tempfile '$oracle_base/oradata/lx02/temp01.dbf' size 100m
undo tablespace rtbs datafile '$oracle_base/oradata/lx02/rtbs01.dbf' size 100m
logfile
group 1 '$oracle_base/oradata/lx02/redo01a.log' size 10m,
group 2 '$oracle_base/oradata/lx02/redo02a.log' size 10m
character set zhs16gbk;
告警日誌資訊:
create tablespace system datafile '$oracle_base/oradata/test/system01.dbf' size 400m
sat aug 20 00:26:51 2011
successfully onlined undo tablespace 1.
completed: create undo tablespace rtbs datafile '$oracle_base/oradata/test/rtbs01.dbf' size 100m
sat aug 20 00:26:51 2011
create tablespace sysaux datafile '$oracle_base/oradata/test/sysaux01.dbf' size 100m
extent management local segment space management auto online
completed: create tablespace sysaux datafile '$oracle_base/oradata/test/sysaux01.dbf' size 100m
extent management local segment space management auto online
sat aug 20 00:26:54 2011
create temporary tablespace temp tempfile '$oracle_base/oradata/test/temp01.dbf' size 100m
completed: create temporary tablespace temp tempfile '$oracle_base/oradata/test/temp01.dbf' size 100m
sat aug 20 00:26:55 2011
alter database default temporary tablespace temp
completed: alter database default temporary tablespace temp
sat aug 20 00:26:55 2011
alter database default tablespace system
completed: alter database default tablespace system
sat aug 20 00:27:01 2011
smon: enabling tx recovery
sat aug 20 00:27:02 2011
threshold validation cannot be done before catproc is loaded.
replication_dependency_tracking turned off (no async multimaster replication found)
starting background process qmnc
qmnc started with pid=13, os id=6485
sat aug 20 00:27:03 2011
completed: create database test
user sys identified by **user system identified by *datafile '$oracle_base/oradata/test/system01.dbf' size 400m
sysaux datafile '$oracle_base/oradata/test/sysaux01.dbf' size 100m
undo tablespace rtbs datafile '$oracle_base/oradata/test/rtbs01.dbf' size 100m
default temporary tablespace temp tempfile '$oracle_base/oradata/test/temp01.dbf' size 100m
logfile
group 1 '$oracle_base/oradata/test/redo01a.log' size 10m,
group 2 '$oracle_base/oradata/test/redo02a.log' size 10m,
group 3 '$oracle_base/oradata/test/redo03a.log' size 10m
character set zhs16gbk
4)建立資料字典
資料字典指令碼:vi cr_dict.sql
@$oracle_home/rdbms/admin/catalog.sql
@$oracle_home/rdbms/admin/catproc.sql
conn system/oracle
@$oracle_home/sqlplus/admin/pupbld.sql
5)建立users 表空間,作為普通使用者的預設表空間
08:08:19 sql> select tablespace_name from dba_tablespaces;
tablespace_name
------------------------------
system
rtbs
sysaux
temp
4 rows selected.
08:08:27 sql> col file_name for a50
08:08:37 sql> select file_id,file_name,tablespace_name from dba_data_files;
tablespace created.
08:10:41 sql> alter database default tablespace users;
database altered.
08:10:45 sql> select file_id,file_name,tablespace_name from dba_data_files;
4 rows selected.
6)新增scott 案例
08:11:45 sql> @$oracle_home/rdbms/admin/utlsampl.sql
disconnected from oracle database 10g enterprise edition release 10.2.0.1.0 - production
with the partitioning, olap and data mining options
[oracle@oracle ~]$
本文出自 「天涯客的blog」 部落格,請務必保留此出處
Oracle DBA學習筆記 STARTUP詳解
oracle dba學習筆記 startup詳解 一 命令解析 startup options upgrade options options為 force restrict pfile filename quiet mount dbname open open options dbname nom...
課程筆記 優秀課程筆記整理
目錄 cs231n 李巨集毅老師機器學習課程 pytorch學習筆記 深度學習概述 神經網路基礎之邏輯回歸 神經網路基礎之python與向量化 淺層神經網路 深層神經網路 深度學習的實用層面 優化演算法 超引數除錯 batch正則化和程式設計框架 機器學習策略 上 機器學習策略 下 卷積神經網路基礎...
python課程筆記 Python課程筆記(二)
1 格式化輸出 print d d s 15,3.14,12.8 對比c語言 printf d,d,s 15,3.14,12.8 這裡可見 python要求更簡明一些。注意點 without syntaxwarning str object is not callable 在 的左側放置乙個字串 格...