Oracle FAQ Your Portal to the Oracle Knowledge Grid
HOME | ASK QUESTION | ADD INFO | SEARCH | E-MAIL US
 

Home -> Community -> Usenet -> c.d.o.server -> Re: Create Database Script..

Re: Create Database Script..

From: Howard J. Rogers <hjr_at_dizwell.com>
Date: 7 Sep 2004 18:27:18 -0700
Message-ID: <14a1f766.0409071727.2bc94226@posting.google.com>


arijitchatterjee123_at_yahoo.co.in (Arijit Chatterjee) wrote in message news:<ea01504d.0409070434.7fd79370_at_posting.google.com>...
> Dear Faculties,
> Thanks for your great supports.I drop my previous DB. And Create
> the new one with the same name.Please advice for any modification is
> needed???
> ===============================================================
> oradim -new -sid TempDB -intpwd tempdb -startmode manual -pfile
> E:\Oracle\admin\TempDB\pfile\inittempdb.ora
> ===============================================================
> SET ORACLE_SID=tempdb
> SQLPLUS /NOLOG
> CONNECT internal/tempdb as SYSDBA

You should *not* be connecting as INTERNAL. It works in 8i, as you have found. But it will not work in 9i or above. It has also been deprecated since version 8.0. Use the 'connect ... as sysdba' construct instead.

> STARTUP PFILE=E:\Oracle\admin\tempdb\pfile\inittempdb.ora NOMOUNT
> ================================================================
> CREATE DATABASE TempDB
> CONTROLFILE REUSE
WHY? I realise you are creating a new database with the same name as the old one, and therefore could actually be wanting to re-use an existing control file. But you (correctly) don't do it for the data files, so why do it for the control files?

If you don't need a piece of syntax, don't use it.

> LOGFILE 'E:\Oracle\oradata\tempdb\redo01.log' SIZE 100M,
> 'E:\Oracle\oradata\tempdb\redo02.log' SIZE 100M,
> 'E:\Oracle\oradata\tempdb\redo03.log' SIZE 100M
> DATAFILE 'E:\Oracle\oradata\tempdb\system01.dbf' SIZE 325M
> MAXLOGFILES 5
A bit on the low side. I would bump that up to 16 myself.

> MAXLOGMEMBERS 5
Probably OK

> MAXLOGHISTORY 1
This setting would kill you in a 9i Real Application Cluster. I realise yuo're NOT using a 9i RAC, but you should be aware of the issue. It does no harm to bump this up to something like 1024.

> MAXDATAFILES 100
The default value for this is 30, which is sheer stupidity on Oracle's part. 100 is better. But it still restricts your ability to grow this database into the future. I prefer a much higher setting... say, 1024 again. Your control file grows in size by 180 bytes per file number used, but that is really quite trivial.

> MAXINSTANCES 1
Technically, not needed as that is the default value anyway.

> CHARACTER SET WE8ISO8859P1
> NATIONAL CHARACTER SET UTF8;
> ================================================================
> orapwd file=E:\Oracle\iSuites\DATABASE\PWDtempdb.ORA password=tempdb entries=20
> I used orapwd ulility because unless at the time of startup
> it was giving error password not indentified check PWDtempdb.ORA

That will be because there is an entry in your init.ora which reads 'remote_login_passwordfile=exclusive'. Change that to 'NONE', and you won't get the error, and you won't need to create a password file.

> ================================================================
> Run The Scripts
> @E:\Oracle\iSuites\RDBMS\ADMIN\catalog.sql
> @E:\Oracle\iSuites\sqlplus\admin\PUPBLD.SQL
> @E:\Oracle\iSuites\RDBMS\ADMIN\catproc.sql
> @E:\Oracle\iSuites\RDBMS\ADMIN\standard.sql
> @E:\Oracle\iSuites\RDBMS\ADMIN\utlirp.sql
> @E:\Oracle\iSuites\RDBMS\ADMIN\catexp.sql
> ==================================================================
> Now I can use the Tab table,open the DBA Studio,
> Now it is working fine.
> Regards
> Arijit Chatterjee

Glad you got it working. There are just a few minor quibbles, but nothing too serious. The number of data files and log archives could be show-stoppers in a production environment, however.

Regards
HJR Received on Tue Sep 07 2004 - 20:27:18 CDT

Original text of this message

HOME | ASK QUESTION | ADD INFO | SEARCH | E-MAIL US