I want to be able to install Oracle and have the installation process install my applications database schema. Can I automate this process? I have researched non-interactive installation but want it to run and create my schema. Can this be done?
Personally, I've never tried to do this. But Oracle Corp did recognize the need for this exact requirement. Beginning with Oracle 8i, the RDBMS software is now installed with a product called the Universal Installer (UI). The UI is a Java-based utility to install Oracle software. With the UI comes the capability to provide custom response files. These response files let you automate installation, called "silent" installation. Instead of manually answering the many questions that UI asks you, you provide your responses in a file. Example response files can be found on the installation CD in the response directory. Pay particular attention to the svrtypical.rsp file. This file shows the responses to a TYPICAL software installation. Part of the typical installation is the creation of the starter database. The svrtypical.rsp response file shows you how to change the "seedLocation" of the starter database. Point this to a directory which contains your starter database complete with your schema. This should do the job! In addition to this response file, the dbca.rsp file can be used to automate the Database Configuration Assitant wizard utility. This can be modified to use your pre-setup database.
Alternately, you can use Oracle's Software Packager. With the Software Packager and UI response files, you can do pretty much what you want. The Software Packager also lets you run SQL scripts with the SPAWN action. You could code your schema creation as a series of SQL scripts which gets run at a specified time.
Both UI response files and the Software Packager are described much more fully in the Oracle documentation than I can provide here.
For More Information
- What do you think about this answer? E-mail us at editor@searchDatabase.com with your feedback.
- The Best Oracle Web Links: tips, tutorials, scripts, and more.
- Have an Oracle tip to offer your fellow DBA's and developers? The best tips submitted will receive a cool prize--submit your tip today!
- Ask your technical Oracle questions--or help out your peers by answering them--in our live discussion forums.
- Ask the Experts yourself: Our Oracle gurus are waiting to answer your toughest questions.
This was first published in June 2001