melsterTEK
Programmer
Hello. Can anyone share a standard create database script for oracle 10g? I tried using my old oracle 9i scripts and I am finding there are some gotchas with creating a db in 10gR2. Thanks.
Follow along with the video below to see how to install our site as a web app on your home screen.
Note: This feature may not be available in some browsers.
-- Maintenance History:
-- 2007/01/26 Created and tailored by DHUNT
shutdown abort
startup nomount pfile=/usr/app/oracle/admin/CHI4102/pfile/initCHI4102.ora
create database CHI4102
controlfile reuse
logfile group 1 ('/data/oracle/oradata/chidev4/CHI4102log1a.ora',
'/data/oracle/oradata/chidev4/CHI4102log1b.ora')
size 30M reuse,
group 2 ('/data/oracle/oradata/chidev4/CHI4102log2a.ora',
'/data/oracle/oradata/chidev4/CHI4102log2b.ora')
size 30M reuse,
group 3 ('/data/oracle/oradata/chidev4/CHI4102log3a.ora',
'/data/oracle/oradata/chidev4/CHI4102log3b.ora')
size 30M reuse
datafile '/data/oracle/oradata/chidev4/CHI4102system01.dbf' size 80M reuse
autoextend on next 10m maxsize 2000m
sysaux datafile '/data/oracle/oradata/chidev4/CHI4102sysaux01.dbf' size 10m reuse
autoextend on next 10m maxsize 2000m
character set WE8ISO8859P1;
create tablespace rbs
datafile '/data/oracle/oradata/chidev4/CHI4102rbs01.dbf' size 10m reuse
autoextend on next 10M maxsize 2000m
segment space management manual
;
alter tablespace rbs add datafile '/data/oracle/oradata/chidev4/CHI4102rbs02.dbf' size 10m reuse
autoextend on next 10m maxsize 2000m;
alter tablespace rbs add datafile '/data/oracle/oradata/chidev4/CHI4102rbs03.dbf' size 10m reuse
autoextend on next 10m maxsize 2000m;
create public rollback segment dummy tablespace system;
alter rollback segment dummy online;
create public rollback segment rbs1 tablespace rbs
storage (initial 1m next 1m optimal 10m maxextents unlimited);
create public rollback segment rbs2 tablespace rbs
storage (initial 1m next 1m optimal 10m maxextents unlimited);
create public rollback segment rbs3 tablespace rbs
storage (initial 1m next 1m optimal 10m maxextents unlimited);
create public rollback segment rbs4 tablespace rbs
storage (initial 1m next 1m optimal 10m maxextents unlimited);
create public rollback segment rbs5 tablespace rbs
storage (initial 1m next 1m optimal 10m maxextents unlimited);
create public rollback segment rbs6 tablespace rbs
storage (initial 1m next 1m optimal 10m maxextents unlimited);
alter rollback segment rbs1 online;
alter rollback segment rbs2 online;
alter rollback segment rbs3 online;
alter rollback segment rbs4 online;
alter rollback segment rbs5 online;
alter rollback segment rbs6 online;
alter rollback segment dummy offline;
drop rollback segment dummy;
create tablespace temp temporary
datafile '/data/oracle/oradata/chidev4/CHI4102temp01.dbf' size 10M reuse
autoextend on next 10m maxsize 2000m
segment space management manual
;
alter tablespace system
default storage (initial 16k next 64k pctincrease 100 maxextents unlimited);
alter tablespace temp
default storage (initial 16k next 1M pctincrease 50 maxextents unlimited);
@$ORACLE_HOME/rdbms/admin/catalog
@$ORACLE_HOME/rdbms/admin/catproc
@$ORACLE_HOME/rdbms/admin/catblock.sql
@$ORACLE_HOME/rdbms/admin/catexp.sql
@$ORACLE_HOME/rdbms/admin/utlxplan.sql
@$ORACLE_HOME/rdbms/admin/utltkprf.sql
@$ORACLE_HOME/sqlplus/admin/plustrce
connect system/<system password>
@$ORACLE_HOME/sqlplus/admin/pupbld
# standard init.ora template for Oracle 10g
db_name = "CHI4102"
instance_name = CHI4102
service_names = CHI4102
control_files = ("/dbsrv/oracle/data1/oradata/CHI4102/CHI4102control01a.ctl",
"/dbsrv/oracle/data1/oradata/CHI4102/CHI4102control01b.ctl",
"/dbsrv/oracle/data1/oradata/CHI4102/CHI4102control02a.ctl",
"/dbsrv/oracle/data1/oradata/CHI4102/CHI4102control02b.ctl",
"/dbsrv/oracle/data1/oradata/CHI4102/CHI4102control03a.ctl",
"/dbsrv/oracle/data1/oradata/CHI4102/CHI4102control03b.ctl")
background_dump_dest = /dbsrv/oracle/app/oracle/admin/CHI4102/bdump
core_dump_dest = /dbsrv/oracle/app/oracle/admin/CHI4102/cdump
user_dump_dest = /dbsrv/oracle/app/oracle/admin/CHI4102/udump
shared_pool_size = 150M
shared_pool_reserved_size = 15M
java_pool_size = 150M
log_buffer = 163840
processes = 1500
db_block_size = 8192
db_block_buffers = 20000
sort_area_retained_size = 64000
sort_area_size = 4096000
db_file_multiblock_read_count = 32
log_checkpoint_interval = 50000
log_checkpoint_timeout = 0
open_cursors = 1024
os_authent_prefix = ""
utl_file_dir = *