Link to home
Start Free TrialLog in
Avatar of gizmola
gizmola

asked on

Oracle 9i Database creation issue: Control file wrong block size

Help clarify something for me please, I haven't done an install since 7.x.  Using dbca, I attempted to create a database, where the initial block size (db_block_size) was set to 8k.  When DBCA attempted to create the database, it threw an error stating that the control files needed to be 4k (the default).  I was not able to get DBCA to create the database until i reset the db_block_size parameter back to 4k.  

Is this a known problem with dbca, or a misunderstanding on my part?  

I'm also a bit confused by the pfile.  When I let Oracle create a database, the only initialization file I could find appears to be a compiled form of the init<sid>.ora files I'm familiar with.  I was able to see some typical text parameters in the file, but it is a binary file (not a text file).

Is there a way that one creates a pfile from an init<sid>.ora file?

ASKER CERTIFIED SOLUTION
Avatar of seazodiac
seazodiac
Flag of United States of America image

Link to home
membership
This solution is only available to members.
To access this solution, you must be a member of Experts Exchange.
Start Free Trial
I have never heard such a problem with dbca though, maybe you can post the exact Oracle error number and message?
Avatar of Kong
Kong

You've probably partially completed an install then resumed it trying to change the db_block_size...

Once the database is created (controlfiles really) you can't change db_block_size.

G'day Seazodiac, seen you around a lot recently :-)
Likewise. Nice to hang out here with you guys...cool...
Avatar of gizmola

ASKER

Seazodiac,
  I didn't record the error numbers unfortunately.

In regards to creating the pfile and spfile, is an spfile a "source" pfile?  This is something different from an sfile?  These are all 8.x enhancements I gather?

Kong that is possible, I suppose.  What I did was create a database and then dropped it. Is it possible that Oracle would re-use the control files that existed for the dropped database because I did not delete them from the file system?  I did use the same SID name each time.
You do not need to use DBCA when you install Oracle. If this is a fresh installation  then the best way is to deinstall everything and to begin the installation from scratch. If you would like to create additional DB then delete the created (or failed to be created DB if any) and begin from the very begining. Do not try to edit SPFILE. It seems yoy tried to edit it - there are visible characters. Use
ALTER SYSTEM SET par_name=value SCOPE=BOTH
to set parameters.
SOLUTION
Link to home
membership
This solution is only available to members.
To access this solution, you must be a member of Experts Exchange.
Start Free Trial
spfile and pfile are totally different:

spfile is a oracle8i new feature, enhancement, and it's a binary file. It helps oracle8i server to keep a consistent repository of all parameters and you can store multiple instance parameter without mixing them up.

pfile is a conventional method of configuring SGA and database parameters, it's instance specific and a ASCII file.

SOLUTION
Link to home
membership
This solution is only available to members.
To access this solution, you must be a member of Experts Exchange.
Start Free Trial
Avatar of gizmola

ASKER

Ok folks, I'm gonna close this out and award points.  Thanks to everyone who weighed in.  It's a good bit clearer for me now.
Avatar of gizmola

ASKER

Also, I felt Kong provided me the best answer to my problem, although I guess I checked the wrong reply when I awarded points.  I believe the problem is a combination of

-Having the default init.ora in the /dbs directory (this was a linux install btw).
-Not deleting the control files on the file system prior to trying to use dbca again.

I will be following Kong's advice and doing a fresh install later today.  

I also appreciate the clarification on the pfile and spfile.  I was somehow confused in thinking there was a 3rd type of file, but I see now that there is only 2... the pfile which is the standard init<sid>.ora file (text format) and the spfile, which is an added convenience which allows you to write out the current database parameters to a persistent file that will be read on subsequent startups.  I can see how this is a nice feature as oppossed to the pre 8.x days when you had to remember to hand edit the init<sid>.ora file whenever you made a change.

If my understanding is correct, when the instance loads it will

1.Read the pfile.
2.Read the spfile.
Glad to have helped.

If you have problems with the fresh install today, update this thread.

For clarification the 9i Startup procedure is:

If you issue "startup", it will read the following files (in the listed order) from $ORACLE_HOME/dbs:

- spfile<sid>.ora
- spfile.ora
- init<sid>.ora

The first valid file it finds will be used. The command "show parameter spfile" will identify which was used.

Executing: startup pfile=..... will obviously direct it to use the pfile specified.